Skip to content

Release 🚀

Release 🚀 #10

Workflow file for this run

name: Release 🚀
on:
push:
tags:
- '*'
jobs:
release:
name: Create Release
runs-on: ubuntu-latest
steps:
- name: Set env
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
- uses: actions/checkout@v2
- name: Set up Python 3.10
uses: actions/[email protected]
with:
python-version: '3.10'
- uses: actions/cache@v2
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('.github/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
- name: Install Python requirements
run: pip install -r .github/requirements.txt
- name : Get current changelog
run: qgis-plugin-ci changelog ${{ env.RELEASE_VERSION }} >> release.md
- name: Set env
# CI_COMMIT_TAG is used in Makefile to not have the "RC" flag
run: echo "CI_COMMIT_TAG=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
- name: Setup
run: |
make manifest
- name: Build package
run: |
python -m build --no-isolation --sdist
- name: Create release on GitHub
uses: ncipollo/[email protected]
with:
bodyFile: release.md
token: ${{ secrets.BOT_HUB_TOKEN }}
allowUpdates: true
artifacts: "dist/*.tar.gz"
- name: Deploy to PyPI
uses: pypa/gh-action-pypi-publish@master
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}
- name: Tweet
uses: mugi111/[email protected]
with:
consumer_key: ${{ secrets.TWITTER_CONSUMER_KEY }}
consumer_secret: ${{ secrets.TWITTER_CONSUMER_SECRET }}
access_token_key: ${{ secrets.TWITTER_ACCESS_TOKEN_KEY }}
access_token_secret: ${{ secrets.TWITTER_ACCESS_TOKEN_SECRET }}
tweet_body: "New version of Py-QGIS-WPS ${{ env.CI_COMMIT_TAG }} ⚙ for #QGIS https://github.com/3liz/py-qgis-wps/releases"