copy_move_delete
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| copy_move_delete [2016/08/21 10:24] – walkeradmin | copy_move_delete [2017/01/29 17:57] (current) – walkeradmin | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| ===== Copy Move Delete ===== | ===== Copy Move Delete ===== | ||
| + | <color darkorange> | ||
| + | |||
| + | ---- | ||
| + | |||
| \\ | \\ | ||
| - | \\ | + | To <color darkred> |
| - | To copy a file or directory | + | |
| - | \\ | + | |
| To copy a file use: | To copy a file use: | ||
| cp filename path/ | cp filename path/ | ||
| Line 9: | Line 11: | ||
| To copy the file test.txt to the folder / | To copy the file test.txt to the folder / | ||
| cp test.txt / | cp test.txt / | ||
| + | \\ | ||
| + | Copying Directories (and contained files) | ||
| + | To copy a directory | ||
| + | cp -avr source_directory destination_directory | ||
| + | | ||
| + | To copy the directory / | ||
| + | cp -avr / | ||
| + | | ||
| + | Now you will have a / | ||
| + | \\ | ||
| + | The attributes <color darkred> | ||
| + | a | ||
| + | v Show results | ||
| + | r | ||
| + | \\ | ||
| + | \\ | ||
| + | To <color darkred> | ||
| + | To Move a file | ||
| + | mv source destination | ||
| + | | ||
| + | To move a file called test.txt from /home/pi to / | ||
| + | mv / | ||
| + | | ||
| + | mv works with directorys too | ||
| + | To move the folder / | ||
| + | mv / | ||
| + | \\ | ||
| + | \\ | ||
| + | To <color darkred> | ||
| + | To Delete a file | ||
| + | rm filename | ||
| + | | ||
| + | To delete a directory (even if it is empty) | ||
| + | rm -R directory | ||
| \\ | \\ | ||
| \\ | \\ | ||
| - | |||
copy_move_delete.1471775086.txt.gz · Last modified: (external edit)
