{"id":18142324,"url":"https://github.com/kana/vim-g","last_synced_at":"2025-04-22T19:07:00.532Z","repository":{"id":16346072,"uuid":"11046262","full_name":"kana/vim-g","owner":"kana","description":"Vim plugin: Misc. utilities for Git","archived":false,"fork":false,"pushed_at":"2025-04-10T16:15:28.000Z","size":115,"stargazers_count":6,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-22T19:06:51.954Z","etag":null,"topics":["vim","vim-plugins"],"latest_commit_sha":null,"homepage":"","language":"Vim Script","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kana.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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,"zenodo":null}},"created_at":"2013-06-29T05:24:56.000Z","updated_at":"2025-04-10T19:17:04.000Z","dependencies_parsed_at":"2024-03-25T12:56:24.211Z","dependency_job_id":"732c3e5d-437b-405a-a557-8ec76ce74886","html_url":"https://github.com/kana/vim-g","commit_stats":null,"previous_names":[],"tags_count":12,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kana%2Fvim-g","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kana%2Fvim-g/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kana%2Fvim-g/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kana%2Fvim-g/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kana","download_url":"https://codeload.github.com/kana/vim-g/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250306638,"owners_count":21408926,"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":["vim","vim-plugins"],"created_at":"2024-11-01T18:06:34.545Z","updated_at":"2025-04-22T19:07:00.449Z","avatar_url":"https://github.com/kana.png","language":"Vim Script","funding_links":[],"categories":[],"sub_categories":[],"readme":"# vim-g [![CI](https://github.com/kana/vim-g/actions/workflows/ci.yml/badge.svg)](https://github.com/kana/vim-g/actions/workflows/ci.yml)\n\nThis is a Vim plugin which provides misc. utilities for Git.\n\n# Features\n\n## `:G args {pattern} [{pattern}...]`\n\nLike `:args`, but {pattern}s are interpreted by Git.\n\nUsage examples:\n\n- `G args 'tests/*.php'` for all PHP files under `tests/`.\n- `G args SomeComponent` for all files which paths includes `SomeComponent`.\n   Like all `*.ts` and `*.tsx` files under `components/SomeComponent/`.\n\n## `:G blame`\n\nOpen a Git blame viewer for the current buffer.\n\nYou can dig into blame prior to the change on the cursor line by typing `o`,\nand rewind the state by typing `u`.\n\n## `g#branch#get_name({dir})`\n\nReturn the current branch name.  Useful for options like `'tabline'`.\n\nIt detects detached HEAD state and returns special notation in that case.  For\nexample,\n\n- `REBASE-i` in the middle of `git rebase -i`\n- `master~100` if you intentionally did `git checkout master~100` to\n  investigate a problem\n\n## `g#vc#add()` `g#vc#commit()` `g#vc#diff()` `g#vc#restore()`\n\nWrappers for the corresponding Git subcommands.  Useful to define key mappings\nfor frequent usage.  For example:\n\n```vim\n\" Open a new buffer to edit commit message.\n\" :write the buffer to commit all modified files.\nnnoremap \u003cLeader\u003evC \u003cCmd\u003ecall g#vc#commit('-av')\u003cCR\u003e\n```\n\n```vim\n\" Open a new buffer to review all uncomitted changes.\nnnoremap \u003cLeader\u003evD \u003cCmd\u003ecall g#vc#diff('HEAD', '--', '.')\u003cCR\u003e\n```\n\n```vim\n\" Revert unstaged changes in the current file.\nnnoremap \u003cLeader\u003evv \u003cCmd\u003ecall g#vc#restore(expand('%'))\u003cCR\u003e\n```\n\n# Further reading\n\nSee [doc/g.txt](./doc/g.txt).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkana%2Fvim-g","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkana%2Fvim-g","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkana%2Fvim-g/lists"}