Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SHELL

how can i copy files in bash?

# from directory-to-directory
cp from_dir_name/file_name to_dir_name/new_file_name
# ex. cp Desktop/computer.jpeg Documents/Picture/pc.jpeg 

# new shortcut file
cp file_name new_file_name
# ex. cp computer.jpeg pc.jpeg

# copy multipler file into new directory
cp file_name file_name to_dir_name/
# ex. cp Desktop/computer.jpeg pc.jpeg Downloads/
 
PREVIOUS NEXT
Tagged: #copy #files
ADD COMMENT
Topic
Name
2+7 =