Open cubuspl42 opened 5 years ago
All your points are really excellent. In order:
but without the need to install yet another command line tool if we already have
hub
.
👍
It would be even better if after
hub clone ...
-> "Permission denied (publickey)" errorhub
could ask "Would you like to add your local SSH public key to your GitHub account?".
YES this is a really great idea 👏 I don't think there's need for a specialized command if hub
would automatically manage the user experience like this.
Generating new ssh keys would be fine too!
Generating new SSH keys is such a sensitive process that I would always suggest to any user that it should be done as it's own step and that hub
should not try to encapsulate that experience. Although, hub could help you get on the right track when doing it, e.g. by outputting example commands that you could run.
I'm aware that there's a (closed) issue #611, but I'm struggling to understand the motivation behind closing it.
That one is simple for me to answer. Lots of people have had great feature ideas for hub over the years, but there was mostly just me as a maintainer for. Therefore, I tend to be on the defensive against new features, especially if they involve defining new hub commands. For every idea that I evaluate, I ask myself:
If the answer to any of these is "no" or "I'm not sure", I don't feel comfortable greenlighting someone to submit a PR.
https://twitter.com/slicknet/status/471834362950844416 https://twitter.com/peterbourgon/statuses/853268787398934528
1. When I run
hub clone <reponame>
it uses SSH by default
That's true, but I wanted to change that default for years now and never gotten around to actually doing it. We at GitHub generally recommend HTTPS.
But I see what you're saying— if SSH is our default, then we should have made the experience of setting up cloning from GitHub over SSH a better one.
4. SSH is one of two primary protocols of git, and some users just might prefer it over HTTPS for any reason
For sure! Many users still use SSH and we will continue to support it in hub. I think hub being more helpful around SSH authentication errors and helping you to set up and upload your SSH key would definitely be the way to go. 👍
It would be awesome if
hub
had an option to add a local SSH key to GitHub. Basically something like ssh-keyreg, but without the need to install yet another command line tool if we already havehub
.It would be even better if after
hub clone ...
-> "Permission denied (publickey)" errorhub
could ask "Would you like to add your local SSH public key to your GitHub account?".Generating new ssh keys would be fine too!
I'm aware that there's a (closed) issue https://github.com/github/hub/issues/611, but I'm struggling to understand the motivation behind closing it. The closing comment has a score of -10 and mentions that HTTPS is better, or something like that. But:
hub clone <reponame>
it uses SSH by defaulthub
could automateI'm totally aware that it's an open source project (thank you for it!). Nobody says that it needs to be implemented right now, but I believe that leaving this feature request open would be a good opportunity for people to comment and leave their opinions.