Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

👍 Add GinBrowse command #92

Merged
merged 1 commit into from
Aug 5, 2023
Merged

👍 Add GinBrowse command #92

merged 1 commit into from
Aug 5, 2023

Conversation

lambdalisue
Copy link
Owner

@lambdalisue lambdalisue commented Jun 24, 2023

Users can visit the hosting service webpage (e.g. GitHub) of the repository.
This feature is powered by git-browse, so users can use equivalent options of that CLI command like

:GinBrowse
#=> Opens a blob page of the current buffer or a tree page of the current working directory in the HEAD commit of the current branch

:GinBrowse my-awesome-branch
#=> Opens a blob page of the current buffer in the HEAD commit of my-awesome-branch branch

:'<,'>GinBrowse
#=> Opens a blob page of the current buffer with selected lines in the HEAD commit of the current branch

:GinBrowse --path=README.md
#=> Opens a blob page of README.md in the HEAD commit of the current branch

:GinBrowse --path=README.md:10
#=> Opens a blob page of README.md with line 10 in the HEAD commit of the current branch

:GinBrowse --path=README.md:10:20
#=> Opens a blob page of README.md with lines 10 to 20 in the HEAD commit of the current branch

:GinBrowse --home
#=> Opens the home page of the repository

:GinBrowse --commit
#=> Opens a commit page of the current branch

:GinBrowse --commit my-awesome-branch
#=> Opens a commit page of my-awesome-branch branch

:GinBrowse --commit fd28fa8
#=> Opens a commit page of fd28fa8 commit

:GinBrowse --pr
#=> Opens a pull request page that contains the HEAD commit of the current branch

:GinBrowse --pr my-awesome-branch
#=> Opens a pull request page that contains the HEAD commit of my-awesome-branch branch

:GinBrowse --pr fd28fa8
#=> Opens a pull request page that contains the fd28fa8 commit

@lambdalisue lambdalisue marked this pull request as draft June 24, 2023 23:02
@lambdalisue lambdalisue force-pushed the gin-browse branch 2 times, most recently from a568bfb to 933fa92 Compare June 24, 2023 23:05
@lambdalisue lambdalisue added the enhancement New feature or request label Jun 24, 2023
@lambdalisue lambdalisue force-pushed the gin-browse branch 2 times, most recently from 17a2ee9 to 3d0d6e4 Compare June 28, 2023 18:42
@lambdalisue lambdalisue marked this pull request as ready for review August 5, 2023 02:40
@lambdalisue
Copy link
Owner Author

Oops, I forgot to write documentations about g:gin_browse_aliases. I'll add it then merge.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant