This repository has been archived on 2024-06-19. You can view files and clone it, but cannot push or open issues or pull requests.
dotfiles-old/dot_oh-my-zsh/plugins/cp
2024-03-03 15:33:59 +01:00
..
cp.plugin.zsh Added basic nvim config, replaced vim with nvim 2024-03-03 15:33:59 +01:00
README.md Added basic nvim config, replaced vim with nvim 2024-03-03 15:33:59 +01:00

cp plugin

This plugin defines a cpv function that uses rsync so that you get the features and security of this command.

To enable, add cp to your plugins array in your zshrc file:

plugins=(... cp)

Description

The enabled options for rsync are:

  • -p: preserves permissions.

  • -o: preserves owner.

  • -g: preserves group.

  • -b: make a backup of the original file instead of overwriting it, if it exists.

  • -r: recurse directories.

  • -hhh: outputs numbers in human-readable format, in units of 1024 (K, M, G, T).

  • --backup-dir="/tmp/rsync-$USERNAME": move backup copies to "/tmp/rsync-$USERNAME".

  • -e /dev/null: only work on local files (disable remote shells).

  • --progress: display progress.