zsh:funcs: Create trash wrapper only if exists
This commit is contained in:
@@ -286,6 +286,7 @@ crypt-umount() {
|
|||||||
udisksctl power-off -b "$1"
|
udisksctl power-off -b "$1"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (( $+commands[trash] )); then
|
||||||
## List items in trash if no argument is specified
|
## List items in trash if no argument is specified
|
||||||
trash() {
|
trash() {
|
||||||
if (( ! $# )); then
|
if (( ! $# )); then
|
||||||
@@ -294,6 +295,7 @@ trash() {
|
|||||||
command trash "$@"
|
command trash "$@"
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
fi
|
||||||
|
|
||||||
## Move one or more file(s) but keep a symlink to the new location.
|
## Move one or more file(s) but keep a symlink to the new location.
|
||||||
mvln() {
|
mvln() {
|
||||||
|
|||||||
Reference in New Issue
Block a user