Comments (2)
it looks like the functionality I'm looking for is already present in this method https://github.com/git-chglog/git-chglog/blob/v0.15.4/chglog.go#L226-L253
there is no real reason that I can tell for this readUnreleased(..)
method to take in a slice of *Tag
; if instead we pushed the responsibility for forming the rev list out so that this method could accept any rev list, that would probably move us towards being able to generate release fragments for an arbitrary range of commits by standard git ref syntax.
func (gen *Generator) readUnreleased(tags []*Tag) (*Unreleased, error) {
if gen.config.Options.NextTag != "" {
return &Unreleased{}, nil
}
rev := "HEAD"
if len(tags) > 0 {
rev = tags[0].Name + "..HEAD"
}
commits, err := gen.commitParser.Parse(rev)
if err != nil {
return nil, err
}
commitGroups, mergeCommits, revertCommits, noteGroups := gen.commitExtractor.Extract(commits)
unreleased := &Unreleased{
CommitGroups: commitGroups,
Commits: commits,
MergeCommits: mergeCommits,
RevertCommits: revertCommits,
NoteGroups: noteGroups,
}
return unreleased, nil
}
maybe supporting generating unreleased notes about any arbitrary commits while still requiring tags to be in use for the standard use case is a nice compromise?
from git-chglog.
@mavogel @wadackel I would also like to generate changelog notes based on a pair of commit references, in my case the head and base refs of a Pull Request
my use case is to generate a release note fragment in a pull request based just on the changes in that pull request as a way to provide feedback to the developers on my team how their commit messages will render in the customer-facing release notes we intend to generate later (based on tags in our release branch).
if this capability is aligned with this project's goals and vision I would be willing to prepare a contribution to implement.
I look forward to your thoughts and direction.
from git-chglog.
Related Issues (20)
- docker image broken in 0.15.2 HOT 5
- build: use buildx and goreleaser for building images
- v0.15.3: checksums are different between HOT 2
- feature request: support break change with `type(scope)!:`
- Allow inserting the changelog inside a file using a marker
- Support other separators than ':' HOT 1
- Querying a tag with number greater than 9 like v0.1.10 gives not found error HOT 2
- faet: changelog not commit url
- minor: flaw in readme description
- Non-breaking changes end up in the breaking changes section
- bash: git-chglog: command not found... HOT 2
- command line switches like --version not being interpretted correctly HOT 2
- Be able to reference `.Info.JiraURL` in template
- How does one reference the PR description in the template?
- Jira integration: support multiple work item tickets per commit HOT 1
- JIRA integration not working HOT 3
- feat: pass additional data/vars into the templates
- replace gitcmd with go-git
- feat: add mergify with auto-approve
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 git-chglog.