Honestly: I hate git

                       Sequel 348

                 What happened until now

I have written a small script. Because of trouble using git because I was not able to upload the offline files to the new empty online repository I have uploaded the files via the Github page last night in the online new created repository.

Now I fail to add / upload changes I’ve made offline.

Currently I have no clue how to handle it. I’ve tried “git rebase” and now “git init”.

            Will Bernd solve this issue in this sequel
               or will he leave this project for ever?

                                Stay tuned!

Bernd in his coding cabinet staring at a pale green glowing screen, mumbeling:

Better than trying to understand that git / Github mess currently seems for me

  1. to rename my offline folder,
  2. clone the online repository,
  3. copy the changed files in the new folder with the cloned online repository,
  4. add,
  5. commit and
  6. push them.

Git and Githib do make more stress than coding a MB application. It’s a mess, absolutly overcomplicated.

Loudly finally he says: How can I upload the changed files with git to Github? Mumbling again: And where is a caffeine drink?

You shot yourself in the foot by re-initializing the local copy of the repo.

Your six steps seem fine.

1 Like

Hi @BerndStorck!

I feel you. Git honestly has a pretty steep learning curve which can be extremely frustrating. Once you get your workflow down though, it gets a lot easier.

As @kingthorin said, your steps for getting back into the flow seem good. There are other ways to troubleshoot issues and such but sometimes just starting clean from scratch with your local repository is just the easiest way of going about things.

When you need to sync your local repository with your remote repository before making changes to your code, run git fetch which updates your branches.

Have you taken a look at the GitHub Guides? The Understanding the GitHub Flow guide and the Hello World guide are ones that helped me a lot when I was first getting started learning Git. I think they do a decent job of breaking down the fundamental concepts.

Hope that helps!

2 Likes

Hi @that-pat, hi @kingthorin!

Thanks for your both answers. :slight_smile:

I’ve done it with the 6 steps above, and it has worked.

@that-pat:
I have looked at some tutorials and some basic videos about git and Github. But every – even very good – introducing video I’ve seen at Youtube has shown only a special way and situation. If you are one step aside those special short shown use cases, you are lost because of missing knowledge.

I plan to buy and read a book about git, but in the last time my days are consumed by grooving my abilities and knowledge in programming Bash scripts. One of the last steps is sometimes to publish a script at Github after I’ve coded and tested the script for a while. At this point I mostly need rather sleep than – in those moments to me – a little bit prissy appearing tool named git. :wink:

I will look at the linked learning resources (again) and study them.

Thanks for your friendly answers!

For German speaking linux friends, it might be not bad to visit: https://www.facebook.com/BStLinux There I discuss and share issues about Linux and Bash Scripting.

I just use SmartGit. I only deal with the command line version for occasional weird cases that it can’t handle.

1 Like

I’d recommend reading this free book: https://github.com/pluralsight/git-internals-pdf

For me, that was exactly what took all the guessing away. I understand git now from the inside and what to do, when and how. Short and easy read.

1 Like

GitKraken is by far the best Git client I have used, I highly recommend it. I haven’t used the Git command line in forever. It has made onboarding new devs with little to no Git experience much easier.