From a1446893aa7686ca95bd996b2a5803f76ac16b34 Mon Sep 17 00:00:00 2001 From: Mike Dacre Date: Mon, 5 Mar 2018 20:21:51 -0800 Subject: [PATCH] Increment version to beta-5 --- README.md | 7 +++++++ careful_rm.py | 6 +++++- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 84854f2..a37377d 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # Careful rm +Version: 1.0-beta5 + A wrapper for rm that adds more useful warnings and an optional recycle/trash mode Can be used as a drop-in replacement for `rm` on any Linux or MacOS system with @@ -14,6 +16,9 @@ MacOS, otherwise the best trash location is chosen (see below). Most files can be restored using GUI tools (e.g. Nautilus/Finder), as the default Trash folders and metadata are used (e.g. *Put Back* works on Mac). +Note: passing `-s` will result in files being destroyed with `shred` and will +forcibly override and disable recycle mode. + Ideally, this tool should be symlinked to `rm` and the file `~/.rm_recycle_home` should be created, which will make recycling automatic only for files in your home directory. This will provide a great deal of safety @@ -28,6 +33,8 @@ Arguments --------- -c, --recycle move to trash instead of deleting (forced on by ~/.rm_recycle) + -s, --shred run shred on all files (recursively if directories + included) prior to deleting, override recycle --direct force off recycling, even if ~/.rm_recycle exists --dryrun do not actually remove or move files, just print -h, --help display this help and exit diff --git a/careful_rm.py b/careful_rm.py index 1eb07b9..091435f 100755 --- a/careful_rm.py +++ b/careful_rm.py @@ -11,6 +11,10 @@ this is the best option for Linux, where recycling all files isn't a great idea. +Passing -s or --shred will invoke shred on every file prior to removing them +and will disable recycle mode. Passing --direct will force disable recycle +mode without enabling shred. + Note: splits files, directories, and other non-files (e.g. sockets) and handles them separately. non-files are always deleted with rm after checking with the user. @@ -65,7 +69,7 @@ # For old versions of python 2 input = raw_input -__version__ = '1.0b4' +__version__ = '1.0b5' # Don't ask if fewer than this number of files deleted CUTOFF = 3