Skip to content

update

update #1

# This is a basic workflow to help you get started with Actions
name: Cx_Freeze on linux
# Controls when the workflow will run
on:
# Triggers the workflow on push or pull request events
push:
branches:
- master
pull_request:
branches:
- master
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
build:
# The type of runner that the job will run on
runs-on: ubuntu-latest
env:
PYTEST_ADDOPTS: "-rA --color=yes --tb=long --showlocals"
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v4
with:
submodules: 'true'
- name: Install poetry
run: pipx install poetry
- name: Setup Python 3.9
uses: actions/setup-python@v5
with:
python-version: 3.9
cache: 'poetry'
- name: Install dependencies
run: |
poetry install
- name: Build with Cx_Freeze for linux
run: poetry run python setup.py build_exe -b dist
- name: Switch code page
run: |
chcp 65001
- name: Set VERSION variable for linux
run: |
echo "VERSION=$(poetry run python scripts/version.py)" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
- name: Upload build artifact
uses: actions/upload-artifact@v4
with:
name: JavSPn-${{ env.VERSION }}-linux-amd64
path: dist