[#125] Build and test on Linux - #135
Merged
Merged
Conversation
Add a linux-x64 leg to both GitHub Actions matrices so the test suite runs on Linux for every PR and the build action produces a Linux release artifact alongside Windows and Mac. The matrices switch from os/arch plus an exclude list to explicit include entries, because GitHub's Linux runner is "ubuntu-latest" and runs-on can no longer be derived by appending "-latest" to the platform name. The explicit entries also carry the native library each package keeps, which collapses the two per-OS cleanup steps in the build workflow into one. Linux is x64 only: the Unity Editor for Linux ships x86_64 only, and there is no arm64 UnityFileSystemApi.so to pair with an arm64 runner.
bastienunity
approved these changes
Sep 15, 2026
bastienunity
left a comment
There was a problem hiding this comment.
tested on linux (Ubuntu 26.04). I didn't had any valid serialized file for the Unity version it support but I got the proper errors for unsupported serialization format version when trying to de-serialize a content file.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes #125.
The GitHub Actions matrices only covered Windows and Mac, even though the Unity Editor also runs on
Linux and the repo has always bundled a Linux
UnityFileSystemApi.so. This adds a Linux leg to bothworkflows, so the test suite now runs on Linux for every PR (guarding against cross-platform
regressions) and the build action produces a Linux artifact that can be attached to future releases.
No product code changes were needed — the
.sowas already wired up as aCopyToOutputDirectoryitem in
UnityFileSystem.csproj,DllImport("UnityFileSystemApi")resolves it via .NET's defaultprobing on Linux, and there is no platform-conditional code in the tool.
Linux is x64 only. The Unity Editor for Linux ships x86_64 only, and the issue says our
configuration can follow what the Editor supports; there is also no arm64
.soto pair with anarm64 runner.
Changes
Workflows
test.ymland.build.yml: added alinux/x64/ubuntu-latestentry to both matrices.os×archplus anexcludelist to explicitincludeentries.This was needed because GitHub's Linux runner is
ubuntu-latest, soruns-oncan no longer bederived by appending
-latestto the platform name. Keepingos: linux(rather thanubuntu)means artifact and release-zip names stay platform-flavoured:
UnityDataTool-linux-x64-release..build.yml: the two near-duplicate per-OS cleanup steps (one pwsh, one bash) collapse into asingle bash step. Each matrix entry now names the
nativelibits package keeps, and the stepdeletes the other two plus any
.pdb.Docs
README.md: the Downloads section said prebuilt Windows and Mac builds are published; nowWindows, Mac, and Linux.
Testing
todo: a validation on a linux machine that the binary works.
Agent Pre-flight checks: no
OSPlatform/RuntimeInformationbranching in thetool's own code, no hardcoded backslash paths in the C# sources, no embedded Windows paths in the
ExpectedDatagolden files, and.gitattributesalready normalises text to LF on all platforms.🤖 Generated with Claude Code