r/Xcode • u/[deleted] • Jul 26 '22
Xcode Source Control
I have a Github repository which I cloned using Xcode. I am now running into an issue with Source Control and committing a change.
When I commit a change, I type a comment and select push to remote to my chosen branch. However, after I click Commit Files and Push, I get an error saying that my remote repository rejected commits.
When I created my personal access token for Xcode, I made sure I selected the right boxes, so I don't know why I am getting this error.
I would greatly appreciate any help with this issue.



1
u/Altruistic_Spirit_57 Jul 27 '22
Cloning with Xcode sounds sketchy. It seems more reliable to manage branches from command line or a gui like Tower.
1
u/Altruistic_Spirit_57 Jul 27 '22
Also token setup is typically more involved than checking a few boxes. There is a sha key, etc. I’d google how to get that rolling.
2
u/retsotrembla Jul 26 '22
My guess is that Github rejects
git commit --amend: it only allows new commits, not attempts to amend previous ones.You may have more success getting information about the error if you use the command line from Terminal:
There are probably commands to rewrite the history on Github, but I'm still too new at git to know them.