summaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
authorTrueffel <106771418+Trueffeloot@users.noreply.github.com>2023-06-20 02:21:29 +0200
committerGitHub <noreply@github.com>2023-06-19 18:21:29 -0600
commit9ba4267e6f22f4b9ab9de09fc662cf23a0084b3c (patch)
treea0b82ace6315c767249652660bb1440daa109002 /.github
parent2e6e46892826c329a7a137e5ef081d81d2775a87 (diff)
TP Progress step for displaying (#350)
* d_a_obj_prop OK * tp-progress (#1) * Tp-progress-work-2 (#2) * seperate (#3)
Diffstat (limited to '.github')
-rw-r--r--.github/workflows/cd.yml35
-rw-r--r--.github/workflows/ci.yml (renamed from .github/workflows/ok-check.yml)21
2 files changed, 49 insertions, 7 deletions
diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml
new file mode 100644
index 0000000000..8509db580f
--- /dev/null
+++ b/.github/workflows/cd.yml
@@ -0,0 +1,35 @@
+name: CD
+
+on:
+ push:
+ branches:
+ - master
+
+env:
+ WORKFLOW: "ci.yml"
+
+jobs:
+ download:
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v3
+ - name: Get latest workflow run ID
+ id: get_run_id
+ run: |
+ RUN_ID=$(curl --request GET \
+ --url https://api.github.com/repos/${{ github.repository }}/actions/workflows/${{ env.WORKFLOW }}/runs \
+ --header 'authorization: Bearer ${{ secrets.GITHUB_TOKEN }}' \
+ --header 'content-type: application/json' | jq '.workflow_runs[0].id')
+ echo "run_id=$RUN_ID" >> $GITHUB_OUTPUT
+ - name: Download artifact
+ uses: dawidd6/action-download-artifact@v2.27.0
+ with:
+ github_token: ${{ secrets.GITHUB_TOKEN }}
+ run_id: ${{ steps.get_run_id.outputs.run_id }}
+ name: artifact-${{ steps.get_run_id.outputs.run_id }}
+ workflow: ${{ env.WORKFLOW }}
+ - name: Upload Progress to Frogress
+ env:
+ PROGRESS_API_KEY: ${{ secrets.FROGRESS_API_KEY }}
+ run: ./tools/upload-progress.py -b https://progress.deco.mp/ -p twilightprincess -v gcn_usa progress-${{ steps.get_run_id.outputs.run_id }}.json \ No newline at end of file
diff --git a/.github/workflows/ok-check.yml b/.github/workflows/ci.yml
index f2c3446476..09ae82e493 100644
--- a/.github/workflows/ok-check.yml
+++ b/.github/workflows/ci.yml
@@ -1,20 +1,27 @@
-name: OK Check
+name: CI
-on: pull_request
+on:
+ pull_request:
+ branches:
+ - master
jobs:
build:
-
runs-on: ubuntu-latest
container:
image: ghcr.io/pheenoh/zeldaret-tp:latest
-
steps:
- name: Checkout
- uses: actions/checkout@v1
- with:
- token: ${{secrets.MY_REPO_PAT}}
+ uses: actions/checkout@v3
- name: Copy in dol and compilers
run: cp /tmp/baserom.dol ./baserom.dol && cp -r /tmp/mwcc_compiler/ tools/mwcc_compiler && cp tools/mwcc_compiler/2.7/mwcceppc.exe tools/mwcc_compiler/2.7/mwcceppc_modded.exe && chown root /github/home/
- name: Run Make (OK)
run: make all rels && ./tp check --rels
+ - name: Create JSON for Progress
+ run: ./tp progress -f JSON > progress-${{ github.run_id }}.json
+ - name: Upload artifact
+ uses: actions/upload-artifact@v3
+ with:
+ name: artifact-${{ github.run_id }}
+ path: ./progress-${{ github.run_id }}.json
+ \ No newline at end of file