4 ms·
Git-hub – Do GitHub operations from the git command
- ChristianBundy 11y agohttps://github.com/ingydotnet/git-hub/issues/160 https://github.com/ingydotnet/git-hub/issues/160
- psophis 11y agoGitHub's hub is a wrapper for the git command. This adds a subcommand.
- TheHippo 11y agoWhy should I favor this over Github's hub? https://github.com/github/hub https://github.com/github/hub
- fiatjaf 11y agoThis is much more complete, and also you know when you are doing GitHub things and when you are doing Git things.
- jessedhillon 11y ago> hub is best aliased as git, so you can type $ git <command> I'd rather have a git subcommand to interface with github. The way hub works is to alias over git and make it do github things by default. That seems like an obviously wrong way to do it.
- jschwartzi 11y agoYou could probably wrap it with another BASH script named git that looks for hub as $1, otherwise it passes its args directly into the git command. I haven't quite worked out how $PATH resolution would work in that scheme though.
- jessedhillon 11y agoGit already works like this. If you attempt `git foo`, your $PATH will be consulted for an executable with the name `git-foo`, and if found, it will be called with the rest of the arguments. That's why this command is `git-hub` and is invoked with `git hub`.
- azdle 11y agoWow, it's all written in bash. This has to be the biggest bash program (?) I've ever seen.
- anonova 11y agoI think rvm [1] still holds that record for me. [1]: https://github.com/rvm/rvm https://github.com/rvm/rvm
- rylee 11y agoWait... rvm is pure bash? Oh dear god. That's honestly terrifying. I've never bothered looking at it.
- deleted 11y ago[deleted]
- bdcravens 11y agoThere was a crowd-sourcing campaign to re-write 2.0 in Ruby: https://www.bountysource.com/teams/rvm/fundraiser https://www.bountysource.com/teams/rvm/fundraiser However, I haven't heard anything of it in a while.
- accatyyc 11y agoThat sound pretty crazy. The reason to use RVM is to be able to run Ruby programs with different Ruby versions... How would you run it in the first time if you have the wrong versions? I guess bash is a good choice since it can be run pretty much everywhere.
- datashaman 11y agoHmmm, a Ruby version manager which is written with Ruby. Smells like rabbit hole. :)
- Hello71 11y ago$ cd rvm; find -type f -exec grep -l '#!.*bash' {} + | xargs wc -l | sort -n [ ... ] 448 ./scripts/functions/selector_interpreters 492 ./scripts/functions/gemset 501 ./scripts/functions/requirements/osx_brew 504 ./scripts/functions/selector 589 ./scripts/functions/support 681 ./scripts/gemsets 684 ./scripts/mount 886 ./binscripts/rvm-installer 1100 ./scripts/cli 1619 ./scripts/functions/installer $ wc -l /usr/portage/eclass/*.eclass | sort -n [ ... ] 1299 /usr/portage/eclass/python-utils-r1.eclass 1337 /usr/portage/eclass/kernel-2.eclass 1528 /usr/portage/eclass/mysql.eclass 1794 /usr/portage/eclass/eutils.eclass 2265 /usr/portage/eclass/toolchain.eclass 2771 /usr/portage/eclass/java-utils-2.eclass 3181 /usr/portage/eclass/python.eclass
- deleted 11y ago[deleted]
- skatenerd 11y agoHow many people do you know who think that Git and GitHub are the same thing?
- accatyyc 11y agoQuite a few. Especially our designers/people that doesn't commit/use git very much but still have to use it, have a hard time grasping the difference. The git client they're using being called "GitHub" doesn't make it any easier!
- fibo 11y agoI was really lucky I could met Ingy at a Perl conference. He is a really kind person and a mighty coder. He wrote also many other creative pieces of software, very powerful stuff like IO::All. Ah, and he is the creator of YAML! Big respect!
- rcthompson 11y agoThis is great. I was just looking for a way to merge pull requests from the command line today. (By which I mean fetch the branch into my local repo and perform the merge with git, not just having a bash script to press the merge button on Github.)
- accatyyc 11y agoI hope this is very ironic (?) edit removed unnecessary comment. What I mean is that you can already do this with git, nothing else required. git remote add fork fork@github.com && git merge fork/pr-branch
- gbtxg 11y agoWell actually you can do it without even adding a remote. git pull https://github.com/otheruser/repo.git branchname so your example will become git pull fork@github.com pr-branch
- rcthompson 11y agoYeah, I want to do it without adding a remote for every person who sends a pull request. I presume this is git with the "hub" wrapper provided by github? Oh, and I know I can pull directly from the appropriate URL, but I still have to browse to the pull request to get the URL for the associated branch. At that point I may as well just hit the merge button while I'm there.