• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Standard for sending commit messages?

Status
Not open for further replies.
Level 15
Joined
Aug 7, 2013
Messages
1,337
Hi,

So I've got a project under version control, and I make changes in bulk, partially because a lot of the code is intergrated with the rest, so changing one system/class can affect many other parts of the code.

Needless to say, making one change to overall code results in around ~100 differences between the version in the repo and the local version on my side.

All of these changes are meaningful, so I think for good documentation I should send commit messages with each change. What I've done is grouped some of the changes, which brings it to about ~30 commit messages every major update.

Is this normal? I've just found it tedious to write each commit message for each commit.
 

Dr Super Good

Spell Reviewer
Level 63
Joined
Jan 18, 2005
Messages
27,188
Sounds like you have very poorly defined interfaces and far too much coupling. The idea of interfaces is to minimize the scope of changes to within a single component. This way you can update part of the code (the implementation of the interface) without having to update all users of the interface. Interface modifications will always be very large commits which is why they are best avoided.

In the case of interface modifications it is often best to migrate rather than change. This means your old existing interface is marked as deprecated while the new interface is added in parallel so part of the program can continue to function unchanged while new parts or maintained parts can be migrated to use the new interface. Eventually when no more references to the old interface exist you can remove it.
 
Level 15
Joined
Aug 7, 2013
Messages
1,337
Interface modifications will always be very large commits which is why they are best avoided.

I see. Well I've kept changing the overall API / interface as my knowledge increased and I learned more.

Sounds like you have very poorly defined interfaces and far too much coupling.

I posted a thread about fixing this issue. I don't suppose you could offer some suggestions to get rid of a bit of inter-dependence?
 
Level 29
Joined
Jul 29, 2007
Messages
5,174
How about just have fun programming instead of opening a new thread of "is there a standard for X" every two days?

No, there isn't a standard for anything, unless you work in a company with its own standards.
Yes, you should improve your API carelessly, unless you work in a company or/and have millions of lines of code...

Just write in the commit whatever makes sense to you to write. That message is for no one but you (...unless you work in a company).
 
Level 15
Joined
Aug 7, 2013
Messages
1,337
How about just have fun programming instead of opening a new thread of "is there a standard for X" every two days?

Well I'm trying to learn, I don't think there is a forum rule against that, considering that this is also part of the off-topic posts?

I'm active on the hive because the members here are both very knowledgeable and friendly, not something that is true for many forums (e.g. many very smart members but they aren't particularly nice to newbs, or friendly people but don't know what they are actually saying).

Just write in the commit whatever makes sense to you to write

Well I actually was working for a R & D company and we used SVN for the project but I didn't think I did good documentation, especially with commits.
 
Status
Not open for further replies.
Top