Skip to content

Commit

Permalink
Create test.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
jdev15 authored Mar 17, 2024
1 parent 6da1af2 commit 1caa65c
Showing 1 changed file with 48 additions and 0 deletions.
48 changes: 48 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@

name: CI

on:
push:
pull_request:
repository_dispatch:
types: [run_build]

jobs:
build:
runs-on: ubuntu-latest
container: ps2dev/ps2dev:latest
steps:

- name: Install dependencies
run: |
apk add build-base git zip
- uses: actions/checkout@v2
- run: |
git config --global --add safe.directory "$GITHUB_WORKSPACE"
git fetch --prune --unshallow
- name: Compile
run: |
make --trace
- name: Get short SHA
id: slug
run: echo "::set-output name=sha8::$(echo ${GITHUB_SHA} | cut -c1-8)"

- name: Upload artifacts
if: ${{ success() }}
uses: actions/upload-artifact@v2
with:
name: OPL-PATINFO-${{ steps.slug.outputs.sha8 }}
path: OPL-Launcher.elf

- name: Create release
if: github.ref == 'refs/heads/master' || github.ref == 'refs/heads/main'
uses: marvinpinto/action-automatic-releases@latest
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
automatic_release_tag: "latest"
title: "Latest development build"
files: OPL-Launcher.elf

0 comments on commit 1caa65c

Please sign in to comment.