All Projects → paulirish → Git Open

paulirish / Git Open

Licence: mit
Type `git open` to open the GitHub page or website for a repository in your browser.

Programming Languages

shell
77523 projects

Projects that are alternatives of or similar to Git Open

Gittar
🎸 Download and/or Extract git repositories (GitHub, GitLab, BitBucket). Cross-platform and Offline-first!
Stars: ✭ 87 (-96.77%)
Mutual labels:  gitlab, bitbucket
Pronto
Quick automated code review of your changes
Stars: ✭ 2,450 (-9.06%)
Mutual labels:  gitlab, bitbucket
Integram
Integrate Telegram into your workflow – Trello, Gitlab, Bitbucket and other bots
Stars: ✭ 1,365 (-49.33%)
Mutual labels:  gitlab, bitbucket
Notes
Some public notes
Stars: ✭ 1,248 (-53.67%)
Mutual labels:  gitlab, bitbucket
Env Ci
Get environment variables exposed by CI services
Stars: ✭ 180 (-93.32%)
Mutual labels:  gitlab, bitbucket
Git Copy History
Copy commit history from another repository
Stars: ✭ 84 (-96.88%)
Mutual labels:  gitlab, bitbucket
Android Ci
A docker image for building Android apps. Supports multiple SDK Build Tools.
Stars: ✭ 101 (-96.25%)
Mutual labels:  gitlab, bitbucket
Git Repo
Git-Repo: CLI utility to manage git services from your workspace
Stars: ✭ 818 (-69.64%)
Mutual labels:  gitlab, bitbucket
Browse At Remote
Browse target page on github/bitbucket from emacs buffers
Stars: ✭ 155 (-94.25%)
Mutual labels:  gitlab, bitbucket
Contributions Importer For Github
This tool helps users to import contributions to GitHub from private git repositories, or from public repositories that are not hosted in GitHub.
Stars: ✭ 147 (-94.54%)
Mutual labels:  gitlab, bitbucket
Export Pull Requests
Export pull requests and/or issues to a CSV file. Supports GitHub, GitLab, and Bitbucket
Stars: ✭ 68 (-97.48%)
Mutual labels:  gitlab, bitbucket
Grav Plugin Git Sync
Collaboratively Synchronize your Grav `user` folder hosted on GitHub, BitBucket or GitLab
Stars: ✭ 183 (-93.21%)
Mutual labels:  gitlab, bitbucket
Scm Backup
Makes offline backups of your cloud hosted source code repositories
Stars: ✭ 38 (-98.59%)
Mutual labels:  gitlab, bitbucket
Git History Browser Extension
Agrega un botón a la interfáz de archivos de github para ver su historial / Add a button to the github file interface to see its history
Stars: ✭ 87 (-96.77%)
Mutual labels:  gitlab, bitbucket
Trackdown
TrackDown - Issue Tracking with plain Markdown. If you are missing the "git clone" for your tickets from github.com or bitbucket.org, then this is for you. A lightweight Ticketing System for distributed and unconnected small Teams.
Stars: ✭ 10 (-99.63%)
Mutual labels:  gitlab, bitbucket
Gitlink
A Jetbrains plugin that opens a local file under Git version control in its remote host using the default browser.
Stars: ✭ 101 (-96.25%)
Mutual labels:  gitlab, bitbucket
Git Touch
An open-source app for GitHub, GitLab, Bitbucket, Gitea, and Gitee(码云), built with Flutter
Stars: ✭ 663 (-75.39%)
Mutual labels:  gitlab, bitbucket
Scala Steward
🤖 A bot that helps you keep your Scala projects up-to-date
Stars: ✭ 812 (-69.86%)
Mutual labels:  gitlab, bitbucket
Gitmails
An information gathering tool to collect git commit emails in version control host services
Stars: ✭ 142 (-94.73%)
Mutual labels:  gitlab, bitbucket
Source Integration
Source control integration plugin framework for MantisBT, including support for Github, Gitlab, Bitbucket, Gitweb, Cgit, Subversion, Mercurial and more
Stars: ✭ 167 (-93.8%)
Mutual labels:  gitlab, bitbucket

git-open Build Status

Type git open to open the repo website (GitHub, GitLab, Bitbucket) in your browser.

Demo of git open in action

Usage

git open [remote-name] [branch-name]
    # Open the page for this branch on the repo website

git open --commit
git open -c
   # Open the current commit in the repo website

git open --issue
git open -i
   # If this branch is named like issue/#123, this will open the corresponding
   # issue in the repo website

git open --print
git open -p
    # Only print the url at the terminal, but don't open it

(git open works with these hosted repo providers, git open --issue currently only works with GitHub, Visual Studio Team Services and Team Foundation Server)

Examples

$ git open
# opens https://github.com/TRACKED_REMOTE_USER/CURRENT_REPO/tree/CURRENT_BRANCH

$ git open someremote
# opens https://github.com/PROVIDED_REMOTE_USER/CURRENT_REPO/tree/CURRENT_BRANCH

$ git open someremote somebranch
# opens https://github.com/PROVIDED_REMOTE_USER/CURRENT_REPO/tree/PROVIDED_BRANCH

$ git open --issue
# If branches use naming convention of issues/#123,
# opens https://github.com/TRACKED_REMOTE_USER/CURRENT_REPO/issues/123

$ git open --print
# prints https://github.com/TRACKED_REMOTE_USER/CURRENT_REPO/tree/CURRENT_BRANCH

$ git open --suffix pulls
# opens https://github.com/TRACKED_REMOTE_USER/CURRENT_REPO/pulls

Installation

Basic install

The preferred way of installation is to simply add the git-open script somewhere into your path (e.g. add the directory to your PATH environment or copy git-open into an existing included path like /usr/local/bin).

Install via NPM:

npm install --global git-open

Windows Powershell

Save git-open anywhere, say as ~/Documents/Scripts/git-open.sh and define a function in your Powershell profile (see ~/Documents/WindowsPowerShell/profile.ps1) like this:

function git-open { cmd /c "C:\Program Files\Git\usr\bin\bash.exe" "~/Documents/Scripts/git-open.sh" }
Set-Alias -Name gop -Value git-open

Windows with cmd terminal

Save the git-open script in any place accessible via your %PATH% environment var.

ZSH

Antigen

Add antigen bundle paulirish/git-open to your .zshrc with your other bundle commands.

Antigen will handle cloning the plugin for you automatically the next time you start zsh, and periodically checking for updates to the git repository. You can also add the plugin to a running zsh with antigen bundle paulirish/git-open for testing before adding it to your .zshrc.

Oh-My-Zsh

  1. git clone https://github.com/paulirish/git-open.git $ZSH_CUSTOM/plugins/git-open
  2. Add git-open to your plugin list - edit ~/.zshrc and change plugins=(...) to plugins=(... git-open)

Zgen

Add zgen load paulirish/git-open to your .zshrc file in the same function you're doing your other zgen load calls in. ZGen will take care of cloning the repository the next time you run zgen save, and will also periodically check for updates to the git repository.

zplug

zplug "paulirish/git-open", as:plugin

Supported remote repositories

git-open can automatically guess the corresponding repository page for remotes (default looks for origin) on the following hosts:

  • github.com
  • gist.github.com
  • gitlab.com
  • GitLab custom hosted (see below)
  • bitbucket.org
  • Atlassian Bitbucket Server (formerly Atlassian Stash)
  • Visual Studio Team Services
  • Team Foundation Server (on-premises)
  • AWS Code Commit

Configuration

See the man page for more information on how to configure git-open.

Alternative projects

See hub for complete GitHub opening support. It's the official GitHub project and provides hub browse.

Homebrew has an alternate git-open that only works with GitHub but can open user profile pages, too.

@gerep has an alternate git-open that works with a few providers. Of note, it opens the default view for BitBucket instead of the source view.

And, of course, jasonmccreary's original gh from which this plugin was forked.

Thanks

jasonmccreary did the initial hard work. Since then, many contributors have submitted great PRs.

Contributing & Development

Please provide examples of the URLs you are parsing with each PR.

Testing:

You'll need to install bats, the Bash automated testing system. It's also available as brew install bats

git submodule update --init # pull in the assertion libraries

# Run the test suite once:
bats test  # or `npm run unit`

# Run it on every change with `entr`
brew install entr
npm run watch

Related projects

License

Copyright Jason McCreary & Paul Irish. Licensed under MIT. http://opensource.org/licenses/MIT

Changelog

  • 2018-12-03 - 2.1.0 shipped.
  • 2017-12-01 - 2.0 shipped. Breaking change: Gitlab configuration handled differently.
  • 2017-12-01 - Configuration for custom remote added
  • 2017-11-30 - Support for VSTS Added
  • 2017-10-31 - --issue and -h added
  • 2017-10-30 - Configuration for custom domains added
  • 2017-10-30 - WSL support added
  • 2017-06-16 - Introduced a test suite in BATS
  • 2017-06-15 - Entire script rewritten and simplified by @dermagia
  • 2016-07-23 - Readme: fix oh-my-zsh install instructions
  • 2016-07-22 - 1.1.0 shipped. update and add linters for package.json, readme.
  • 2016-07-11 - Readme formatting and installation instructions updated. Changelog started
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].