{"id":13825377,"url":"https://github.com/k1LoW/execop","last_synced_at":"2025-07-08T21:32:15.744Z","repository":{"id":66825395,"uuid":"101045648","full_name":"k1LoW/execop","owner":"k1LoW","description":"ExeCop is a checker that check commands and environment variables before execute command.","archived":false,"fork":false,"pushed_at":"2017-09-27T00:57:54.000Z","size":77,"stargazers_count":18,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-17T05:55:18.013Z","etag":null,"topics":["bash","checker","zsh","zsh-plugin"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/k1LoW.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}},"created_at":"2017-08-22T09:26:13.000Z","updated_at":"2023-05-12T16:48:29.000Z","dependencies_parsed_at":"2023-05-10T15:30:44.570Z","dependency_job_id":null,"html_url":"https://github.com/k1LoW/execop","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/k1LoW/execop","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/k1LoW%2Fexecop","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/k1LoW%2Fexecop/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/k1LoW%2Fexecop/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/k1LoW%2Fexecop/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/k1LoW","download_url":"https://codeload.github.com/k1LoW/execop/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/k1LoW%2Fexecop/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264352817,"owners_count":23594979,"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":["bash","checker","zsh","zsh-plugin"],"created_at":"2024-08-04T09:01:19.819Z","updated_at":"2025-07-08T21:32:15.483Z","avatar_url":"https://github.com/k1LoW.png","language":"Shell","funding_links":[],"categories":["Shell"],"sub_categories":[],"readme":"# ExeCop\n\nExeCop is a checker that check commands and environment variables before execute command.\n\n![demo](demo.gif)\n\n## Install\n\nIf you use Zsh, add the following line to your .zshrc\n\n```zsh\n. /path/to/execop.zsh\n```\n\nIf you use Bash, add the following line to your .bashrc\n\n```bash\n. /path/to/execop.bash\n```\n\n## Usage\n\nPut `.execop` file to `/path/to/dir` like `.htaccess`.\n\n`.execop` file looks like following code\n\n```\ndeny when command_match destroy\nconfirm when command_match rm\nconfirm when env_eq AWS_PROFILE=production\n```\n\n## `.execop` file format\n\n```\ndeny when command_match destroy\n```\n\n```\n[action] when [matcher] [command or environment value]\n```\n\n| action |  |\n| --- | --- |\n| `deny` | deny command if macther match |\n| `confirm` | insert `yes/no` confirm if macther match |\n\n| matcher |  |\n| --- | --- |\n| `command_match` | command ~= value |\n| `command_not_match` | ! command ~= value |\n| `command_eq` | command = value |\n| `command_not_eq` | command != value |\n| `env_eq` | $SOMEENV = value |\n| `env_not_eq` | $SOMEENV != value |\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fk1LoW%2Fexecop","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fk1LoW%2Fexecop","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fk1LoW%2Fexecop/lists"}