]> git.ipfire.org Git - thirdparty/util-linux.git/commit
rename: add --copy option to copy instead of rename
authorWanBingjiang <wanbingjiang@webray.com.cn>
Fri, 27 Feb 2026 09:08:39 +0000 (17:08 +0800)
committerWanBingjiang <wanbingjiang@webray.com.cn>
Tue, 28 Apr 2026 06:28:33 +0000 (14:28 +0800)
commitd021e24bc185cca05cf81a257648ec5d2d94f0e4
tree0f98de4a7d276b24bb79be22620f0341eafdaf2d
parent17b2647536294b6c598e9e4636cd603920183bbd
rename: add --copy option to copy instead of rename

Regular files: copy content with ul_copy_file(), preserve permissions.
Symlinks: create new link with same target. Add tests and man page.

Addresses: util-linux#3887
bash-completion/rename
misc-utils/rename.1.adoc
misc-utils/rename.c
tests/expected/rename/copy [new file with mode: 0644]
tests/expected/rename/copy.err [new file with mode: 0644]
tests/ts/rename/copy [new file with mode: 0755]