R
22

My first github commit was a disaster compared to what I do now

I used to write code in one giant file and just pray it worked before pushing it straight to main. Last year I finally started using branches and pull requests after I broke a team project 3 times in one week. Now I write small functions, test them locally, and commit with messages that actually say what I changed. What was the biggest change in how you code from when you started vs now?
2 comments

Log in to join the discussion

Log In
2 Comments
jordanm19
jordanm1918h ago
Read a blog post once that called it "code archaeology" when you have to dig through your old commits to figure out what happened. That stuck with me because I used to leave messages like "fixed stuff" and then wonder why past me was such a troll. Now I treat commit messages like notes to my future self and it honestly saves hours of confusion.
7
wendyc53
wendyc5321h ago
Small functions and testing locally are the real game changers. "Praying it works" before pushing to main is basically gambling with your team's sanity. Branches and PRs are good but breaking down code into tiny pieces is what really saves everyone time.
4