{"id":13682480,"url":"https://github.com/Snyssfx/goerr-nvim","last_synced_at":"2025-04-30T09:32:48.218Z","repository":{"id":86123884,"uuid":"405362126","full_name":"Snyssfx/goerr-nvim","owner":"Snyssfx","description":"fold go `if err != nil` and show other lines","archived":false,"fork":false,"pushed_at":"2021-10-18T11:10:31.000Z","size":299,"stargazers_count":24,"open_issues_count":2,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-08-02T13:34:11.199Z","etag":null,"topics":["folding","go","neovim","neovim-plugin"],"latest_commit_sha":null,"homepage":"","language":"Lua","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/Snyssfx.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":"2021-09-11T11:33:48.000Z","updated_at":"2024-06-02T21:58:47.000Z","dependencies_parsed_at":null,"dependency_job_id":"21f2bdee-e2c8-46ef-95a0-220f3bdab1c9","html_url":"https://github.com/Snyssfx/goerr-nvim","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/Snyssfx%2Fgoerr-nvim","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Snyssfx%2Fgoerr-nvim/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Snyssfx%2Fgoerr-nvim/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Snyssfx%2Fgoerr-nvim/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Snyssfx","download_url":"https://codeload.github.com/Snyssfx/goerr-nvim/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":224206082,"owners_count":17273386,"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":["folding","go","neovim","neovim-plugin"],"created_at":"2024-08-02T13:01:46.792Z","updated_at":"2024-11-12T02:30:49.736Z","avatar_url":"https://github.com/Snyssfx.png","language":"Lua","funding_links":[],"categories":["Lua"],"sub_categories":[],"readme":"# goerr-nvim\nThe plugin folds Go's `if err != nil` and shows other lines like in Goland, it greatly reduces code length and doesn't affect readability.  \n\nThe plugin converts popular words that is used in handling errors to just Greek letters.  \nAlso it folds errors on buffer enter, and remove dots in folding.  \n\n__Before:__\n\n\u003cimg src=\"./pictures/before.png\" width=\"600\" height=\"700\" alt=\"before\"\u003e\n\n__After:__\n\n\u003cimg src=\"./pictures/after.png\" width=\"500\" height=\"600\" alt=\"after\"\u003e\n\n## Installation\n1. Install it with your favorite plugin manager\n2. Make sure you set `syntax on` and `set foldmethod=syntax`, since this plugin closes folds based on syntax. \n    - Or you can use any other foldmethod that creates folds on error handling, e.g. treesitter's one;\n    - If you know the better way of creating and closing folds, make me know in an issue or PR :)\n3. The plugin uses `softtabstop` setting under the cover. If the indentation level isn't right, you can adjust the setting accordingly or contribute to the plugin development :)\n4. If you don't use folds much and just want this plugin to work, you can set `foldnestmax` and `foldlevel` settings to high numbers (e.g. 10 and 9 respectively).\n    - It enables folding, but all your folds would be open by default (except `if err != nil` ones)\n\n## Features\n- Auto close `if err != nil` blocks of code, show inner lines;\n- Remove distracted dots via `'fillchars'`;\n- Truncate long inner lines;\n- Change `return` to 1 Unicode symbol (arrows);\n- Change `log` and `logger` to lambda;\n- Change `can't`, `cannot`, `can not` to just `c'`;\n- Change `fmt` and `errors` to phi and epsilon respectively.\n\n## TODO\n- Add parameters for this stuff;\n- Handle long `if`'s.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FSnyssfx%2Fgoerr-nvim","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FSnyssfx%2Fgoerr-nvim","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FSnyssfx%2Fgoerr-nvim/lists"}