I was being more evil than that, saying that if one is gonna push direct to main, might as well maximize the possible damage to everyone else’s branch.
I think it depends what branch your local version of the repo is set to. If you’re already in master then it’ll push there, if you’re in a testing branch then you can push it straight to master instead by telling it to
Do you always have to do origin master? I’ve seen it where sometimes just git push works and other times not.
I was being more evil than that, saying that if one is gonna push direct to
main
, might as well maximize the possible damage to everyone else’s branch.Lol why not just delete the whole project from GitHub… I mean, everyone has a copy, right?😱
where it Just Works, the branch is set up to track a remote branch
https://git-scm.com/book/en/v2/Git-Branching-Remote-Branches
https://git-scm.com/docs/git-push#Documentation/git-push.txt-pushautoSetupRemote
I tired that, still was having issues, weeeird.
uh in any actual company you almost never push to origin master. so I think it’s a joke.
Not with that attitude! /s
Force push Fridays!
That’s part of the joke, I think. If it’s a repo more than just you use, you would almost never push directly to the main branch.
I think it depends what branch your local version of the repo is set to. If you’re already in master then it’ll push there, if you’re in a testing branch then you can push it straight to master instead by telling it to
I just meant it not auto creating a new matching named branch.