blitzcode / hue-dashboard

A web interface for monitoring and controlling Philips Hue lights
http://www.blitzcode.net/haskell.shtml#hue-dashboard
279 stars 23 forks source link

Suggest changing to anon github protocol #2

Closed pc-mreeves closed 7 years ago

pc-mreeves commented 7 years ago

I am working on a fork to use Vagrant to create a standalone machine running your app and I was finding I needed to forward my ssh agent from my client. The root cause is: On https://github.com/blitzcode/hue-dashboard/blob/7d7611485db55d60309ca34584f3552cd0b8ce53/stack.yaml#L11

I suggest you change this from:
git: git@github.com:HeinrichApfelmus/threepenny-gui.git
to:
git: git://github.com/HeinrichApfelmus/threepenny-gui.git which will change the protocol from ssh to https. Even though the docs say the user needs to login with creds when using git clone this does not seem to be the case.

so the user does not need to have a github account and public key setup.

This behavior can be reproduced by temporarily moving your id_rsa and/or id_rsa tokens to another directory and running: git clone git://github.com/HeinrichApfelmus/threepenny-gui.git which works and
git clone git@github.com:HeinrichApfelmus/threepenny-gui.git which does not.

Regardless I will probably add this to my eventual PR which I am not sure if you will accept or not.

Thanks for your creation!

blitzcode commented 7 years ago

Interesting, thanks for your explanation!

I actually experienced this issue myself when I cloned the project from a machine without my SSH keys present. It seems I fixed it when I was using my own threepenny fork and promptly reintroduced it when switching over to a revision from the official repository...

As you can imagine, I'm somewhat unhappy about referencing a repository revision instead of a Hackage release for threepenny here. Especially in the stable master branch. The in-progress version of threepenny fixes some long-time & very important bugs and I thought these improvements are so significant that I really want them in master now where everybody benefits from them.

We should have a new threepenny release 'real soon now' and then the repository dependency will be gone and I'll make a 1.2 release of hue-dashboard.

pc-mreeves commented 7 years ago

Cool! I actually was slightly in error. The http protocol also appears to not need auth for clone requests. But what I described and showed above is the git protocol.

Here is more info on the distinction between ssh/git/"smart" https/ "dumb" https/local: https://git-scm.com/book/en/v2/Git-on-the-Server-The-Protocols#_the_git_protocol

blitzcode commented 7 years ago

Yeah, I used https last time, but switched to SSH for unclear reasons when I pointed back at the official repository. I guess I just copied whatever was convenient from GH's history browser. Let's hope there's an 8.0 release soon and I can just pull from Hackage again.