rm-trash


Namerm-trash JSON
Version 1.0.2 PyPI version JSON
download
home_pagehttps://github.com/celsiusnarhwal/rm-trash
Summary🗑 Safe(r) deletion of files from the macOS command line
upload_time2022-12-29 03:06:12
maintainer
docs_urlNone
authorcelsius narhwal
requires_python>=3.8,<4.0
license
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # rm-trash

[![GitHub release (latest SemVer)](https://img.shields.io/github/v/release/celsiusnarhwal/rm-trash?logo=github&color=orange&logoColor=white&style=for-the-badge)](https://github.com/celsiusnarhwal/rm-trash/releases)

rm-trash is a macOS command-line utility that moves files and directories to the Trash.
Unlike [similar](https://github.com/ali-rantakari/trash) [tools](https://github.com/sindresorhus/macos-trash),
rm-trash intends to be a complete alternative to `rm` and `rmdir`, to the extent that you could use aliases
to have rm-trash replace them both.

rm-trash works by communicating with Finder
through [AppleScript](https://developer.apple.com/library/archive/documentation/AppleScript/Conceptual/AppleScriptLangGuide/introduction/ASLR_intro.html),
so it's no different from moving files to the Trash
from within Finder itself.

## Installation

Install rm-trash with [Homebrew](https://brew.sh) via
the [Houkago Tea Tap](https://github.com/celsiusnarhwal/homebrew-htt).

```bash
brew tap celsiusnarhwal/htt
brew install rm-trash
```

## Usage

Invoke rm-trash with the `trash` command, which will become available after installation.

```bash
trash --help
```

will tell you everything you need to know.

## Replacing `rm` and `rmdir`

If you wish, you can replace `rm` and `rmdir` with aliases to `trash`.

```bash
alias rm="trash trash"
alias rmdir="trash dir"
```

`trash` supports all options of both commands. Run `trash --help` for details.

## Limitations

rm-trash refuses to as root when [System Integrity Protection](https://support.apple.com/en-us/HT204899) (SIP) is
disabled.
You can still run rm-trash as a non-root user when SIP is disabled, or as any user when SIP is enabled. This limitation
is intended to prevent you from accidentally trashing files and directories that are typically protected by SIP.

If you must remove files as root while SIP is disabled, you can always fall back to `rm`.

## License

rm-trash is licensed under the [MIT License](LICENSE.md).
            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/celsiusnarhwal/rm-trash",
    "name": "rm-trash",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.8,<4.0",
    "maintainer_email": "",
    "keywords": "",
    "author": "celsius narhwal",
    "author_email": "hello@celsiusnarhwal.dev",
    "download_url": "https://files.pythonhosted.org/packages/1f/34/6125d839c75b0736d3eacbefec285c0b983cd3f82c20455f66be390ff25f/rm_trash-1.0.2.tar.gz",
    "platform": null,
    "description": "# rm-trash\n\n[![GitHub release (latest SemVer)](https://img.shields.io/github/v/release/celsiusnarhwal/rm-trash?logo=github&color=orange&logoColor=white&style=for-the-badge)](https://github.com/celsiusnarhwal/rm-trash/releases)\n\nrm-trash is a macOS command-line utility that moves files and directories to the Trash.\nUnlike [similar](https://github.com/ali-rantakari/trash) [tools](https://github.com/sindresorhus/macos-trash),\nrm-trash intends to be a complete alternative to `rm` and `rmdir`, to the extent that you could use aliases\nto have rm-trash replace them both.\n\nrm-trash works by communicating with Finder\nthrough [AppleScript](https://developer.apple.com/library/archive/documentation/AppleScript/Conceptual/AppleScriptLangGuide/introduction/ASLR_intro.html),\nso it's no different from moving files to the Trash\nfrom within Finder itself.\n\n## Installation\n\nInstall rm-trash with [Homebrew](https://brew.sh) via\nthe [Houkago Tea Tap](https://github.com/celsiusnarhwal/homebrew-htt).\n\n```bash\nbrew tap celsiusnarhwal/htt\nbrew install rm-trash\n```\n\n## Usage\n\nInvoke rm-trash with the `trash` command, which will become available after installation.\n\n```bash\ntrash --help\n```\n\nwill tell you everything you need to know.\n\n## Replacing `rm` and `rmdir`\n\nIf you wish, you can replace `rm` and `rmdir` with aliases to `trash`.\n\n```bash\nalias rm=\"trash trash\"\nalias rmdir=\"trash dir\"\n```\n\n`trash` supports all options of both commands. Run `trash --help` for details.\n\n## Limitations\n\nrm-trash refuses to as root when [System Integrity Protection](https://support.apple.com/en-us/HT204899) (SIP) is\ndisabled.\nYou can still run rm-trash as a non-root user when SIP is disabled, or as any user when SIP is enabled. This limitation\nis intended to prevent you from accidentally trashing files and directories that are typically protected by SIP.\n\nIf you must remove files as root while SIP is disabled, you can always fall back to `rm`.\n\n## License\n\nrm-trash is licensed under the [MIT License](LICENSE.md).",
    "bugtrack_url": null,
    "license": "",
    "summary": "\ud83d\uddd1 Safe(r) deletion of files from the macOS command line",
    "version": "1.0.2",
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "md5": "124f532a0b583646897fab7c849e1181",
                "sha256": "29164737b6a40e9a45616d1457e3696dec1d3de943e064beac2b0fb94ee12c5e"
            },
            "downloads": -1,
            "filename": "rm_trash-1.0.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "124f532a0b583646897fab7c849e1181",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8,<4.0",
            "size": 7945,
            "upload_time": "2022-12-29T03:06:11",
            "upload_time_iso_8601": "2022-12-29T03:06:11.597814Z",
            "url": "https://files.pythonhosted.org/packages/96/64/fdf98486effae2aff997001bfc4bc54b569f7b9147a77d2a4ffc716fafd5/rm_trash-1.0.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "md5": "97820b638630e496a76885201f13ca92",
                "sha256": "8cc2454e4cf5056178c3d8883723798f27c05f0d120419cbc9f32d32a48e658f"
            },
            "downloads": -1,
            "filename": "rm_trash-1.0.2.tar.gz",
            "has_sig": false,
            "md5_digest": "97820b638630e496a76885201f13ca92",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8,<4.0",
            "size": 6481,
            "upload_time": "2022-12-29T03:06:12",
            "upload_time_iso_8601": "2022-12-29T03:06:12.849313Z",
            "url": "https://files.pythonhosted.org/packages/1f/34/6125d839c75b0736d3eacbefec285c0b983cd3f82c20455f66be390ff25f/rm_trash-1.0.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2022-12-29 03:06:12",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "github_user": "celsiusnarhwal",
    "github_project": "rm-trash",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "rm-trash"
}
        
Elapsed time: 0.08125s