OS2 World Community Forum

OS/2, eCS & ArcaOS - Technical => Programming => Topic started by: Jochen Schäfer on June 13, 2017, 11:32:16 pm

Title: Can't push to Github.
Post by: Jochen Schäfer on June 13, 2017, 11:32:16 pm
After installing ArcaOS, I installed Git via RPM.
Now I want to push to Github. git asks my username and password, which entered multiple times.
But it tells me that it can't access the HTTPS address and that the server returns 403 (Forbidden).
What do I have to configure, to make that work?
Title: Re: Can't push to Github.
Post by: Martin Iturbide on June 14, 2017, 07:00:59 pm
Hi Jochen.

Some time ago I wrote (with collaboration of more people) this article:
http://www.edm2.com/index.php/Using_Git_under_eComStation

There are two similar errors I got with git, but when I was cloning. Check the "Errors" part of the article to see if it can give you some hint.

Regards
Title: Re: Can't push to Github.
Post by: Martin Iturbide on June 14, 2017, 07:16:09 pm
Hi

Just in case I created a txt file and push it into a test repo to see if it works. I pushed it via Command line.

[C:\projects\Gittest\Warp-WPS-GUI_Tests]git push https://github.com/martiniturbide/Warp-WPS-GUI_Tests.git

It worked fine and pushed "example.txt" on https://github.com/martiniturbide/Warp-WPS-GUI_Tests (https://github.com/martiniturbide/Warp-WPS-GUI_Tests).

Regards
Title: Re: Can't push to Github.
Post by: Dave Yeo on June 15, 2017, 02:25:26 am
It should just work if you're pushing to the correct URL. It is possible you might need some certificates, installed with OpenSSL IIRC.
Title: Re: Can't push to Github.
Post by: Jochen Schäfer on June 15, 2017, 10:51:53 am
The clone from the repo went well, so I would guess that the URL is correct.
I will look at cert issue.
Title: Re: Can't push to Github.
Post by: Martin Iturbide on June 15, 2017, 05:00:52 pm
Hi Jochen. What is your Github ID to also follow you there?

Regards
Title: Re: Can't push to Github.
Post by: Jochen Schäfer on June 15, 2017, 05:22:47 pm
It's josch1710.
Title: Re: Can't push to Github.
Post by: Jochen Schäfer on June 15, 2017, 09:38:09 pm
Ok, Git is weird. It was indeed the wrong URL, but other than one would think.
I tried to push upstream, i.e. the CC65 repo, not my forked one.
That was indeed forbidden.
So case closed. The leson always watch the checkout branch.
Title: Re: Can't push to Github.
Post by: Dave Yeo on June 16, 2017, 01:24:56 am
If you look in .git\config, you'll find the remote URL under the remote "origin" section. You can change this if desired. There's a git command to do it too. You can also pass the URL on the command line.
Title: Re: Can't push to Github.
Post by: Jochen Schäfer on June 16, 2017, 08:11:41 am
Yes, I totally know that. The problem was not the origin remote, that pointed to my repo. I also have a upstream remote pointing to the CC65 original repo.
I wanted to merge upstream to my repo, but it seems I checkout out upstream instead. The when I wanted to push it, it was correctly push upstream.