Skip to content

unspecified - test for cd #15

unspecified - test for cd

unspecified - test for cd #15

Workflow file for this run

name: CD
on:
push:
branches:
- master
pull_request:
types:
- synchronize
- opened
concurrency:
group: ${{ github.ref }}-${{ github.workflow }}-${{ github.event_name }}
cancel-in-progress: true
jobs:
cd_upload_artifacts_to_release:
name: Upload
if: github.event_name == 'push'
runs-on: ubuntu-latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
steps:
- uses: actions/checkout@v4
- name: Install github-release
run: |
go install github.com/github-release/github-release@latest
echo "GOPATH=$(go env GOPATH)" >> $GITHUB_ENV
echo "$(go env GOPATH)/bin" >> $GITHUB_PATH
- name: Install Python & Pip
uses: actions/setup-python@v5
with:
python-version: '3.10'
cache: 'pip'
- name: Create Executable
run: |
git clone https://github.com/Dungeons-of-Kathallion/Bane-Of-Wargs.git
mkdir yamale
echo "4.0.4" >> yamale/VERSION
pip install -r requirements.txt
pip install PyInstaller
python -m PyInstaller --console --onefile --name Bane-Of-Wargs source/main.py source/battle.py source/check_yaml.py source/colors.py source/map_item.py source/train.py --add-data yamale/VERSION:yamale
- name: Set environment variables
run: |
echo "GITHUB_USER=$( echo ${{ github.repository }} | cut -d/ -f1 )" >> $GITHUB_ENV
echo "GITHUB_REPO=$( echo ${{ github.repository }} | cut -d/ -f2 )" >> $GITHUB_ENV
- name: Move/Create continuous tag
run: |
git tag --force 9.9.9-continuous ${{ github.sha }}
git push --tags --force
- name: Setup continuous release
run: |
DESCRIPTION="This is an automated build of the latest source triggered by commit ${{ github.sha }} (@${{ github.actor }}). It may be unstable or even crash, corrupt your save or eat your kitten. Use with caution!
This release was made to be compatible with **latest stable version** of Python.
_Certain features will not work with earlier versions of Python._"
if ! github-release info -t 9.9.9-continuous > /dev/null 2>&1; then
github-release release \
--tag 9.9.9-continuous \
--name "Continuous Build" \
--description "$DESCRIPTION" \
--pre-release
else
github-release edit \
--tag 9.9.9-continuous \
--name "Continuous Build" \
--description "$DESCRIPTION" \
--pre-release
fi
- name: Add executable
run: |
github-release upload \
--tag 9.9.9-continuous \
--replace \
--name Bane-Of-Wargs \
--file dist/Bane-Of-Wargs