Skip to content

Package

Package #21

Workflow file for this run

name: Package
on:
workflow_dispatch:
inputs:
tags:
description: 'test build tags'
required: true
type: string
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: version
run: echo "version=${{ inputs.tags }}" >> $GITHUB_STATE
id: version
- name: release
id: create_release
uses: softprops/action-gh-release@v1
with:
tag_name: ${{ inputs.tags }}
- name: Package Application
uses: JackMcKew/pyinstaller-action-windows@python3-10-pyinstaller-5-3
with:
path: .
pypi_index_url: https://pypi.tuna.tsinghua.edu.cn/simple
- name: Copy Files and Tar
run: |
cp config.yaml LICENSE README.md README_zh.md dist/windows
cp -r imgs dist/windows
cp -r resources dist/windows
cd dist/windows && zip -q -r projz_Winndows.zip ./* && cd -
# - name: Upload a Build Artifact
# uses: actions/upload-artifact@v4
# id: artifact
# with:
# name: projz-Winndows_${{ inputs.tags }}
# path: dist/windows
- name: Upload Windows Artifact
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ github.token }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: dist/windows/projz_Winndows.zip
asset_name: projz-Winndows_${{ inputs.tags }}.zip
asset_content_type: application/zip