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

ci: fix release process #389

Merged
merged 1 commit into from
Oct 6, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 12 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ jobs:
- name: Checkout
uses: actions/checkout@v3
with:
ssh-key: ${{secrets.CI_RELEASE_DEPLOY_KEY}}
fetch-depth: 0
- name: Use Python "3.10"
uses: actions/setup-python@v4
Expand All @@ -23,19 +24,27 @@ jobs:
uses: orhun/git-cliff-action@v2
id: git-cliff
with:
config: cliff.toml
args: --verbose --latest
env:
OUTPUT: git-cliff-changes.tmp.md
- name: Update the changelog
run: |
echo "${{ steps.git-cliff.outputs.contents }}" | sed -i "3r /dev/stdin" CHANGELOG.md
git checkout main
cat git-cliff-changes.tmp.md | sed -i "3r /dev/stdin" CHANGELOG.md
git config --global user.name 'Github Action'
git config --global user.email '[email protected]'
git commit -am "chore: update changelog"
git add CHANGELOG.md
git commit -m "chore: update CHANGELOG.md"
git push
- name: Update CONTRIBUTORS.md
run: |
git checkout main
poetry install
poetry run poe generate_contributors_md
if [[ $(git diff --stat CONTRIBUTORS.md) != '' ]]; then
git commit -am "chore: update CONTRIBUTORS.md"
git add CONTRIBUTORS.md
git commit -m "chore: update CONTRIBUTORS.md"
git push
fi
- name: Release
Expand Down
2 changes: 1 addition & 1 deletion cliff.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ body = """
{% else %}\
## [unreleased]
{% endif %}\
More details: https://github.com/openlawlibrary/pygls/releases/tag/v{{version}}
More details: https://github.com/openlawlibrary/pygls/releases/tag/{{version}}
{% for group, commits in commits | group_by(attribute="group") %}
### {{ group | upper_first }}
{% for commit in commits %}
Expand Down
Loading