Skip to content

Commit

Permalink
Show release draft as a step output.
Browse files Browse the repository at this point in the history
  • Loading branch information
adiroiban committed Nov 7, 2023
1 parent 8b9b4b2 commit 47cf0f3
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
10 changes: 7 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -160,10 +160,12 @@ jobs:
python-version: '3.11'
task:
- name: Check Newsfragment
nox: check_newsfragment
run: |
nox -e check_newsfragment
nox -e draft_newsfragment >> $GITHUB_STEP_SUMMARY
run-if: ${{ github.head_ref != 'pre-commit-ci-update-config' }}
- name: Check mypy
nox: typecheck
run: nox -e typecheck
run-if: true

steps:
Expand All @@ -187,7 +189,9 @@ jobs:

- uses: twisted/python-info-action@v1

- run: nox -e ${{ matrix.task.nox }}
- name: Check
run: |
${{ matrix.task.run }}
if: ${{ matrix.task.run-if }}


Expand Down
5 changes: 5 additions & 0 deletions noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,11 @@ def check_newsfragment(session: nox.Session) -> None:
session.install(".")
session.run("python", "-m", "towncrier.check", "--compare-with", "origin/trunk")

@nox.session
def draft_newsfragment(session: nox.Session) -> None:
session.install(".")
session.run("python", "-m", "towncrier.build", "--draft")


@nox.session
def typecheck(session: nox.Session) -> None:
Expand Down

0 comments on commit 47cf0f3

Please sign in to comment.