{"id":23191675,"url":"https://github.com/vilhalmer/nvim-corral","last_synced_at":"2025-04-05T06:44:10.224Z","repository":{"id":142716567,"uuid":"109625670","full_name":"vilhalmer/nvim-corral","owner":"vilhalmer","description":"A neovim plugin to keep you within your boundaries","archived":false,"fork":false,"pushed_at":"2018-11-26T22:50:16.000Z","size":9,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-10T14:38:17.894Z","etag":null,"topics":["neovim","neovim-plugin","python3","source-control","vcs"],"latest_commit_sha":null,"homepage":"","language":"Python","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/vilhalmer.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":"2017-11-05T23:32:33.000Z","updated_at":"2018-11-26T22:50:18.000Z","dependencies_parsed_at":null,"dependency_job_id":"809d60db-517a-4e64-871f-6458d1071124","html_url":"https://github.com/vilhalmer/nvim-corral","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/vilhalmer%2Fnvim-corral","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vilhalmer%2Fnvim-corral/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vilhalmer%2Fnvim-corral/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vilhalmer%2Fnvim-corral/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/vilhalmer","download_url":"https://codeload.github.com/vilhalmer/nvim-corral/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247299787,"owners_count":20916186,"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":["neovim","neovim-plugin","python3","source-control","vcs"],"created_at":"2024-12-18T12:18:32.855Z","updated_at":"2025-04-05T06:44:10.219Z","avatar_url":"https://github.com/vilhalmer.png","language":"Python","readme":"# corral\n### A neovim plugin to keep you within your boundaries\n\nCorral is a small plugin with a single purpose: to prevent me from accidentally\nediting files outside of the repository I'm working in. If this is also a\nproblem you have, congratulations, you have found the solution!\n\n## Functionality\nWhen corral is enabled, it will observe your current working directory.\nWhenever you are inside of a VCS repository (currently git and svn are \nsupported, and only git is tested), any files that you open from outside of the \nrepository's directory tree will automatically have their buffers marked\n`readonly` and `nomodifiable`.  You will also get a message indicating that this \nhas happened.\n\n## Interface\nCorral exposes the following commands:\n- `:CorralEnable` to turn it on.\n- `:CorralDisable` to turn it off.\n- `:CorralToggle` to do whichever one of those isn't currently the case\n    (for bindings).\n\nNote that enabling corral does not affect existing buffers until they are\nre-read. Disabling it currently never releases existing corralled buffers. You\ncan always do `:set noreadonly modifiable` yourself, however.\n\nIt also sets the variable `b:corralled` on each buffer that it corrals,\nallowing this information to be used by other plugins.\n\n## TODO\n- Expose the settings dictionary as global variables, so you can use it.\n- Test svn support.\n- Add a `:CorralClean` command to delete all corralled buffers, making the\n    workspace squeaky clean.\n- Add `:CorralRelease` to 'free' all corralled buffers.\n- Add an option to be 'proactive' and scan all existing buffers when enabling\n    or disabling.\n\n## FAQ\n**Q:** I'm confused, does 'corralled' refer to the buffers inside or outside of\n    the repository?\n\n**A:** It's not a perfect metaphor, ok? (More seriously though, corral only\n    concerns itself with the behavior of buffers outside of the repository.)\n\n**Q:** Can it support *my favorite VCS*?\n\n**A:** Yeah, probably. All that corral needs to support a given VCS is \n    a command in the `vcs_commands` dictionary that returns the root of a\n    repository or exits non-zero if the command was not run within a\n    repository. If you have such a command, feel free to submit a PR and I'll\n    probably merge it!\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvilhalmer%2Fnvim-corral","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvilhalmer%2Fnvim-corral","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvilhalmer%2Fnvim-corral/lists"}