Add del function to the base plugins

pull/555/head
Miguel Morales 2015-10-07 15:55:38 -05:00
parent 8c05350c8b
commit ca3f1baf80
1 changed files with 8 additions and 0 deletions

View File

@ -223,3 +223,11 @@ function buf ()
local filetime=$(date +%Y%m%d_%H%M%S) local filetime=$(date +%Y%m%d_%H%M%S)
cp -a "${filename}" "${filename}_${filetime}" cp -a "${filename}" "${filename}_${filetime}"
} }
function del() {
about 'move files to hidden folder in tmp, that gets cleared on each reboot'
param 'file or folder to be deleted'
example 'del ./file.txt'
group 'base'
mkdir -p /tmp/.trash && mv "$@" /tmp/.trash;
}