ProgrammerHumor

initialCommitViaCLIBeLike

initialCommitViaCLIBeLike
https://i.redd.it/6fw35i7aj9cf1.gif
Reddit

Discussion

HappinessFactory

I love this gif

1 day ago
Mr_Potatoez
:unity:

Use this: https://education.github.com/git-cheat-sheet-education.pdf

1 day ago
cjb3535123

He is. He said he had to use a cheat sheet every time.

1 day ago
DefinitelyNotMasterS

I just press the green button in my IDE

12 hours ago
The100thIdiot

Or just use a gui like github desktop.

Fuck remembering commands when you can just click.

14 hours ago
photogdog

If you have the right permissions, you can use --force to get past a lot of issues with git.

git add .
git commit -m 'bug fix and stuff'
git push origin master --force
1 day ago
worked-on-my-machine

wow brb bro gonna go do this on one of the repos at my job

23 hours ago
markiel55

Also, don't forget the good ol' git branch -D main

18 hours ago
beisenhauer

What's hard to remember about git push?

1 day ago
exnez
:cs:

terminal scary

1 day ago
Skibur1

It’s all and great until you’re a few commits behind and merge conflicts happen…

1 day ago
Kitchen_Device7682
:sc:

fatal: The current branch has no upstream branch

22 hours ago
beisenhauer
git config set push.default simple
git config set push.autoSetupRemote true

Set it and forget it.

More good config suggestions here.

11 hours ago
AppropriateStudio153

I have several ideas why that might not work.

  • You haven't added new files or have no tracked files. *  You have tracked files, but you did not commit them.
  • You have committed them, but remote is ahead, and your changes cause a conflict, which leads to a rejected push.

In all these cases git push won't help you, as a single command.

1 day ago
exnez
:cs:

This why terminal scary

22 hours ago
Luneriazz

conflict merge

20 hours ago
InTheEndEntropyWins

Sounds like you are working on a small project by yourself. When you are working on larger projects with multiple people you can't just git push by itself.

14 hours ago
beisenhauer

Sounds like you work on projects where you just push to main without a well-defined code review/merge process.

11 hours ago
InTheEndEntropyWins

Sounds like you work on projects where you just push to main without a well-defined code review/merge process.

You don't just do git push to merge a branch.

11 hours ago
exnez
:cs:

GitHub desktop or VSCode built-in Git extension. Never had to write a command

1 day ago
big_guyforyou
:py:

i'm so lazy that once the CLI stopped working for me I just used the github website.

i did google the problem, though. i think i had to delete an old password from the keychain but i couldn't figure out how to do that. like i could literally see what to click on but i couldn't click it

1 day ago
TheGreatSausageKing

People like terminal because they think it makes them look smart.

I never used and never will, there is a reason we moved from msdos to windows.

1 day ago
exnez
:cs:

How else were we gonna play GTA 6?

1 day ago
TheGreatSausageKing

Hahahaah good one

1 day ago
Gysenok

Not every computer has a gui, especially servers. Also not every ide has buttons for using git. So if you want to have version control on a remote server you need to use cli/terminal

1 day ago
TheGreatSausageKing

If you are commiting from a server, I'm sorry,

There is GitHub desktop which is freem

Whoever is programming on a remote server, I'm sorry for you..

1 day ago
delayedsunflower
:cp::cs::py:

I program on a remote machine. It's fantastic and has literally hundreds of times better hardware than my laptop. I can WFH and literally program on a beach and have all the hardware I want and not step a foot in an office. It's all mostly done through ssh and CLI because remote desktop software is pretty slow and clunky.

You should try it it's great.

23 hours ago
TheGreatSausageKing

It's awesome but it's clunky ?

21 hours ago
Jk2EnIe6kE5

Remote desktop software is clunky. They're using SSH, which is a terminal-based remote access program.

20 hours ago
delayedsunflower
:cp::cs::py:

Remote desktop software is clunky and slow.

Using the command line is fast and awesome 

9 hours ago
TheGreatSausageKing

Maybe use remote desktop in command line with ASCII drawings then.

Also , go back to the 80s and pretend you are smart

8 hours ago
delayedsunflower
:cp::cs::py:

I'm not trying to be holier than thou.

I'm saying you should try programming remotely - it's pretty neat

7 hours ago
TheGreatSausageKing

There is no reason I would try such BS if I already own a decent machine. Which I can use through parsec or moonlight if I want to program remotely.

Moreover, both would support GUI for git and i would never use command lines.

In the end , it's always this. Programmers screwing themselves because they can

"Your (programmers) Were So Preoccupied With Whether Or Not They Could, They Didnt even think if they should"

7 hours ago
Gysenok

Github desktop is not officially supported on linux, so unless you're using git exclusively on windows and Mac it's not an option. Maybe it's a strong opinion but the need for a gui application to have version control seems way too big of a crutch for me. As a programmer a basic understanding of the terminal is (at least in my experience and opinion) expected, the need to click through menus seems unnecessary and a waste of time compared to using the terminal. And git cli is universal, gui applications for git are not.

1 day ago
Darder

Your opinion is fair. You can decide not to use a GUI.

I don't feel it's a big crutch. Git GUI are plentiful under any platform. And they simplify a lot of the daily commands to do. I used both command line and GUI, and I find GUI much quicker to commit stuff, rebase, solve merges than using the CLI. But I use Fork now, because Github For Desktop was a hassle with many advanced functions and GitKraken was too complicated for me.

To me, writing out the commands for git is slower than clicking 3 buttons (stash all, and commit, and push). Not to mention learning the in-depth stuff or how to fix git issues using CLI.

8 minutes ago
exnez
:cs:

If you’re using Linux, you’re a command geek anyways

23 hours ago
Gysenok

Yeah, my view is biased however at my university we were also taught the basics of git with the command line even though most users were using windows. Though some people still used the ide commit and push afterwards

13 hours ago
TheGreatSausageKing

As a programmer, basic understanding of terminal is just bullshit. We just need to get thing done with the least effort.

Anything you add because you feel like you should use it know is just for your ego

21 hours ago
No-Article-Particle

I use terminal because it's the environment that is most comfortable and convenient to me. In a job, it's also very common to dev/deploy/test on remote servers, so that terminal might be your only choice.

14 hours ago
The-Chartreuse-Moose
:powershell::bash::cs::j::py::terraform:

Some people apparently have a fear of commitment. But seriously: learn the commands by using them!

1 day ago
_sweepy
:cs::ts:

sourcetree

1 day ago
grasopper

I'm even worse than that guy. I use the tool in visual studio

22 hours ago
MinosAristos
:py: :ts: :cs:

VSCode UI does the important stuff for you

1 day ago
elderron_spice

There are a ton of git clients out there. I used SourceTree when I started, and it eased me up into git since it also displays the commands it uses to fetch, checkout, create pull requests, prune, rebase, etc.

1 day ago
AWzdShouldKnowBetta
:kt:

It's been a long time since I actually laughed out loud on this sub. Nice one!

1 day ago
Wizado991

I get why people are uncomfortable with it but it's like everything else. The more you use it the better you get with it. If you let yourself use one of the graphical apps to do git for you, you won't ever learn how to use the tool.

20 hours ago
livingMybEstlyfe29

pwd git status git add —all git commit -m “I love git” git push git status

21 hours ago
InTheEndEntropyWins

I want to share this at work, but probably not appropriate.

14 hours ago
KillCall
:py:

3 git command to remember.

Git add

Git commit

Git push

Everything else look up on the internet as they come up.

14 hours ago
doSmartEgg

git add, git commit -m, git push -u origin main

10 hours ago
DearChickPeas

The only thing more scary than a CLI e is a GUI client, apparently. Its like were still in the 90s

9 hours ago
Darder

Hot Take: I think using the command line for git is trash and should be left to experts, and everyone else should just use a GUI.

Hear me out. It's just like with any technological advancement and helper software. Sure, you can do everything from the command line. But it's not intuitive, it takes more effort to learn, and it does not provide a significant advantage for the average programmer compared to a GUI. Why stop others from having it the easy way?

I also heard some people say "You should start coding using notepad, that way you won't have the IDE as a crutch" and I think it's a silly advice. Just find a good GUI for git. The day something goes wrong that you can't use the GUI for, then open the command line and google for a way to fix it. Until then? Screw that, use a good GUI.

It's 100x easier, more convenient, quicker, and it does allow you to do a whole lot more than the command line IF you are inexperienced in git! Resolving merge conflicts through the command line sucks ass. Doing it through a GUI? Super easy and understandable, even as a beginner.

So yeah. Just use a GUI. And while I'm here, skip GitHub for Desktop.... Go with Fork. Fork is awesome.

15 minutes ago
Raemos103

git rebase -i is the only command you'll need to know other than commit and push

1 day ago
asd1o1
:c:cp:asm:py:j:

git stash

git switch

git restore

...

git pull

1 day ago
[deleted]

rebase is dirty

1 day ago