good morning usa

This commit is contained in:
Yoshman29
2023-01-07 19:55:24 +01:00
parent 7dde43baa4
commit 66dc408fa6
3 changed files with 76 additions and 10 deletions
+35 -2
View File
@@ -6,7 +6,7 @@ on:
jobs:
build:
name: Mac OS Build
runs-on: ubuntu-latest
runs-on: macos-latest
steps:
- name: Pulling the new commit
uses: actions/checkout@v2
@@ -14,6 +14,8 @@ jobs:
uses: krdlab/setup-haxe@v1
with:
haxe-version: 4.2.5
- name: Show current dir
run: pwd
- name: Cache Haxelibs and build
uses: actions/cache@v3
with:
@@ -31,6 +33,7 @@ jobs:
haxelib setup ".haxelib"
- name: Installing libraries
run: |
ls
haxe -cp ./update -D analyzer-optimize -main Update --interp
- name: Building the game
run: |
@@ -44,4 +47,34 @@ jobs:
uses: actions/upload-artifact@v2
with:
name: Update-Mac
path: export/release/mac/bin/CodenameEngine
path: export/release/mac/bin/CodenameEngine
- name: Clear cache
uses: actions/github-script@v6
with:
script: |
const caches = await github.rest.actions.getActionsCacheList({
owner: context.repo.owner,
repo: context.repo.repo,
})
for (const cache of caches.data.actions_caches) {
if (cache.key == "cache-build-mac") {
console.log('Clearing ' + cache.key + '...')
await github.rest.actions.deleteActionsCacheById({
owner: context.repo.owner,
repo: context.repo.repo,
cache_id: cache.id,
})
console.log("Cache cleared.")
}
}
- name: Cache... again
uses: actions/cache@v3
with:
# caching again since for some reason it doesnt work with the first post cache shit
key: cache-build-mac
path: |
.haxelib/
export/release/mac/haxe/
export/release/mac/obj/
restore-keys: |
cache-build-mac