-
Notifications
You must be signed in to change notification settings - Fork 3
49 lines (46 loc) · 1.43 KB
/
pack-randomizer.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
name: Pack Randomizer
on:
workflow_dispatch: # Allows manual triggers
push:
branches:
- main
paths:
- "Dolphin scripts/Entrance Randomizer/**"
- "Dolphin scripts/pack-rando.ps1"
- "Various technical notes/transition_infos.json"
- ".github/workflows/pack-randomizer.yaml"
pull_request:
branches:
- main
paths:
- "Dolphin scripts/Entrance Randomizer/**"
- "Dolphin scripts/pack-rando.ps1"
- "Various technical notes/transition_infos.json"
- ".github/workflows/pack-randomizer.yaml"
env:
PIP_DISABLE_PIP_VERSION_CHECK: 1
FORCE_COLOR: 1
jobs:
pack:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: '& "Dolphin scripts/pack-rando.ps1"'
shell: pwsh
# upload-artifact will double zip, so unpack first
# https://github.com/actions/upload-artifact/issues/39
- name: Get pack filename
id: packname
run: |
echo "packname=$(
find -name 'Entrance Randomizer v*.zip' | sed 's/\.zip$//1' | sed 's/^\.\///1'
)" >> $GITHUB_OUTPUT
- name: Extract premade archive
run: |
7z x \
'${{ steps.packname.outputs.packname }}.zip' \
-o'${{ steps.packname.outputs.packname }}'
- uses: actions/upload-artifact@v4
with:
name: ${{ steps.packname.outputs.packname }}
path: ${{ steps.packname.outputs.packname }}/*