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

feat: add ADDITIONAL_OPTIONS for gh action #477

Conversation

eifinger
Copy link
Contributor

Add ADDITIONAL_OPTIONS as an additional command for the github action.

Using it with --noop on PRs as shown below allows to verify that new configurations or versions will run successfully on the main branch:

name: Semantic Release

on:
  push:
    branches:
      - master
  pull_request:
    branches:
      - master

jobs:
  noop-release:
    if: github.ref != 'refs/heads/master'
    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@v2
      with:
        fetch-depth: 0

    - name: Python Semantic Release Test
      uses: relekang/python-semantic-release@master
      with:
        github_token: ${{ secrets.GITHUB_TOKEN }}
        repository_username: __token__
        repository_password: ${{ secrets.PYPI_TOKEN }}
        additional_options: --noop
  release:
    if: github.ref == 'refs/heads/master'
    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@v2
      with:
        fetch-depth: 0

    - name: Python Semantic Release
      uses: relekang/python-semantic-release@master
      with:
        github_token: ${{ secrets.GITHUB_TOKEN }}
        repository_username: __token__
        repository_password: ${{ secrets.PYPI_TOKEN }}

@danth
Copy link
Member

danth commented Jul 24, 2022

It looks like you committed as the GitHub Actions account - do you want to fix this before merging?

@eifinger eifinger force-pushed the feat/gh-action-additional-options branch from c89de21 to df5ed72 Compare July 25, 2022 06:13
@eifinger
Copy link
Contributor Author

Thank you! Was overwritten when I tested the action.

@danth danth merged commit aea60e3 into python-semantic-release:master Jul 25, 2022
@danth
Copy link
Member

danth commented Jul 25, 2022

This seems to be causing an error when the new option isn't used:

https://github.com/relekang/python-semantic-release/runs/7498107038?check_suite_focus=true#step:4:222

@eifinger
Copy link
Contributor Author

Yes I saw that as well and opened a fix PR: #479

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants