Skip to content

update flake

update flake #27

name: Release MTFG Installer
on:
push:
tags:
- '*'
jobs:
miniconda:
name: Miniconda ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: ["windows-latest"]
steps:
- name: Checkout Repository
uses: actions/checkout@v3
- name: Setup Miniconda
uses: conda-incubator/setup-miniconda@v2
with:
activate-environment: build-installer
environment-file: ./contrib/Installer/environment.yaml
python-version: 3.9
auto-activate-base: false
- name: Collect Conda Info
shell: bash -l {0}
run: |
conda info
conda env export
- name: Get Version
shell: bash -l {0}
run: |
echo "INSTALLER_VERSION=$(grep '^VERSION' ./contrib/Installer/mtfg-ofs-extension-installer.py | cut -d '=' -f 2 | sed 's/\"//g' | sed 's/ //g')" >> $GITHUB_ENV
- name: Print Version
run: echo $INSTALLER_VERSION
- name: Build Installer
shell: bash -l {0}
working-directory: ./contrib/Installer
run: |
pyinstaller --add-data="assets/*;./" --noupx --onefile mtfg-ofs-extension-installer.py
- name: Upload Installer
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: ./contrib/Installer/dist/mtfg-ofs-extension-installer.exe
asset_name: mtfg-ofs-extension-installer-${{env.INSTALLER_VERSION}}.exe
tag: ${{ github.ref }}
overwrite: true