{"id":20064343,"url":"https://github.com/cedws/saferm","last_synced_at":"2026-05-12T17:43:30.193Z","repository":{"id":101974372,"uuid":"223657936","full_name":"cedws/saferm","owner":"cedws","description":"Utility for intercepting C standard library calls to delete files, instead moving them to a trash directory.","archived":false,"fork":false,"pushed_at":"2021-05-03T23:25:24.000Z","size":21,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-02T00:59:23.087Z","etag":null,"topics":["linux","utility"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cedws.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-11-23T21:53:12.000Z","updated_at":"2021-05-03T23:25:26.000Z","dependencies_parsed_at":null,"dependency_job_id":"8da8a5bc-c2cb-4d79-b577-ab98d57d1f36","html_url":"https://github.com/cedws/saferm","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cedws%2Fsaferm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cedws%2Fsaferm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cedws%2Fsaferm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cedws%2Fsaferm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cedws","download_url":"https://codeload.github.com/cedws/saferm/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241494142,"owners_count":19971870,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["linux","utility"],"created_at":"2024-11-13T13:45:45.623Z","updated_at":"2026-05-12T17:43:30.147Z","avatar_url":"https://github.com/cedws.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# saferm\nUtility for intercepting C standard library calls to delete files, instead moving them to the `Trash` directory. This is achieved via `LD_PRELOAD`. This can prevent an accidental `rm` or software bug from becoming a disaster.\n\n**This is just an experiment for now. Use at your own risk.**\n\n## Limitations\n- Can only prevent dynamically linked executables from truly deleting your files\n- Only supports Linux (macOS support might be possible but difficult, due to runtime hardening)\n\n## Usage\n- Run `make`\n- Configure your shell to export `LD_PRELOAD` with the path to the built shared object:\n\n    - Bash: add to `~/.profile`:\n        ```\n        export LD_PRELOAD=full/path/to/saferm.so\n        ```\n\n    - Fish: add to `~/.config/fish/config.fish`:\n        ```\n        set -x LD_PRELOAD full/path/to/saferm.so\n        ```\n- Reload your shell configuration with `source`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcedws%2Fsaferm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcedws%2Fsaferm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcedws%2Fsaferm/lists"}