This commit is contained in:
parent
736a53bad0
commit
3c09b37c3a
4
trash.sh
4
trash.sh
@ -6,11 +6,11 @@ FILE_PATHS_FILE="$HOME/.trash/.filepaths"
|
|||||||
[ ! -f "$FILE_PATHS_FILE" ] && touch "$FILE_PATHS_FILE"
|
[ ! -f "$FILE_PATHS_FILE" ] && touch "$FILE_PATHS_FILE"
|
||||||
|
|
||||||
trash_list() {
|
trash_list() {
|
||||||
ls -lrth "$HOME"/.trash/
|
find "$HOME"/.trash/
|
||||||
}
|
}
|
||||||
|
|
||||||
trash_put() {
|
trash_put() {
|
||||||
for FILE in $@; do
|
for FILE in "$@"; do
|
||||||
# Store old filepath for later restore
|
# Store old filepath for later restore
|
||||||
echo "$FILE $(readlink -f "$FILE")" >> "$FILE_PATHS_FILE"
|
echo "$FILE $(readlink -f "$FILE")" >> "$FILE_PATHS_FILE"
|
||||||
done
|
done
|
||||||
|
Loading…
x
Reference in New Issue
Block a user