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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Allow commit message ONLY with --messageonly #156

Merged
merged 4 commits into from
Jan 10, 2024

Conversation

vespasianvs
Copy link
Contributor

For my project we needed the commit messages only (with no URLs, author names etc). I added the functionality for my project and thought I'd submit it here too to see if it is useful for others. Follows the same pattern as --plaintext but displays the commit messages only.

Also changed the grouping so that it doesn't display the single colon if the commitGroup value is undefined/empty.

test.js Outdated
Comment on lines 61 to 63
* refactor and improve
test:
* update refs for testing
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
* refactor and improve
test:
* update refs for testing
* refactor and improve
test:
* update refs for testing

@rvagg
Copy link
Member

rvagg commented Nov 27, 2023

lgtm, there's a test failure with a simple fix as I've suggested, also please remove the package-lock.json from the commit

@vespasianvs
Copy link
Contributor Author

Apologies - forgot to check back on this - will take a look

@vespasianvs
Copy link
Contributor Author

Think that should do it? Finding it hard to run the tests locally as I'm on Windows 11 - even using WSL (Ubuntu) the tests aren't passing properly all of the time. Use the output from the workflow to fix the tests - I hope.

@rvagg
Copy link
Member

rvagg commented Jan 10, 2024

Yeah, sorry, windows support is lacking, there was an attempt to do it at one point but that was never completed. You're welcome to give that a try but iirc it was kind of gnarly. Some of that history can be traced through here: #66

Comment on lines 95 to 97
let s = ''
s += data.summary
return ` * ${s.trim()}`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
let s = ''
s += data.summary
return ` * ${s.trim()}`
return ` * ${data.summary.trim()}`

@rvagg
Copy link
Member

rvagg commented Jan 10, 2024

lgtm except for that one little change to remove unnecessary lines

@vespasianvs
Copy link
Contributor Author

Lines removed. I know exactly what I did there - took the toStringPlaintext and removed the lines I didn't want - then didn't spot the shortcut :)

If I can find time, I'll have a look at the Windows tests - I already had a branch open to look at it but ran out of time.

@rvagg rvagg merged commit e069500 into nodejs:main Jan 10, 2024
9 checks passed
@rvagg
Copy link
Member

rvagg commented Jan 10, 2024

excellent, thanks, I hope this is now more useful for you

github-actions bot pushed a commit that referenced this pull request Jan 10, 2024
## [4.1.0](v4.0.1...v4.1.0) (2024-01-10)

### Features

* allow commit message ONLY with --messageonly ([#156](#156)) ([e069500](e069500))
Copy link

🎉 This PR is included in version 4.1.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants