769
you are viewing a single comment's thread
view the rest of the comments
[-] Pacmanlives@lemmy.world 18 points 11 months ago* (last edited 11 months ago)

git commit -m “changed somethings “

git push origin master

[-] MajorHavoc@lemmy.world 15 points 11 months ago

You forgot this --force flag.

[-] Valmond@lemmy.mindoki.com 7 points 11 months ago

I'm too lazy, I use -f

[-] jelloeater85@lemmy.world 1 points 11 months ago

Do you always have to do origin master? I've seen it where sometimes just git push works and other times not.

[-] adrian783@lemmy.world 3 points 11 months ago

uh in any actual company you almost never push to origin master. so I think it's a joke.

[-] MajorHavoc@lemmy.world 6 points 11 months ago
[-] jelloeater85@lemmy.world 4 points 11 months ago

Force push Fridays!

[-] herrvogel@lemmy.world 1 points 11 months ago

In most actually companies you can try push to origin master, but it'll likely get rejected by the repo's security policies.

[-] Valmond@lemmy.mindoki.com 1 points 11 months ago* (last edited 11 months ago)

Depends on the configuration right?

You can work on your branch and then push that to integration for example.

I mean you're not working on your local master/main branch right?

[-] Valmond@lemmy.mindoki.com 2 points 11 months ago

push origin your/branch

Pushes, you guessed it, your/branch!

Head is usually your checked out working branch if you're not in a headless state, right?

[-] jelloeater85@lemmy.world 3 points 11 months ago

Force push main, straight to jail🤣

Yup yup, usually you're on a branch, sometimes a tag. I mean it's all just pointers to references at the end of the day. I tend to treat Git like a story book, some folks still act like it's SVN.

[-] zcoyle@programming.dev 2 points 11 months ago

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

[-] Meowoem@sh.itjust.works 1 points 11 months ago

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

[-] jelloeater85@lemmy.world 1 points 11 months ago

I just meant it not auto creating a new matching named branch.

[-] TheUncannyObserver@lemmy.dbzer0.com 0 points 11 months ago

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.

this post was submitted on 12 Dec 2023
769 points (99.0% liked)

Programmer Humor

19480 readers
204 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 1 year ago
MODERATORS