Skip to content

Merge remote-tracking branch 'origin/internal-merge' into internal-merge #1078

Merge remote-tracking branch 'origin/internal-merge' into internal-merge

Merge remote-tracking branch 'origin/internal-merge' into internal-merge #1078

Workflow file for this run

name: Windows Builds
on:
push:
workflow_dispatch:
env:
HAXE_VERSION: 4.3.7
HXCPP_COMPILE_CACHE: ${{ github.workspace }}/.hxcpp_cache
jobs:
build:
name: Windows Build
permissions: write-all
runs-on: windows-latest
steps:
- name: Pulling the new commit
uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Setting up Haxe
uses: krdlab/setup-haxe@v2
with:
haxe-version: ${{ env.HAXE_VERSION }}
# - name: Restore existing build cache for faster compilation
# uses: actions/cache@v4.2.3
# with:
# # not caching the bin folder to prevent asset duplication and stuff like that
# key: cache-build-windows
# path: |
# .haxelib/
# export/release/windows/obj/
- name: Installing/Updating libraries
run: |
haxe -cp commandline -D analyzer-optimize --run Main setup -si --no-vscheck
- name: Building the game
run: |
haxelib run lime setup -alias -y -nocffi
haxelib run lime rebuild hxcpp
haxelib run lime rebuild tools
haxelib run lime rebuild windows -nocolor
haxelib run lime build windows -DCOMPILE_EXPERIMENTAL
- name: Uploading artifact (executable)
uses: actions/upload-artifact@v7
with:
name: Codename Engine (Executable Only)
path: |
export/release/windows/bin/CodenameEngine.exe
export/release/windows/bin/lime.ndll
- name: Uploading artifact (entire build)
uses: actions/upload-artifact@v7
with:
name: Codename Engine
path: export/release/windows/bin
- name: Building the game (debug build)
run: haxelib run lime build windows -debug -DCOMPILE_EXPERIMENTAL
- name: Uploading artifact (debug executable)
uses: actions/upload-artifact@v7
with:
name: Codename Engine Debug (Executable Only)
path: |
export/debug/windows/bin/CodenameEngine.exe
export/debug/windows/bin/lime.ndll
- name: Uploading artifact (entire debug build)
uses: actions/upload-artifact@v7
with:
name: Codename Engine Debug
path: export/debug/windows/bin
# - name: Clearing already existing 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-windows") {
# 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: Uploading new cache
# uses: actions/cache@v4.2.3
# with:
# # caching again since for some reason it doesnt work with the first post cache shit
# key: cache-build-windows
# path: |
# .haxelib/
# export/release/windows/obj/