Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 12 additions & 14 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,12 @@ jobs:
runs-on: windows-latest
name: Native Compilation
steps:
- uses: actions/checkout@v4
- name: Checkout Repository
uses: actions/checkout@v6

- name: Check CMake version
run: cmake --version

- name: Setup MSVC environment
uses: ilammy/msvc-dev-cmd@v1
with:
arch: amd64

- name: Generate CMake project
run: cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_BUILD_TYPE=RelWithDebInfo -S . -B build -G Ninja

Expand All @@ -35,7 +31,7 @@ jobs:
working-directory: build/

- name: Upload Artifact
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@v6
with:
name: RelWithDebInfo-Native-Clang
path: |
Expand All @@ -46,16 +42,18 @@ jobs:
runs-on: ubuntu-latest
name: Cross-compilation
steps:
- uses: actions/checkout@v4

- name: Setup CMake and build tools
run: |
sudo apt update
sudo apt install -y cmake ninja-build
- name: Checkout Repository
uses: actions/checkout@v6

- name: Setup Zig
uses: mlugg/setup-zig@v2

- name: Check Packages Versions
run: |
cmake --version
ninja --version
zig version

- name: Generate CMake project
run: cmake -DUSE_CROSSCOMPILER=Zig -DCMAKE_BUILD_TYPE=RelWithDebInfo -S . -B build -G Ninja

Expand All @@ -72,7 +70,7 @@ jobs:
working-directory: build/

- name: Upload Artifact
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@v6
with:
name: RelWithDebInfo-Cross
path: |
Expand Down
26 changes: 11 additions & 15 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ jobs:
outputs:
should_run: ${{ steps.should_run.outputs.should_run }}
steps:
- uses: actions/checkout@v4
- name: Checkout Repository
uses: actions/checkout@v6

- id: should_run
name: Check if latest commit date is within the previous 24 hours
Expand All @@ -37,26 +38,20 @@ jobs:
full_sha: ${{ steps.var.outputs.full_sha }}
short_sha: ${{ steps.var.outputs.short_sha }}
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- name: Checkout Repository
uses: actions/checkout@v6

- name: Check CMake version
run: cmake --version

- name: Setup MSVC environment
uses: ilammy/msvc-dev-cmd@v1
with:
arch: amd64

- name: Generate CMake project
run: cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_BUILD_TYPE=RelWithDebInfo -S . -B build -G Ninja

- name: Build 64bit RelWithDebInfo DLL
run: cmake --build ./build --config RelWithDebInfo --target YimMenuV2 --

- name: Upload Artifact
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@v6
with:
name: binary
path: |
Expand All @@ -75,11 +70,12 @@ jobs:
needs: build_nightly
if: needs.check_recent_commit.outputs.should_run == 'true'
steps:
- uses: actions/checkout@v4
- name: Checkout Repository
uses: actions/checkout@v6

- name: Delete Existing Release
id: delete_release
uses: actions/github-script@v7
uses: actions/github-script@v8
with:
script: |
const owner = context.repo.owner;
Expand Down Expand Up @@ -119,7 +115,7 @@ jobs:
}

- name: Download Artifact
uses: actions/download-artifact@v4
uses: actions/download-artifact@v7
with:
name: binary

Expand All @@ -131,7 +127,7 @@ jobs:
cat sha256.checksum

- name: Nightly Release
uses: softprops/action-gh-release@v2.2.2
uses: softprops/action-gh-release@v2
with:
name: Nightly [${{ needs.build_nightly.outputs.short_sha }}]
tag_name: nightly
Expand Down Expand Up @@ -159,4 +155,4 @@ jobs:
${{ needs.build_nightly.outputs.full_sha }}
```
files: |
YimMenuV2.dll
YimMenuV2.dll
4 changes: 2 additions & 2 deletions .github/workflows/pr-comment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
# Assume the 0th index in the array of found PRs is the correct one (it seems to usually be the latest one)
PR_NUM=$(echo $PR_RAW | jq '.items | map(select(.repository_url=="https://api.github.com/repos/${{ github.repository }}")) | .[0].number')
echo "PR_NUM=${PR_NUM}" >> $GITHUB_ENV
- uses: actions/github-script@v7
- uses: actions/github-script@v8
with:
# This snippet is public-domain, taken from
# https://github.com/oprypin/nightly.link/blob/master/.github/workflows/pr-comment.yml
Expand Down Expand Up @@ -59,4 +59,4 @@ jobs:
}

core.info("Review thread message body:", body);
await upsertComment(owner, repo, ${{ env.PR_NUM }}, "nightly-link", body);
await upsertComment(owner, repo, ${{ env.PR_NUM }}, "nightly-link", body);