-
Notifications
You must be signed in to change notification settings - Fork 238
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: pass additional data/vars into the templates #261
Comments
davidalpert
added a commit
to davidalpert/git-chglog
that referenced
this issue
Nov 28, 2023
this commit addresses git-chglog#261 by allowing the passing of arbitrary key=value arguments into the command line and exposing them as part of RenderData for use in the templates resolves: git-chglog#261
davidalpert
added a commit
to davidalpert/git-chglog
that referenced
this issue
Nov 28, 2023
this commit addresses git-chglog#261 by allowing the passing of arbitrary key=value arguments into the command line and exposing them as part of RenderData for use in the templates resolves: git-chglog#261
2 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Sometimes when generating change notes it becomes useful to include data that is not present in the source code and is only known at build time while generating the change log. An example might be a build number that is generated by a CI/CD build server.
It would be nice to be able to pass variables into the changelog templates as command-line arguments:
a slice of string
--arg name value
flags similar tojq
(e.g.--arg build_number 123
)--arg-json '{"build_number": 123}'
--arg-file /path/to/args.json
where
/path/to/args.json
looks like thisin all cases the accumulated key/value pairs could be made available to the template as a
map[string]interface
and accessed via theindex
template functionIf this request is aligned with the direction of this project I would be happy to contribute a pull request.
The text was updated successfully, but these errors were encountered: