name: Bump Version on Push

on:
  push:
    branches:
      - master

jobs:
  bump-version:

    runs-on: ubuntu-latest
    if: "!startsWith(github.event.head_commit.message, '[SKIP]')"

    steps:

    - name: Set up Python
      uses: actions/setup-python@v1
      with:
        python-version: '3.x'

    # - name: Setup Git
    #   uses: actions/checkout@v2
    #   with:
    #     token: ${{ secrets.PDBPAT }}
    #   run: |
    #     git config user.email "dev@null.com"
    #     git config user.name "Github Actions - Bumper"

    - name: Create skip flag
      run: |
        echo "::set-env name=SKIPBUMP::FALSE"

    - name: Install dependencies
      run: |
        python -m pip install --upgrade pip
        pip install bump2version

    - name: Bump Minor Version
      uses: actions/checkout@v2
      with:
        token: ${{ secrets.PDBPAT }}
      run: |
        bump2version minor
        echo "::set-env name=SKIPBUMP::TRUE"
      if: "startsWith(github.event.head_commit.message, 'FEATURE')"

    # Default action
    - name: Bump Patch Version
      run: |
        bump2version patch
      if: env.SKIPBUMP == 'FALSE'

    # No major version change should go through automatically.

    - name: Commit version change to master
      uses: actions/checkout@v2
      with:
        token: ${{ secrets.PDBPAT }}
      run: |
        git push --follow-tags
name: Bump Version on Push

on:
  push:
    branches:
      - master

jobs:
  bump-version:

    runs-on: ubuntu-latest
    if: "!startsWith(github.event.head_commit.message, '[SKIP]')"

    steps:

    - uses: actions/checkout@v2
      with:
        token: ${{ secrets.PDBPAT }}

    - name: Set up Python
      uses: actions/setup-python@v1
      with:
        python-version: '3.x'

    # - name: Setup Git
    #   uses: actions/checkout@v2
    #   with:
    #     token: ${{ secrets.PDBPAT }}
    #   run: |
    #     git config user.email "dev@null.com"
    #     git config user.name "Github Actions - Bumper"

    - name: Create skip flag
      run: |
        echo "::set-env name=SKIPBUMP::FALSE"

    - name: Install dependencies
      run: |
        python -m pip install --upgrade pip
        pip install bump2version

    - name: Bump Minor Version
      run: |
        bump2version minor
        echo "::set-env name=SKIPBUMP::TRUE"
      if: "startsWith(github.event.head_commit.message, 'FEATURE')"

    # Default action
    - name: Bump Patch Version
      run: |
        bump2version patch
      if: env.SKIPBUMP == 'FALSE'

    # No major version change should go through automatically.

    - name: Commit version change to master
      run: |
        git push --follow-tags
Fix no uses/runs in the same step error
Fix no uses/runs in the same step error
