mirror of
https://github.com/DaedalusX64/daedalus.git
synced 2025-04-02 10:21:48 -04:00
76 lines
No EOL
1.9 KiB
YAML
76 lines
No EOL
1.9 KiB
YAML
name: CI
|
|
|
|
on:
|
|
push:
|
|
pull_request:
|
|
repository_dispatch:
|
|
types: [run_build]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
container: pspdev/pspdev:latest
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
apk add build-base git bash cmake
|
|
|
|
- name: Compile project
|
|
run: |
|
|
./build_daedalus.sh PSP
|
|
|
|
- name: Get short SHA
|
|
id: slug
|
|
run: echo "::set-output name=sha8::$(echo ${GITHUB_SHA} | cut -c1-8)"
|
|
|
|
- name: Prepare artefacts
|
|
run: |
|
|
tar -zcvf daedalusX64.tar.gz \
|
|
DaedalusX64/dvemgr.prx \
|
|
DaedalusX64/exception.prx \
|
|
DaedalusX64/imposectrl.prx \
|
|
DaedalusX64/mediaengine.prx \
|
|
DaedalusX64/EBOOT.PBP \
|
|
DaedalusX64/roms.ini \
|
|
DaedalusX64/readme.txt \
|
|
DaedalusX64/copying.txt \
|
|
DaedalusX64/SaveStates \
|
|
DaedalusX64/Resources \
|
|
DaedalusX64/Languages \
|
|
DaedalusX64/ControllerConfigs \
|
|
DaedalusX64/Cache
|
|
|
|
|
|
- name: Upload artifacts
|
|
if: ${{ success() }}
|
|
uses: actions/upload-artifact@v2
|
|
with:
|
|
name: DaedalusX64-${{ steps.slug.outputs.sha8 }}
|
|
path: daedalusX64.tar.gz
|
|
|
|
- name: Extract tag name
|
|
if: startsWith(github.ref, 'refs/tags/')
|
|
id: tag
|
|
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\//}
|
|
|
|
- name: Create pre-release
|
|
if: github.ref == 'refs/heads/master'
|
|
uses: softprops/action-gh-release@v1
|
|
with:
|
|
files: daedalusX64.tar.gz
|
|
prerelease: true
|
|
name: "Development build"
|
|
tag_name: "latest"
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- name: Release
|
|
if: startsWith(github.ref, 'refs/tags/')
|
|
uses: softprops/action-gh-release@v1
|
|
with:
|
|
files: daedalusX64.tar.gz
|
|
tag_name: ${{ steps.tag.outputs.VERSION }}
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |