You're viewing an older version of this GitHub Action. Do you want to see the latest version instead?
GitHub Action
get-commit-changelog
v1.1.0
This action returns a list of commits between two commits as an output. This is useful when creating a changelog between two commits, such as when deploying something new to the servers, you might wanna give that a changelog. If you keep tabs of your head and base commits, this action might be useful for you!
- Uses composite action
base
andhead
can be typical container tags (e.g. branchname-69b7ea), because this action reads everything after a hyphen (-). Meaning, if you setbase
tobranchname-69b7ea
, it becomes69b7ea
.- Can be used with other repositories 📂
- Returns Markdown ✍️
Important: You must use a personal access token with repo scope if you're reading other repositories.
- uses: cobraz/get-commit-changelog@v1
id: changelog
with:
base: ${{ steps.something.base }}
- uses: cobraz/get-commit-changelog@v1
id: changelog
with:
base: ${{ steps.something.base }}
- name: Print changelog
run: echo "${{ steps.changelog.outputs.changelog }}"
Also, check out the test.yml
for a real, working example. In this I have manually
set the base
to the first commit in this repository. In theory, the changelog will contain all commits in this
repository. Check out the actions tab for example runs.
base
(required) is the typically the latest commit (the to commit in our example).head
(defaults togithub.ref
) is typically the commit back in time.token
(defaults togithub.token
) is the GitHub token. It needs to be a personal GitHub token if you are trying to compare other repositories.repository
(defaults togithub.repository
) is which GitHub repository you want to compare commits in.