feat: testing version env var #13
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release Workflow | |
on: | |
# pull request | |
pull_request: | |
branches: | |
- main | |
# push: | |
# tags: | |
# - '[0-9]+.[0-9]+.[0-9]+' | |
jobs: | |
build-and-publish: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Set up Python | |
uses: actions/setup-python@v2 | |
with: | |
python-version: 3.7 | |
- name: Install necessary packages for make | |
run: sudo apt-get update && sudo apt-get install -y build-essential | |
- name: Install Pipenv and build packages | |
run: | | |
python -m pip install --upgrade pip | |
pip install pipenv build | |
- name: Install project dependencies | |
run: pipenv install --dev | |
# Get github tag and set env var VERSION with it | |
- name: Set up env vars | |
run: echo "VERSION=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_ENV | |
# Print VERSION env var | |
- name: Print VERSION | |
run: echo $VERSION | |
# - name: Set up PyPI Token | |
# run: echo "pypi_token=${{ secrets.PYPI_TOKEN }}" >> $GITHUB_ENV | |
# - name: Run make publish | |
# env: | |
# TWINE_USERNAME: __token__ | |
# TWINE_PASSWORD: ${{ env.pypi_token }} | |
# run: make publish |