At the moment of writing this I’m in the final month of my internship. I am slowly realising how much I have learned in the past few months. But of...
For further actions, you may consider blocking this person and/or reporting abuse
Hi Imani, thanks for your post! Didn't know there was a spec about git commits and it's very interesting! It really makes sense since we tend to be "conservative" about explaining commits usually.
In addition you might want to setup a template (basically put the template you explained up there in a template file :D) for your Git commit messages, so that it can help you and the people you collaborate with, with something like:
Another feature I did not know about! This one will be very useful, thanks for sharing ✨
I've used GiT for over a decade and did not know about this. TYVM @rhymes and @Imani.
Great post about conventional commits Imani! We've been doing it for a year now at Peakfijn (a company I work for), and I never want to go back. We've had some discussions within the team about the types we need and eventually, we created our own type-list based on Angular conventions.
Our biggest problem was to get everyone committing valid commits. Along the way, we found some great tools which can really help. Especially when combining this in an automated continuous integration system! Hope it can help anyone :)
Disclaimer; I became one of the maintainers of Commitlint and wrote an Expo plugin for Semantic Release
I'd also add commitizen to that list. It walks you through the steps, at commit, to get the message correct without having to memorise the syntax.
Really great when used in combination with the above tools.
These are some gems! I'll definitely try them out in my upcoming projects :D
Also check out sethrobertson.github.io/GitPostPro.... It discusses how to take a lot of smaller commits (which is a good practice of course) and use git rebase to make a single, well documented commit to push.
I'll definitely check it out, seems like that one thing I'm still missing in my current flow
git -a -m "message"
can be shortened togit -am "message"
btw 😊Neat!
I think active voice would make it even better, eg:
There are also more fun ways using emojis for commit categories. Have a look at these projects:
But the development team should be not too serious in their ways of working if you choose these.
I am guilty of using emoji's in my commit messages when I'm building small homework assignments I had no idea people have created 'specs' for this 😂
Hi Imani, thanks for sharing your experience with us! When I started using git, I was the same way when creating my commit messages.
I did mostly to save progress or bundle all the changes to have one commit. After getting more involved in the dev community and discovering resources. I was able to discover The seven rules of a great Git commit message. This convention has similar rules to your specs. If you really want to enforce these rules, you can create a template as well as git hook so it won't let you commit unless it meets the criteria you set.
"When using conventional commits I can't just collect all the changes I have made in a single commit."
I use to do this. Make a lot of changes in many files and dump them in a single commit. Now I commit small and often. But since the commits are small, I try to use as few words as possible, for the commit message. This results in non-descriptive commit messages.
I have to spend a bit more of my time on writing better, descriptive commit.
Thanks for your post.
Messages are really a pain at times, I really hope this helps 😊
I've fallen into the trap of trying to follow conventional commits only to forget or make a typo which will get pushed. So I made Sailr [1] which is an installable Git hook to help you follow the standard. It's flexible and configurable so you can adapt it to your own implementation.
[1] - github.com/craicoverflow/sailr
Add partial file Commits to your tools if you haven't already.
Partial Commits with Git
Jesse Phillips
I've started pushing to bring this conversational commit to my work.
Nice, I'll definitely try it out :)
It perfectly works on Windows too!
Lesson learnt here😊. Thanks Imani.