2022-07-22 15:24:11 -04:00
|
|
|
name: Release
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- master
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
permissions:
|
|
|
|
contents: write
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
2022-07-22 15:28:13 -04:00
|
|
|
- uses: actions/setup-python@v4
|
|
|
|
with:
|
|
|
|
python-version: '3.10.x'
|
2022-07-23 15:09:59 -04:00
|
|
|
- name: Install Env
|
|
|
|
# this should be all we need because shiv will download the deps itself
|
|
|
|
run: |
|
2022-07-23 15:26:10 -04:00
|
|
|
pip install --upgrade pip
|
2022-07-23 15:09:59 -04:00
|
|
|
pip install shiv
|
|
|
|
pip install poetry
|
2022-07-23 15:26:10 -04:00
|
|
|
- name: Add CURRENT_TIME env property
|
|
|
|
run: echo "CURRENT_TIME=$(date -Iseconds)" >> $GITHUB_ENV
|
2022-07-23 12:05:34 -04:00
|
|
|
- name: Build the sucker
|
|
|
|
run: |
|
2022-07-23 15:26:10 -04:00
|
|
|
sed -i -e "s/?????/v${{ env.CURRENT_TIME }}/g" src/__init__.py
|
2022-07-23 12:05:34 -04:00
|
|
|
make build
|
2022-07-22 15:24:11 -04:00
|
|
|
- uses: ncipollo/release-action@v1
|
|
|
|
with:
|
|
|
|
artifacts: "utils"
|
|
|
|
body: "It's releasin' time"
|
2022-07-23 13:46:46 -04:00
|
|
|
generateReleaseNotes: false
|
2022-07-23 15:26:10 -04:00
|
|
|
tag: v${{ env.CURRENT_TIME }}
|
2022-07-22 21:51:16 -04:00
|
|
|
commit: master
|
2022-07-22 21:26:42 -04:00
|
|
|
token: ${{ secrets.PAT }}
|