Skip to content

Commit ef6f817

Browse files
committed
Workflow tweaks (Yoinked from Codename) + fixes
1 parent 705fd6d commit ef6f817

8 files changed

+140
-9
lines changed

.github/workflows/linux.yml

+44-1
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,18 @@ jobs:
1919
- uses: krdlab/setup-haxe@v1
2020
with:
2121
haxe-version: 4.2.5
22+
23+
- name: Get last Action build
24+
uses: actions/cache@v3
25+
with:
26+
# not caching the bin folder to prevent asset duplication and stuff like that
27+
key: cache-build-linux
28+
path: |
29+
.haxelib/
30+
export/release/linux/haxe/
31+
export/release/linux/obj/
32+
restore-keys: |
33+
cache-build-linux
2234
# Runs a set of commands using the runners shell
2335
- name: script run line haha
2436
run: |
@@ -40,7 +52,7 @@ jobs:
4052
haxelib install flixel-addons
4153
haxelib install flixel-ui
4254
haxelib install hscript
43-
haxelib install hxCodec
55+
haxelib git hxCodec https://github.com/polybiusproxy/hxCodec
4456
haxelib install flixel-addons
4557
haxelib git faxe https://github.com/uhrobots/faxe
4658
haxelib git polymod https://github.com/BoloVEVO/polymod.git
@@ -60,3 +72,34 @@ jobs:
6072
with:
6173
name: Linux Build
6274
path: export/release/linux/bin
75+
76+
- name: Clear current Action Cache
77+
uses: actions/github-script@v6
78+
with:
79+
script: |
80+
const caches = await github.rest.actions.getActionsCacheList({
81+
owner: context.repo.owner,
82+
repo: context.repo.repo,
83+
})
84+
for (const cache of caches.data.actions_caches) {
85+
if (cache.key == "cache-build-linux") {
86+
console.log('Clearing ' + cache.key + '...')
87+
await github.rest.actions.deleteActionsCacheById({
88+
owner: context.repo.owner,
89+
repo: context.repo.repo,
90+
cache_id: cache.id,
91+
})
92+
console.log("Cache cleared.")
93+
}
94+
}
95+
- name: Caching new Action
96+
uses: actions/cache@v3
97+
with:
98+
# caching again since for some reason it doesnt work with the first post cache shit
99+
key: cache-build-linux
100+
path: |
101+
.haxelib/
102+
export/release/linux/haxe/
103+
export/release/linux/obj/
104+
restore-keys: |
105+
cache-build-linux

.github/workflows/mac.yml

+44-1
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,18 @@ jobs:
1919
- uses: krdlab/setup-haxe@v1
2020
with:
2121
haxe-version: 4.2.4
22+
23+
- name: Get last Action build
24+
uses: actions/cache@v3
25+
with:
26+
# not caching the bin folder to prevent asset duplication and stuff like that
27+
key: cache-build-mac
28+
path: |
29+
.haxelib/
30+
export/release/macos/haxe/
31+
export/release/macos/obj/
32+
restore-keys: |
33+
cache-build-mac
2234
# Runs a set of commands using the runners shell
2335
- name: script run line haha
2436
run: |
@@ -34,7 +46,7 @@ jobs:
3446
haxelib install flixel-addons
3547
haxelib install flixel-ui
3648
haxelib install hscript
37-
haxelib install hxCodec
49+
haxelib git hxCodec https://github.com/polybiusproxy/hxCodec
3850
haxelib install flixel-addons
3951
haxelib git faxe https://github.com/uhrobots/faxe
4052
haxelib git polymod https://github.com/BoloVEVO/polymod.git
@@ -54,3 +66,34 @@ jobs:
5466
with:
5567
name: MacOS Build
5668
path: export/release/macos/bin
69+
70+
- name: Clear current Action Cache
71+
uses: actions/github-script@v6
72+
with:
73+
script: |
74+
const caches = await github.rest.actions.getActionsCacheList({
75+
owner: context.repo.owner,
76+
repo: context.repo.repo,
77+
})
78+
for (const cache of caches.data.actions_caches) {
79+
if (cache.key == "cache-build-mac") {
80+
console.log('Clearing ' + cache.key + '...')
81+
await github.rest.actions.deleteActionsCacheById({
82+
owner: context.repo.owner,
83+
repo: context.repo.repo,
84+
cache_id: cache.id,
85+
})
86+
console.log("Cache cleared.")
87+
}
88+
}
89+
- name: Caching new Action
90+
uses: actions/cache@v3
91+
with:
92+
# caching again since for some reason it doesnt work with the first post cache shit
93+
key: cache-build-mac
94+
path: |
95+
.haxelib/
96+
export/release/macos/haxe/
97+
export/release/macos/obj/
98+
restore-keys: |
99+
cache-build-mac

.github/workflows/windows.yml

+45-1
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,18 @@ jobs:
1919
- uses: krdlab/setup-haxe@v1
2020
with:
2121
haxe-version: 4.2.4
22+
23+
- name: Get last Action build
24+
uses: actions/cache@v3
25+
with:
26+
# not caching the bin folder to prevent asset duplication and stuff like that
27+
key: cache-build-windows
28+
path: |
29+
.haxelib/
30+
export/release/windows/haxe/
31+
export/release/windows/obj/
32+
restore-keys: |
33+
cache-build-windows
2234
# Runs a set of commands using the runners shell
2335
- name: script run line haha
2436
run: |
@@ -37,7 +49,7 @@ jobs:
3749
haxelib install flixel-addons
3850
haxelib install flixel-ui
3951
haxelib install hscript
40-
haxelib install hxCodec
52+
haxelib git hxCodec https://github.com/polybiusproxy/hxCodec
4153
haxelib install flixel-addons
4254
haxelib git faxe https://github.com/uhrobots/faxe
4355
haxelib git polymod https://github.com/BoloVEVO/polymod.git
@@ -57,3 +69,35 @@ jobs:
5769
with:
5870
name: Windows Build
5971
path: export/release/windows/bin
72+
73+
- name: Clear current Action Cache
74+
uses: actions/github-script@v6
75+
with:
76+
script: |
77+
const caches = await github.rest.actions.getActionsCacheList({
78+
owner: context.repo.owner,
79+
repo: context.repo.repo,
80+
})
81+
for (const cache of caches.data.actions_caches) {
82+
if (cache.key == "cache-build-windows") {
83+
console.log('Clearing ' + cache.key + '...')
84+
await github.rest.actions.deleteActionsCacheById({
85+
owner: context.repo.owner,
86+
repo: context.repo.repo,
87+
cache_id: cache.id,
88+
})
89+
console.log("Cache cleared.")
90+
}
91+
}
92+
93+
- name: Caching new Action
94+
uses: actions/cache@v3
95+
with:
96+
# caching again since for some reason it doesnt work with the first post cache shit
97+
key: cache-build-windows
98+
path: |
99+
.haxelib/
100+
export/release/windows/haxe/
101+
export/release/windows/obj/
102+
restore-keys: |
103+
cache-build-windows

.vscode/launch.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
{
1919
"name": "Windows x32 (Debug)",
2020
"type": "hxcpp",
21-
"preLaunchTask": "Build Windows x32 (Release)",
21+
"preLaunchTask": "Build Windows x32 (Debug)",
2222
"request": "launch",
2323
"program": "${workspaceFolder}/export/debug-32bits/windows/bin/Kade Engine.exe"
2424
},

Project.xml

+3-2
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,8 @@
3535

3636
<set name="BUILD_DIR" value="export/debug" if="debug" />
3737
<set name="BUILD_DIR" value="export/release" unless="debug" />
38-
<set name="BUILD_DIR" value="export/32bit" if="32bits" />
38+
<set name="BUILD_DIR" value="export/release-32bits" if="32bits" unless="32bits debug"/>
39+
<set name="BUILD_DIR" value="export/debug-32bits" if="32bits debug" />
3940

4041
<source name="source" />
4142

@@ -151,7 +152,7 @@
151152
<!-- ______________________________ Haxedefines _____________________________ -->
152153

153154
<define name="hscriptPos" />
154-
<haxeflag name="-dce no" />
155+
<haxeflag name="--dce full" />
155156

156157
<!--Enable the Flixel core recording system-->
157158
<!--<haxedef name="FLX_RECORD" />-->

appveyor-linux.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ install:
2323
- haxelib install flixel-addons
2424
- haxelib install flixel-ui
2525
- haxelib install hscript
26-
- haxelib install hxCodec
26+
- haxelib git hxCodec https://github.com/polybiusproxy/hxCodec
2727
- haxelib git faxe https://github.com/uhrobots/faxe
2828
- haxelib git polymod https://github.com/BoloVEVO/polymod.git
2929
- haxelib git discord_rpc https://github.com/Aidan63/linc_discord-rpc

appveyor-macos.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ install:
2424
- haxelib install flixel-addons
2525
- haxelib install flixel-ui
2626
- haxelib install hscript
27-
- haxelib install hxCodec
27+
- haxelib git hxCodec https://github.com/polybiusproxy/hxCodec
2828
- haxelib git faxe https://github.com/uhrobots/faxe
2929
- haxelib git polymod https://github.com/BoloVEVO/polymod.git
3030
- haxelib git discord_rpc https://github.com/Aidan63/linc_discord-rpc

appveyor-windows.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ install:
2828
- haxelib install flixel-addons
2929
- haxelib install flixel-ui
3030
- haxelib install hscript
31-
- haxelib install hxCodec
31+
- haxelib git hxCodec https://github.com/polybiusproxy/hxCodec
3232
- haxelib install flixel-addons
3333
- haxelib git faxe https://github.com/uhrobots/faxe
3434
- haxelib git polymod https://github.com/BoloVEVO/polymod.git

0 commit comments

Comments
 (0)