Mohammadreza Hadizadeh

How to copy a file to all subdirectories in a directory using a command-line?

This will put the file "code.f" (in the current working directory) in all of the subfolders, but not their subfolders:
for d in */; do cp code.f "$d"; done

But this will put the file "code.f" in all of the subfolders and their subfolders:
find . -type d -exec cp code.f {} \;

How to delete all files of a specific extension in a directory and all subfolders using a command-line?

To remove all files with a specific extension (e.g. .data) in the current directory and all subfolders run
find . -name "*.data" -type f -delete
But first use "find" to see exactly which files you will remove:
find . -name "*.data" -type f

Install Dropbox via command line on Linux

Pasted Graphic 7

The Dropbox daemon works fine on all 32-bit and 64-bit Linux servers. To install, run the following command in your Linux terminal.
32-bit:
$ cd ~ && wget -O - "https://www.dropbox.com/download?plat=lnx.x86" | tar xzf -
64-bit:
$ cd ~ && wget -O - "https://www.dropbox.com/download?plat=lnx.x86_64" | tar xzf -
Next, run the Dropbox daemon from the newly created .dropbox-dist folder.
$ ~/.dropbox-dist/dropboxd
Tip:
If you're running Dropbox on your server for the first time, you'll be asked to copy and paste a link in a working browser to create a new account or add your server to an existing account. Once you do, your Dropbox folder will be created in your home directory. Download this CLI script to control Dropbox from the command line. For easy access, put a symlink to the script anywhere in your PATH.