cp
for filesystem> cp {flags} (source) (destination)
--recursive, -r
: copy recursively through subdirectories--verbose, -v
: show successful copies in addition to failed copies (default:false)--update, -u
: copy only when the SOURCE file is newer than the destination file or when the destination file is missing--interactive, -i
: ask user to confirm action--no-symlink, -n
: no symbolic links are followed, only works if -r is active--progress, -p
: enable progress barsource
: the place to copy fromdestination
: the place to copy toinput | output |
---|---|
nothing | nothing |
Copy myfile to dir_b
>cpmyfiledir_b
Recursively copy dir_a to dir_b
>cp-rdir_adir_b
Recursively copy dir_a to dir_b, and print the feedbacks
>cp-r-vdir_adir_b
Move many files into a directory
>cp*.txtdir_a
Copy only if source file is newer than target file
>cp-uab
Copyright © 2019–2023 The Nushell Project DevelopersLicensed under the MIT License.
https://www.nushell.sh/commands/docs/cp.html