unjs / changelogen Goto Github PK
View Code? Open in Web Editor NEW๐ Beautiful Changelogs using Conventional Commits
License: MIT License
๐ Beautiful Changelogs using Conventional Commits
License: MIT License
Provide some way to generate changelogs only for one or more specific subfolders/repos in a monoprepo structure.
For single folders, rootDir would probably work, but if 2 or more projects in a monorepo changed, you would have to append all together.
This flag can be helpful to for automated releases to automatically trigger the npm publish command with proper args and scope.
Related: #104
Hello,
In order to easily add new command and understand how the CLI works (because there is more and more feature), I think that we could use a tool like CAC, https://github.com/cacjs/cac, to achieve this.
Currently, there is no -h
flag and there is many more flag to come.
#104 with a --prevenance
#105 with a --publish
nuxt/nuxt#20675 with a flag to create a PR (where we could personalize changelog header)
Hello,
I'm currently working in a project where they use merge commit. So changelogen have some difficulties to create the changelog because all commits are use.
2 issues here:
But, GitHub is able to generate correct release not. So I build a tool to fetch release notes, organize them and update the related release. (https://github.com/aneoconsulting/order-github-release-notes)
I see that changelogen is using more GitHub API with a namespace github
so do you think we can merge my tool into changelogen?
related to #62
Node.js v20.2.0
Changelogen v0.5.3
I added changelog.config.json
with the following content:
{
"types": {
"feat": {
"title": "๐ Features"
},
"fix": {
"title": "๐ Bug Fixes"
},
"perf": {
"title": "๐ Performance Improvements"
},
"refactor": false,
"style": false,
"chore": false,
"build": false,
"test": false,
"docs": false,
"ci": false
}
}
Everything is working fine.
But when I create a file `.changelogrc' with the same content, it has no effect on how changelog is generated.
Show summary stats of total commits, change type, authors
Would it be possible to add an option to disable the contributors section ? Or only show new contributors instead of repeating every time ?
A GitHub action to automate releases and prereleases.
We can also auto-detect and use --provenance
flag to link the release to the source code.
Add a flag to automatically update CHANGELOG.md
Hello,
I'm going to move from standard-version and friends since the project is deprecated. I found changelogen and I really like it!
Not only that, but I wanted to ask if it could be possible to regenerate the CHANGELOG.md
for a project that is already uses conventional commits.
Like generating all the releases from the beginning, is that possible? ๐
For some reasons, github api might be unable to map a user to it's handle and name (unjs/ungh#50). We might support a emailMap
configuration to support custom emails
(also i would use same feature to stop thanking my self / known members in changeloges :D)
GitHub Releases marks contributors to releases by usage of @ handle. It would be nice to generate these in the contributors list at the bottom (maybe instead of email addresses) so they show up when the release is published.
OS: Ubuntu 22.04.1 LTS
node: 16.19.0
npm: 8.9.13
changelogen: latest (0.4.1)
https://github.com/sumerokr/changelogen-reproduction
Dear UnJS team,
I have noticed that the first run of the npx changelogen --release
command does not include the CHANGELOG.md file into the version bump commit. Is this on purpose?
No response
> git log
feat: init
> git status
nothing to commit, working tree clean
> npx changelogen --release
> git log
chore(release): v1.1.0
feat: init
> git status
Untracked files:
CHANGELOG.md
My .changelogrc
looks like that:
{
"types": {
"feat": { "title": "Features" }
}
}
But config is still logged like that:
{
types: {
feat: { title: '๏ฟฝ๐ Enhancements' }
perf: { title: '๏ฟฝ๐ Performance' },
fix: { title: '๐ฉน Fixes' },
refactor: { title: '๏ฟฝ๐
Refactors'
examples: { title: '๏ฟฝ๐ Examples' }
docs: { title: '๏ฟฝ๐ Documentation'
chore: { title: '๏ฟฝ๐จ Chore' },
build: { title: '๏ฟฝ๐ฆ Build' },
test: { title: 'โ
Tests' },
types: { title: '๏ฟฝ๐ Types' },
style: { title: '๏ฟฝ๐จ Styles' },
ci: { title: '๏ฟฝ๐ค CI' }
},
v14.18.0
When I run the 'yarn changelogen --release' command i get the error mentioned in the title. I don't have any problem when my Node version is 16.0.0, but when it's 14.18.0, I get the error. I think it's because replaceAll function started to be used in version 15.0.0. Can you create alternative for replaceAll fn due to solve it?
No response
I'm using renovate in my project to manage dependencies (as does this one). Renovate generates commit messages like fix(deps): update dependency ...
. I would like to group these dependency changes not under the fixes section but in a separate group. Usually there are a lot of dependency updates between releases and thus they clutter the changelog.
I can look into implementing this if someone points me in the right direction.
I wish the changelog could be generated using only merge commit (git log --merges
) to have a tool more inclusive for those want do not want use squash merges.
Query API (only works for public emails): https://api.github.com/search/[email protected]
Hello,
Actually, I'm using codacy/git-version but it use a dev and a main branch which is really annoying. So, I'm looking for a way to generate the next version using conventional commit. I'm not founding anything but looking at this package, I think that it could be awesome to extract the bump function into it's own package to be able to generate, using lastest tag and last commits a new version without the pain of the dev and main branch.
Then, in this package, we could use the new package to get a version.
Can be also useful to auto generate the scope
This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.
Warning
These dependencies are deprecated:
Datasource | Name | Replacement PR? |
---|---|---|
npm | standard-version |
These updates are awaiting their schedule. Click on a checkbox to get an update now.
These updates are pending. To force PRs open, click the checkbox below.
These updates have all been created already. Click a checkbox below to force a retry/rebase of any.
.github/workflows/autofix.yml
actions/checkout v4
actions/setup-node v4
autofix-ci/action ff86a557419858bb967097bfc916833f5647fa8c
.github/workflows/ci.yml
actions/checkout v4
actions/setup-node v4
codecov/codecov-action v4
package.json
c12 ^1.11.2
colorette ^2.0.20
consola ^3.2.3
convert-gitmoji ^0.1.5
execa ^8.0.1
mri ^1.2.0
node-fetch-native ^1.6.4
ofetch ^1.3.4
open ^10.1.0
pathe ^1.1.2
pkg-types ^1.2.0
scule ^1.3.0
semver ^7.6.3
std-env ^3.7.0
yaml ^2.5.1
@types/node ^20.16.5
@types/semver ^7.5.8
@vitest/coverage-v8 ^2.0.5
eslint ^9.10.0
eslint-config-unjs ^0.3.2
jiti ^1.21.6
prettier ^3.3.3
standard-version ^9.5.0
typescript ^5.5.4
unbuild ^2.0.0
vitest ^2.0.5
pnpm 9.9.0
Would like the option for changelogen to stop if the working copy isn't clean. This will ensure all commits are done first.
I like commitlint's ability to check commit messages but wanted it to be 100% compatible with changelogen.
It is available here:
https://github.com/jcamp-code/commitlint-config-unjs
May I submit a PR with a small update to the README to let people know this is out there?
It would be great to have a --dry-run
option so we could do npx changelogen@latest --release --dry-run
or npx changelogen@latest --bump --dry-run
This will force to not write to git/disk (improved --no-output --no-commit --no-tag
)
node 16.20.0
migrate cli to use unjs/citty
migrate cli to use unjs/citty
No response
No response
Built-in: group
(previous) and flat
(current)
External: Lodash-template alike?
I would really like to be able to mention users when making a GitHub release. (This does not work if their user name is linked.)
For the GitHub release only, would it be possible to include just the username and not the link to their profile (which will be auto-linked)?
I would also note that quite a lot of usernames are not correctly linked, including mine. Currently I manually go through every commit to ensure I have the right user mentioned in the release. Here's a sample implementation from the amazing changelogithub
:
https://github.com/antfu/changelogithub/blob/main/src/github.ts#L63-L93
Add support for gitmoji commit messages:
Currently:
### ๐ก Chore
- :arrow_up: bump qs from 6.10.3 to 6.10.4 (xxx)
- :arrow_up: bump mongodb from 4.4.1 to 4.6.0 (xxx)
- :arrow_up: bump @azure/data-tables from 13.0.1 to 13.1.1 (xxx)
- :arrow_up: bump gremlin from 3.5.2 to 3.6.0 (xxx)
### ๐ Documentation
- **helper:** :pencil: Updated TSDoc (xxx)
With gitmoji support:
### ๐ก Chore
- โฌ๏ธ bump qs from 6.10.3 to 6.10.4 (xxx)
- โฌ๏ธ bump mongodb from 4.4.1 to 4.6.0 (xxx)
- โฌ๏ธ bump @azure/data-tables from 13.0.1 to 13.1.1 (xxx)
- โฌ๏ธ bump gremlin from 3.5.2 to 3.6.0 (xxx)
### ๐ Documentation
- **helper:** โ๏ธ Updated TSDoc (xxx)
When there is a prerelease suffix to the version (x.y.z-something) we should sync it as a prerelease for github
Using taggerdate
to find the latest created tag seems wrong when different tag names exist in a git repo. Using creatordate
will solve this issue.
Line 30 in cdc7dd4
Here is the result of running these command in @nuxt/content
repo
git --no-pager tag -l --sort=taggerdate
2.0.0
2.0.1
v1.13.1
v1.14.0
...
[email protected]
[email protected]
@nuxt/[email protected]
@nuxt/[email protected]
git --no-pager tag -l --sort=creatordate
v0.0.1
v0.0.2
v0.0.3
...
@nuxt/[email protected]
v2.0.0
v2.0.1
Using a map from file names / prefixes to scoped like scopeMap
, we could map a change to it's scope (like updating src/presets
renamed fix: foobar
in src/presets/foo.ts
to fix(presets): foobar
when scopeMap: { 'presets/**': 'foobar' }
is set.
Use a prompt to confirm before bumping.
Moving from #18 also awesome works in #45 by @leo91000 and #83 by @aa900031
@itpropro: Provide some way to generate changelogs only for one or more specific subfolders/repos in a monoprepo structure.
These are smaller tasks breakdown in order to support mono repos progressively since this is a rather big change in changelogen.
workspaces
config object (auto-detected with resolveWorkspace
from pkg-types
)subDir
config defaulting to /
and when is set, filters commits only relevant to this subpath and also operates package.json
and CHANGELOG.md
in {rootDir}/{subDir}
for updating--release
to use workspace config when is set/detected and operate release on each monorepo project with baseDir
set (using sorted/ordered graph resolved by pkg-types)scopeMap
(#86) with workspace config to automatically apply scoped changelogesNote: PRs are more than welcome to implement each task. If you see an improvement in the roadmap for implementation please comment below. ๐๐ผ
Hi!
I use bumpp to raise the version of my package.
I used conventional-changelog and standard-version for generating changelogs before.
It worked according to the following algorithm:
bumpp
updates the version in package.json
standard-version
or conventional-changelog
generate the changelog from latest version tag to version from package.json
bumpp
create commit and tag with new version and push to origin repoExample of package.json
:
{
"scripts": {
"release": "pnpm release:check && pnpm release:version && pnpm release:publish",
"release:changelog": "standard-version --infile changelog.md --same-file --skip.bump --skip.commit --skip.tag",
"release:check": "pnpm test && pnpm build",
"release:publish": "clean-publish",
"release:version": "bumpp package.json --execute=\"pnpm release:changelog && git add changelog.md\" --commit \"build: publish v%s\" --tag --all",
}
}
I would like to be able to generate changelogs without creating a tag and getting a new version from package.json
Hi!
Thank you for your awesome project!
I use the bumpp package for version upgrades. I like that I can manually choose version of my package.
It would be great to be able to generate a changelog for a release by tag, which would include the difference between the tag and the previous tag.
Like this:
// package.json
{
"scripts" {
"release:version": "bumpp package.json --execute=\"pnpm exec changelogen --output changelog.md --version %s" --tag --all",
}
}
Automatically remove entries that are referenced to revert in same changelog set
changelogen: 0.5.2
node: 18.14.1
browser: Arc v0.95.1 (37921)
Run: changelogen --release --push
package.json
{
"changelog": {
"repo": {
"provider": "github"
}
}
}
The auto publish of the release with Github not works anymore with v0.5.2
A new window of the Browser is open, stay open and the release is not published.
The urls generated for commits and compare version looks like:
I think the bug is due to this error
Check it here: https://github.com/zadigetvoltaire/nuxt-gtm/blob/main/CHANGELOG.md (v0.0.9)
> changelogen --release --push
โน Generating changelog for v0.0.8...main 15:27:31
โน Bumping version from 0.0.8 to 0.0.9 (minor) 15:27:31
โน Updating /.../CHANGELOG.md 15:27:31
โน Followup in the browser to manually create the release.
Use github API to allow generating changelog without need of a local git.
When repository name or org name contains .
or -
or _
, (while it is supported, it cannot be detected).
While working on fix, I'm thinking to extract this functionality to it's own lib also sharing with unjs/giget and improve testing
Hi. Thanks for your work.
When I try changelogen
, I find no way to generate CHANGELOG.md when I first time bump version.
$ npx changelogen --release
Need to install the following packages:
[email protected]
Ok to proceed? (y)
ERROR Command failed with exit code 128: git describe --tags --abbrev=0 16:07:45
fatal: No tags can describe 'dbd9fa593d64f0a04bb801be556eae775242c48a'.
Try --always, or create some tags.
fatal: No tags can describe 'dbd9fa593d64f0a04bb801be556eae775242c48a'.
Try --always, or create some tags.
at makeError (/Users/wurui/.npm/_npx/fd5a125c5466fd2f/node_modules/execa/lib/error.js:59:11)
at handlePromise (/Users/wurui/.npm/_npx/fd5a125c5466fd2f/node_modules/execa/index.js:124:26)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async execCommand (/Users/wurui/.npm/_npx/fd5a125c5466fd2f/node_modules/changelogen/dist/shared/changelogen.53701f80.mjs:94:15)
at async getLastGitTag (/Users/wurui/.npm/_npx/fd5a125c5466fd2f/node_modules/changelogen/dist/shared/changelogen.53701f80.mjs:13:13)
at async loadChangelogConfig (/Users/wurui/.npm/_npx/fd5a125c5466fd2f/node_modules/changelogen/dist/shared/changelogen.53701f80.mjs:415:19)
at async Module.defaultMain (/Users/wurui/.npm/_npx/fd5a125c5466fd2f/node_modules/changelogen/dist/chunks/default.mjs:24:18)
at async main (/Users/wurui/.npm/_npx/fd5a125c5466fd2f/node_modules/changelogen/dist/cli.mjs:22:3)
Can you please give me some advice? Thanks.
Just tried using changelogen
with npx and I keep getting this error:
/bin/env: bad interpreter: No such file or directory
I've tried on a couple different computers and seems to be happening whenever you try to run the script ๐ค (I am on node 16, btw)
I'm using bitbucket as pipeline and I can skip the pipeline run when the commit message contains "[skip ci]"
I see no possibilty to adjust the commit message "chore(release): {tag}" to another one
We can base on c12 extends
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.