cp plugin: remove -- to separate files from options

This has some undesired effects, like having `cpv --help` be a file
not found error.

Use `--` yourself if you need it:

```zsh
cpv -- -some-file-with-hyphens.txt /tmp
```
This commit is contained in:
Marc Cornellà 2016-09-21 22:58:49 +02:00
commit 15900e7778
2 changed files with 1 additions and 3 deletions

View file

@ -30,5 +30,3 @@ The enabled options for rsync are:
* `-e /dev/null`: only work on local files (disable remote shells). * `-e /dev/null`: only work on local files (disable remote shells).
* `--progress`: display progress. * `--progress`: display progress.
* `--`: everything after this is an argument, even if it starts with a hyphen.

View file

@ -1,4 +1,4 @@
cpv() { cpv() {
rsync -pogbr -hhh --backup-dir=/tmp/rsync -e /dev/null --progress -- "$@" rsync -pogbr -hhh --backup-dir=/tmp/rsync -e /dev/null --progress "$@"
} }
compdef _files cpv compdef _files cpv