Comments (17)
I think this is a good thing to do. I would suggest we ask that commit comments follow a format similar to this:
Simple Description
Detailed information if required
Issue: #
Signed-off-by: First Last
from omr.
Overall, I agree with this approach but expect that trivial changes (spelling fixes, etc) can be done without an issue.
Doing a bit of reading, in particular [1], indicates:
Unless you are making a rather minor change, it is generally a good idea to file an issue on the appropriate bug tracker, explaining your idea before writing code or submitting a PR, especially when introducing new features.
which is the kind of wording I think we should adopt.
[1] https://contribute.jquery.org/commits-and-pull-requests/
from omr.
It sounds like we don't want to use the github feature of closing issues via commit comment, right?
It's helpful to put the Issue # in the first line of the commit comment so that you can get a quick overview using "git log --oneline".
I suggest tweaking the comment template to this:
Issue #nn Simple Description
<blank line>
Detailed information if required
Signed-off-by: First Last <email>
from omr.
I don't mind not having an issue for truly trivial patches, but I think any multi-commit piece of work should be tied together by having an issue number which is referenced in the commit comments.
I don't care whether we use an issue number or pull request number, but a pull request number doesn't seem to work well since it doesn't exist until after you have made a bunch of commits and created the pull request. You would have to edit every commit on the pull request branch to add in the pull request number.
from omr.
How about:
#n Short, simple summary
Detailed information if required
Signed-off-by: First Last <email>
That's simple, puts the issue number (I'll make sure its described as the Issue number and should not be the pull request number) into every commit title. I suppose the recommendation would be to follow the same form in the pull request, which at least makes it easy to describe.
If no additional concerns, I'll commit this change tomorrow.
from omr.
Looks good to me.
from omr.
+1
from omr.
Amusing: # starts a comment so the first line cannot start with that. D'oh!
I recommend we give up on a "rigid" positioning of the issue text and just say the title has to have #N in it somewhere.
from omr.
+1
from omr.
As long as we can write tooling that finds it (and doesn't get too many false hits), fine with me.
from omr.
Hmmm I made some commits today that started with # and it appears in the text for the commit. You are right though that lines starting with # are supposed to not show up.
I guess I should go update my commit messages.
from omr.
The suggestion was to specify that "#n" needs to appear somewhere in the message. That's enough for github to find the link.
I see your commits on #64, Charlie. How did you do that? When I tried it, git commit failed saying my commit message was empty (and it actually was :) ). The only difference I see is that your commits also had detailed comments whereas mine did not. No idea why it didn't treat your title line as a comment.
Weird. But your commit message still fits the template as suggested :) .
from omr.
I agree with @charliegracie on this:
If we are not rigid then people will not do it ...
from omr.
The rigidity comment was only about the positioning...
from omr.
http://stackoverflow.com/questions/2788092/start-a-git-commit-message-with-a-hashmark
The rigidity comment was only about the positioning...
Understood. I prefer to have a clear template with clear positioning. I prefer going back to one of the older proposals of starting the abstract with "Issue #nn" or "Fix #nn". However, I'm willing to compromise on positioning and prefix if everyone else prefers otherwise.
My hard requirements are:
- All commits have the same comment template, with no conditional parts that require judgment to fill in.
- It is easy to find all commits for a particular issue number, and construct a short summary of the commits. e.g. using
git log --grep='#25' --oneline
from omr.
It's quite possible for a commit comment to refer to other issue numbers, so I prefer having a keyword to identify the issue most relevant.
from omr.
We've settled on Mark's most recent proposal.
from omr.
Related Issues (20)
- Reuse OMRPORT_TIME_DELTA_IN_NANOSECONDS in omrtime.c HOT 1
- x86: make improvements to port library for cpu identification
- Implement omrsysinfo_get_process_start_time for z/TPF HOT 4
- Agenda for June 20, 2024 OMR Architecture Meeting
- TRIL tests on z/OS generates non-standard NaN formatting HOT 3
- Linux RISCV64 PR Builds Failing: Missing libfakeroot_1.31-1.2 HOT 3
- Allow '[' and ']' to be used for specifying options in subset
- Hang in SanityTest
- Define fmax/fmin/dmax/dmin opcode specifications HOT 2
- Use 32-bit XORRegReg to zero registers on x64
- Consolidate ValuePropogation paths for with and without off-heap
- Upgrade Python on CI nodes to at least version 3.2
- Revisit optimizations in IntegerMultiplyDecomposer.cpp
- Supported C++ features document is out of date HOT 10
- Revisit coding standards HOT 1
- SEGFULT in portLibrary.str_printf() calls HOT 1
- Enable storing pinning array pointer in node extension for all nodes
- Proposed Agenda for July 18, 2024 OMR Architecture Meeting
- Extensible classes: how to be protected from inter-project name clashes for re-declared concrete classes
- Generic Double Memory Map API HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from omr.