Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Suggest a commit message template #614

Open
matuskalas opened this issue Mar 28, 2021 · 26 comments
Open

Suggest a commit message template #614

matuskalas opened this issue Mar 28, 2021 · 26 comments
Labels
discussion Involving or requiring a thorough discussion and inputs from users and contributors good first issue Good for newcomers

Comments

@matuskalas
Copy link
Member

matuskalas commented Mar 28, 2021

Please suggest a template for commit messages to this repository, in form of either ideas, or even better a work-in-progress pull request. This issue is open for ideas from many contributors! 馃挕

[a good small task for newcomers, e.g. Outreachy applicants]


No idea what this is? Recommended reading is here:


I'm personally considering for the template something like:

  • a good compromise between being short (simple, concise), but helpful enough for newcomers and non-confident contributors
  • asking for a Reason/Why (if not obvious)
  • having Co-authored-by: lines, perhaps with the GitHub no-reply email address pattern(?)

... but really open to any other or additional suggestions! 馃槉

@matuskalas matuskalas added discussion Involving or requiring a thorough discussion and inputs from users and contributors good first issue Good for newcomers labels Mar 28, 2021
@shaonakundu
Copy link

Hello sir, I am Outreachy applicant. My initial application got approved. I am enthusiastic and would love to contribute. I also have keen interests in Machine learning

@matuskalas
Copy link
Member Author

Welcome @shaonakundu, so awesome to hear that you're interested! 馃檶馃徑

Please feel free to ask for help whenever you need, either here, or in Gitter.
(Or if needed privately on email matus.kalas@uib.no)

@shaonakundu
Copy link

Thank you sir @matuskalas , can you guide on which issues I can contribute to for Machine learning?

@trhiana
Copy link

trhiana commented Mar 29, 2021

Hello. I'm a prospective Outreachy applicant.
I think the template should also have how the commit addresses the problem and the possible effects (good or bad). Is the commit vital? This will help prioritise the commits

@cupcakes-code
Copy link

Hello, Im an outreachy prospective applicant.
The template message should have a brief and to the point comments about the project and how it contributes to a project.
simple message should include Who contributed to the project. Date provided with version info, impact including a brief reasoning for contributing. There should also be a where or the line of code where the contribution was edited.
//Contributor: Name/Email , Version info: ex..V1.1 Date 1/1/21. Contribution: reason for contributing.

@shaonakundu
Copy link

shaonakundu commented Mar 29, 2021

To add on, a commit message can be divided into subject and body where subject can have the heading and body will consist the definition. Keeping this mind, the commit message should be short and crisp but detailed to make others understand. Also, punctuation symbols and whitespace errors should be ignored.

@SAY-droid427
Copy link

Hey! I am a prospective Outreachy applicant. My initial application got approved. I am enthusiastic about contributing to the project.

@RuthAtem
Copy link

RuthAtem commented Mar 30, 2021

Hello @matuskalas I'm an Outreachy applicant and very interested in contributing to this project.
I think your template idea is already great. For additional suggestions, I'll say the commit description should have a capitalized subject line which briefly tells what change is being made and where the change is. After this it could have a short description explaining why the change is being made and how it was made. As such new comers and contributors will understand at a glance.

@ahlraf
Copy link

ahlraf commented Mar 30, 2021

Hello @matuskalas, I'm an Outreachy applicant looking forward to work here.
Adding on to your template, I think the description should have:

  • version details,
  • if approved, what will the commit do?
  • tags/ flairs to specify what kind of commit this is: code refactor/ documentation/ formatting/ bug fixes,
  • is it is a work in progress?
    I feel formatting is important too: including newlines, capitalizing, bulleting (?) etc.

@Lukong123
Copy link
Contributor

Hello @matuskalas and other applicants.
For the template I suggest it should emphasize that commit messages be in a readable format which can be easily understood by other developers even in the future.
Relevant link or even extra information can be added.
What the commit thus should be stated in a concise manner
And equally updating the branch can come in handy.

@SAY-droid427
Copy link

Hello @matuskalas
I would like to suggest this template:
While writing the commit message always use the keywords: Fix/Remove/Refactor/Add/Update/Document as this will give a clear indication of what has been done. It is easier to process mentally.
Then comes the 'Why is the change necessary? Is it a new feature,does it rectify a bug, does it improve the existing thing in short.
Then comes how does it solve the issue?
Including a line about the ticket raised before regarding it would be helpful.

@leilayesufu
Copy link

Good day @matuskalas
I'd like to suggest the template for the commit message-
# Subject or Title
# explain why the change was made
# explain the problem and solution(bug fixes)
# Attach links and files
# Other important details

@benny-coy
Copy link

Please suggest a template for commit messages to this repository, in form of either ideas, or even better a work-in-progress pull request. This issue is open for ideas from many contributors! 馃挕

[a good small task for newcomers, e.g. Outreachy applicants]

No idea what this is? Recommended reading is here:

I'm personally considering for the template something like:

  • a good compromise between being short (simple, concise), but helpful enough for newcomers and non-confident contributors
  • asking for a Reason/Why (if not obvious)
  • having Co-authored-by: lines, perhaps with the GitHub no-reply email address pattern(?)

... but really open to any other or additional suggestions! 馃槉

@benny-coy
Copy link

benny-coy commented Apr 1, 2021

Hello @benny-coy. I am an Outreachy applicant and new to open source. Here is my contribution to this project.
I understand that Commits should be used to tell a story that is understandable by you and others for any future use in a concise and consistent manner.

First, the template should be divided into Title/Subject and body. The subject and body should be separated by a blank line.

Style such as Markup syntax, wrap margins, grammar, capitalization, punctuation should be spelled out so that the result will be a remarkably consistent log that鈥檚 a pleasure to read.
The Metadata should tell how issue tracking IDs, pull request numbers, etc. be referenced?

Subject: Keywords(Fix/Remove/Refactor/Add/Update/Document ) should be used in the subject for easy understanding of
the commit. E.g
BUGFIX: Add New Column For User First Name.
The subject should start with a capital letter and should describe the commit in 50 characters or less.

Body:
The line length in the body should not be more than 75 characters.
The body should contain the followings;
Problem:
Reason for Commit(why is this change made?)
Blank line.....(for spacing)
Any reference to tickets or articles etc.?
Blank line.....
Task(if this commit is applied, it will.....
)
Blank line...
Solution:
List of Changes(changes to be committed ).
Blank line......

Note: special instructions, testing steps, rake etc.

Example of the template:
Subject: BUGFIX (Add New Column For User First Name.)

Body:

  • Reason for Commit(why is this change made?): We do not have a column for the first name. We need this column for reporting.

*Reference tickets: #123

*Task(if this commit is applied, it will.....: create a column for users first name.

*List of Changes(changes to be committed ):

  • Add column migration
  • Create a task to populate the new column
  • Update user view.

@leilayesufu
Copy link

leilayesufu commented Apr 2, 2021

#I'm Leila Yesufu and here's my contribution to the project.##
.gitconfig --global commit.template~/.gitmessage
[commit]
template = ~/.gitmessage
code ~/.gitcommit
##40 characters for the title of the commit##
Title
##40 characters for the nature of problem##
Problem

50 characters for solution/ changes made and why change was made and type of commit##

#please note that the commit message should be clear and understandable to other programmers##
Solution
#72 characters for specialnotes##
Additional instructions

#631

@DankamT
Copy link

DankamT commented Apr 4, 2021

Hello @matuskalas, this a suggestion am making with regards to the commit message template. It is modification of the udacity recommended commit message template. The commit message should be sub-divided into title, subject and body

<Title> (Separate this section from next by a newline)

Subject line (Capitalise and use the imperative mood for this and don't end it with a dot. Max 50 char )
structure: [] (If applied, this commit will...) )
Example: [feat] Implement Automated Commit Messages

Body (Multiple lines starting with * or - can be used but try To Limit Each Line to a Maximum Of 72 Characters )
Explain why this change is being made
Explain what is change that is being made
(Optional) Provide links or keys to any relevant tickets, articles or other resources
Example: Github issue #23

--- COMMIT END ---

#The tags can be

feat (new feature)

fix (bug fix)

refactor (refactoring code)

style (formatting, missing semi colons, etc; no code change)

doc (changes to documentation)

test (adding or refactoring tests; no production code change)

version (version bump/new release; no production code change)

jsrXXX (Patches related to the implementation of jsrXXX, where XXX the JSR number)

jdkX (Patches related to supporting jdkX as the host VM, where X the JDK version)

dbg (Changes in debugging code/frameworks; no production code change)

license (Edits regarding licensing; no production code change)

hack (Temporary fix to make things move forward; please avoid it)

WIP (Work In Progress; for intermediate commits to keep patches reasonably sized)

defaults (changes default options)

Note: Multiple tags can be combined, e.g. [fix][jsr292] Fix issue X with methodhandles

@melibleq
Copy link
Member

Hi there, hope everyone is doing fine!
@matuskalas, could you please help me understand a little better what you expect with this task?
I've got some ideas, but I'm not sure if I should share them here, message you, or just submit a pull request with them.

@AnkitaxPriya
Copy link
Contributor

@matuskalas I have made a PR for this issue. Kindly review #643. Thank you.

@matuskalas
Copy link
Member Author

Sorry, off-topic this issue:
@shaonakundu

... I also have keen interests in Machine learning

Would you like to fix edamontology/edam-bioimaging#24?

@Lukong123
Copy link
Contributor

Hello @matuskalas, @AnkitaxPriya and other applicants please can you people help me with creating pull request for this issue cause I am facing difficulties.
I used git config --global commit.template ~/.gitmessage on git bash and then used code ~/.gitmessage under a branch on my cloned edamontology repo when i use code ~/.gitmessage it opens my editor but the path there is not included under edamontology please i need help?

@melibleq
Copy link
Member

I used git config --global commit.template ~/.gitmessage on git bash and then used code ~/.gitmessage under a branch on my cloned edamontology repo when i use code ~/.gitmessage it opens my editor but the path there is not included under edamontology please i need help?

Hi @Lukong123. Perhaps it would be a little easier to visualize what's going on with a screenshot of your script. You can drag and drop the image here in the comment box.

I don't fully understand your question about the path. Could you please detail it a little bit more?

@Lukong123
Copy link
Contributor

ok @melibleq
temerr1
temvserr2

@Lukong123
Copy link
Contributor

ok @melibleq
temerr1
temvserr2

after writting my template when i check git status it shows working directory clean , problably because the path editor is not even under edamontology folder but i wonder why since i ran the code under my edam directory

@melibleq
Copy link
Member

Thanks for the screenshots! Now I can see more clearly what's going on. Maybe this link could help you?
I've also come across this Git documentation page that could be useful.
I'm sorry if you have already searched for answers and have seen those pages already.

Now, before commiting, you're supposed to do git add [file] first. Also, the commit should have a message explaining what you did, such as git commit -m "[message]". The first message in this thread has some good links about Git commands.
(Again, sorry if you are already familiar with all this and have used it but for some reason it's not working)

@Lukong123
Copy link
Contributor

Thanks for the screenshots! Now I can see more clearly what's going on. Maybe this link could help you?
I've also come across this Git documentation page that could be useful.
I'm sorry if you have already searched for answers and have seen those pages already.

Now, before commiting, you're supposed to do git add [file] first. Also, the commit should have a message explaining what you did, such as git commit -m "[message]". The first message in this thread has some good links about Git commands.
(Again, sorry if you are already familiar with all this and have used it but for some reason it's not working)

Thanks alot @melibleq let me go through it please i'll get back to you if i encounter any difficulty

@Lukong123
Copy link
Contributor

Hello, @matuskalas, @melibleq and other applicants please checkout my pull request and tell me what to rectify there #663

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discussion Involving or requiring a thorough discussion and inputs from users and contributors good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests