Permalink
Browse files

Revises docs.

  • Loading branch information...
1 parent 15acb89 commit bb94083c416ac79fdb4c573375499b39cbfc6d68 @andreafrancia committed Apr 13, 2012
View
@@ -2,34 +2,37 @@
trash-cli - Command Line Interface to FreeDesktop.org Trash.
============================================================
-trash-cli provides the following commands:
+trash-cli trashes files recording the original path, deletion date, and
+permissions. It uses the same trashcan of KDE, GNOME, and XFCE, but you can
+call it from the command line (and scripts).
+
+You can use these commands:
* trash-put trashes files and directories.
* trash-empty empty the trashcan(s).
* trash-list list trashed file.
* restore-trash restore a trashed file.
-For each file the name, original path, deletion date, and permissions
-are recorded. The trash command allow trash multiple files with the
-same name. trash-cli uses the same trashcan of KDE, GNOME and XFCE.
-
-Installation
-============
-Requirements:
-
- - python == 2.7 (2.6 may also work)
- - python-setuptools (e.g. apt-get install python-setuptools)
-
-Installation:
+How to get it (the easy way)
+============================
+ - Get python 2.7 (2.6 may also work)
+ - Get setuptools (e.g. apt-get install python-setuptools)
+ - Install with this command::
- sudo easy_install trash-cli
+ sudo easy_install trash-cli
Installation from sources
=========================
-Install with::
+::
- $ sudo python setup.py install
+ # grab the latest sources
+ wget https://github.com/andreafrancia/trash-cli/tarball/master
+
+ # unpack and install
+ tar xfz andreafrancia-trash-cli-xxxxxxxx.tar.gz
+ cd andreafrancia-trash-cli-xxxxxxxx
+ sudo python setup.py install
Usage
=====
@@ -87,31 +90,30 @@ Example::
$ trash-list
2008-02-19 20:11:34 /home/einar/today
-Packages from Debian/Ubuntu
-===========================
+Using it as 'rm' alias
+======================
-Don't use apt-get, this would install a very old version of trash-cli that
-contain a serious bug that could destroy your data. Please, if you are
-interested, ask to Debian/Ubuntu to upgrade their version of trash-cli.
+`trash-put` accept all the options that GNU `rm` does, if you prefer (I don't)
+you can set up this alias in your .bashrc::
-Information
-===========
+ alias rm='trash-put'
+
+At the present the semantic of trash-put is sligthly different from the one of
+`rm`, for example, while `rm` requires `-R` for deleting directories
+`trash-put` does not. This may change in future.
+
+Keep in mind that Bash aliases are used only in interactive shells, so using
+this alias should not interfere with scripts that expects to use `rm`.
+
+Bugs and feedback
+=================
- Website: http://code.google.com/p/trash-cli/
- Download page: http://code.google.com/p/trash-cli/wiki/Download
-Report bugs to: http://code.google.com/p/trash-cli/issues/list
+If you discover a bug please report it to:
-Features list
-=============
+ https://github.com/andreafrancia/trash-cli/issues
- - Command line interface compatible with on of the rm command. You can alias
- rm with trash.
- - Remembers original path, deletion time and file permissions of each trashed
- file.
- - Compatible with the KDE trash.
- - Implements the FreeDesktop.org Trash Specification
- - Works with volume other than the home volume (e.g. USB pen or another
- partition).
+You can reach me via email at me@andreafrancia.it . For twitter use
+@andreafrancia or #trashcli
Development
===========
@@ -120,7 +122,7 @@ Environment setup::
virtualenv env --no-site-packages
source env/bin/activate
- pip install -r requirements.txt -r requirements-dev.txt
+ pip install -r requirements-dev.txt
Running tests::
@@ -1,121 +0,0 @@
-#summary List of similar projects
-
-= DELSAFE =
-*URL:* http://homepage.esoterica.pt/~nx0yew/delsafe/
-
-Use a different approach to the same problem.
-While 'trash' provide a extra command that put files in the trash, 'delsafe' modifies the semantics of the existing commands.
-
-Apparently 'delsafe' overrides the library calls of unlink, unlinkat, rename, open and fopen modifying the semantics of these functions.
-A program that was designed to works with the original functions may not work well with the overridden functions.
-
-The example is the KDE filemanager which as two command:
- * delete file
- * trash file
-Using 'delsafe' these commands becomes:
- * delete file --> trash file in the delsafe trash
- * trash file --> trash file in the KDE trash
-
-I prefer the 'trash' approach because don't change the semantics of the existing program letting the user chose when putting files in the trash and when removing them.
-
-Personally I don't like the model where each deletion should recorded somewhere. 'trash' is intended to be used only in interactive shells, if a program decides to delete, or trunk a file the information loss risk IMHO should be managed in the context of this program.
-
-= trash.sh =
-*URL:* http://fresh.t-systems-sfr.com/unix/src/privat2/trashcan-3.2.tar.gz/
-
- * This program seems not compliant with the FreeDesktopTrashSpecification.
- * It compresses trashed file instead of just moving it.
- * Like trash-cli can trash and restore directories.
- * Seems that the development was ended in 2003.
-
-= Trashcan for Rox-Filer =
-URL: http://usuarios.lycos.es/proyectarr/
-
-Features:
- * Has a graphical user interface.
- * Does not support the FreeDesktopTrashSpecification.
- * Implemented in bash using zenity.
-
-= trash by skymt=
-URL: http://mysite.verizon.net/skymt/trash/
-Language: Python
-
-I reviewed the version [http://mysite.verizon.net/skymt/trash/trash-0.2.tar.gz 0.2]
-
-Is the only other CLI implementation of FreeDesktopTrashSpecification I ever found till now (2008-06-29)
-
-Features:
- * Operation supported:
- * trash files and directories: yes
- * listing trashed files: no
- * restoring trashed files: no
- * emptying the trashcan: no
- * Support of volumes trashcans: no
- * Can be used as alias='rm': no
-
-Notes:
- * *(Better than trash-cli)* Seems much simpler of trash-cli.\
- * *(Better than trash-cli)* Prints sensible output if the trashcan directories permission are wrong.
- * Not object oriented.
-
-=cn by Richard Neill=
-URL: http://www.richardneill.org/source.php#cn
-
-License: GPLv3
-
-Reviewed on: 2008-06-29
-
-Features:
- * Seems it is conform to the FreeDesktopTrashSpecification
- * Works also with the older KDE and GNOME TrashCan implementation
- * Can be used as alias='rm': no
- * *(Better than trash-cli)* It has a manpage.
-
-Trash Specification:
- * Operation supported:
- * trash files and directories: yes
- * listing trashed files: yes
- * restoring trashed files: yes
- * emptying trashcan: yes
- * Support of volumes trashcans: no
- * Can be used as alias='rm': no
-
-FreeDesktop.org specification deviations:
- * I'm not sure that it creates the trashinfo file in an atomic way.
-
-=File Rename Utils=
-URL: http://filerenameutils.sourceforge.net/
-
-License: ?
-
-Reviewed on: 2008-06-30
-
-Features:
- * Conform to FreeDesktopTrashSpecification : yes
- * Operation supported:
- * trash files and directories: yes
- * listing trashed files: yes
- * restoring trashed files: yes
- * emptying trashcan: yes
- * Support of volumes trashcans: ?
- * Can be used as alias='rm': no
-
-=Gnome Trashcan =
-As of Nautilus 2.22, GNOME support the XDG Trash specification through
-GIO and the GVFS-Trash backend. You can find the code for this backend
-here:
-http://svn.gnome.org/viewvc/gvfs/trunk/daemon/
-and GIO is in GLib:
-http://svn.gnome.org/viewvc/glib/trunk/gio/
-
-=Safe RM=
-This project does not use the TrashCan metaphore. The program alert you whenewer you attempt to delete files known to be important.
-URL: http://www.safe-rm.org.nz/
-
-= rmtrash =
-website: http://www.nightproductions.net/cli.htm
-trashcan utility for Mac OS X.
-I think it support only trashing files (not trash listing, or restoring).
-
-=Feedback=
-Feel free to leave any comment (below or mailing me) for any error or else.
@@ -5,9 +5,8 @@ Register the new version of the software on pypi
python setup register
-Then create a tarball and upload it to google and pypi:
+Then create a tarball and upload it to pypi:
- python setup.py sdist upload google_upload --src
-
+ python setup.py sdist upload
-EOF
@@ -1,21 +0,0 @@
-
-To create a patch:
-
-{{{
-svn checkout http://trash-cli.googlecode.com/svn/trunk/ trash-cli
-cd trash-cli/
-vim some files ...
-
-# Run tests
-python setup.py develop -s scripts
-python setup.py test
-
-# Add you as contributor
-vim THANKS
-
-svn diff > some-name-that-describe-changes.patch
-}}}
-
-Then you can send it to trash-cli@andreafrancia.it or you can attach to an
-open issue.
-
Oops, something went wrong.

0 comments on commit bb94083

Please sign in to comment.