this post was submitted on 10 Oct 2024
1 points (53.8% liked)

JetBrains

199 readers
2 users here now

A community for discussion and news relating to JetBrains and its products! https://www.jetbrains.com/

Related Communities

Copyright ยฉ 2000-2024 JetBrains s.r.o. JetBrains and the JetBrains logo are registered trademarks of JetBrains s.r.o.

founded 1 year ago
MODERATORS
 

After seeing people use the @jetbrains UI to commit to git I understand where all those - sorry: shitty - commit messages come from....

๐Ÿ™ˆ

An improvement would already be to have a "Subject" line and the text box.

And have the subject line follow the Beams Rule.

Sonthat the first line of the commit message finishes the sentence

"When this commit is applied it will..."

And please: No longer than 56(?) characters (Unicode). Keep it short. You got the textbox to explain *why* in full length.

top 34 comments
sorted by: hot top controversial new old
[โ€“] [email protected] 9 points 4 months ago (1 children)

Software is not responsible for content. Software could help writing better commit messages, but at the end it is the developer who has to improve his messages and mindset.
A shitty text will keep shitty nevertheless if it's written in a simple text editor or in Word ๐Ÿคทโ€โ™‚๏ธ
IMO .gitmessage Templates can help - but it's also not the solution. The solution sits in front of the monitor.
@heiglandreas @jetbrains

[โ€“] [email protected] 4 points 4 months ago

@Xitnelat Indeed. But software can help.

After all an email editor also has different fields for different content, while it is perfectly possible to write an email.with a texteditor.

And while everything is possible, the "Subject line, empty line, Body (empty line, trailer)" is what it's intended to be.

So why not help the person in front of the monitor with that...

/cc @jetbrains

[โ€“] [email protected] 6 points 4 months ago (1 children)

@heiglandreas @jetbrains are you writing commit messages on a Nokia 3320? Even limiting at 80 had some meaning, but 56 is just an arbitrary low number that sometimes requires an English Masters degree to achieve.

[โ€“] onlinepersona 0 points 4 months ago

56 characters is ridiculous ๐Ÿ˜‚ We're not in the hole-punching era of computing. We have screens with resolutions that can easily fit 200-300 characters horizontally. My wraps across nearly everything are 100 characters.

Even code at 80 characters I find a joke from the era of 80 character terminals forcing people to have variable names like mCar, pItm, ctx, ptc, hln, vln, l for list, m for map and so on. Sure, it fits in 80 characters, but you might as well be reading obfuscated code.

Anti Commercial-AI license

[โ€“] [email protected] 3 points 4 months ago (1 children)

@heiglandreas @jetbrains What if you want to use Conventional Commits instead of Beams? ๐Ÿ˜‰

[โ€“] [email protected] -1 points 4 months ago (1 children)

@ramsey Just: Don't.

The subject lines space is limited and should not be wasted for stuff that doesn't belong there.

Also the prime idea behind conventional commits is to add machine readable info.to the commit message: Fine. Do so. The commit.meysage can be as long as you want. Add it there. Keep the subject line to the human readable part.

Also: Creating changelogs from.git.commits is *not* what chamgelogs are there for.

Keep a changelog can help on *that* front.

@jetbrains

[โ€“] BatmanAoD 3 points 4 months ago* (last edited 4 months ago) (18 children)

Why should I put manual effort into separately maintaining a changelog and a semantically meaningful commit history? If I'm going to manually maintain atomic commits with useful commit messages, why would I want the contents of those messages to be substantially different from the content of the relevant bullets of the changelog?

[โ€“] [email protected] 1 points 4 months ago

@BatmanAoD Because they serve a different purpose.

Purely semantically a changelog is something different than a git log (otherwise it would be named a git log).

The changelog is more a log of merges that describes the main overview of new features and also bug fixes.

If I want to know the exact details why this line of code changed, *then* I look at the git log.

Having all atomic commitlogs in the changelog tells the user that you are too busy fixing code to give them a meaningful summary

load more comments (17 replies)
[โ€“] Cyno 3 points 4 months ago* (last edited 4 months ago) (1 children)

One more reason why Git-Fork is the GOAT - it does have separate subject and description fields. Don't lump all GUI tools in together and generalize

[โ€“] [email protected] 0 points 4 months ago

@Cyno IIRC I explicitly talked about the Jetbrains UI.

Others I didn't check and mean! Sorry if it came across like that!