Skip to content

Commit

Permalink
Bump to zig 0.13!
Browse files Browse the repository at this point in the history
  • Loading branch information
batiati committed Jun 15, 2024
1 parent cd3081a commit ae5ecc1
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 12 deletions.
9 changes: 5 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Matrix Build
on:
push:
push:
branches: [ master ]
pull_request:
branches: [ master ]
Expand All @@ -10,7 +10,7 @@ jobs:
test:
strategy:
fail-fast: false
matrix:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
include:
- os: windows-latest
Expand Down Expand Up @@ -38,11 +38,12 @@ jobs:
run: |
sudo apt-get install -y kcov
# No comptime tests for now.
- name: Run Tests
run: |
zig version
zig build test ${{ matrix.coverage }}
zig build test -Dcomptime-tests=false ${{ matrix.coverage }}
- name: Upload Codecov
if: ${{ matrix.os == 'ubuntu-latest' }}
env:
Expand Down
4 changes: 2 additions & 2 deletions benchmark/build.zig
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@ pub fn build(b: *std.Build) void {

const exe = b.addExecutable(.{
.name = "benchmark",
.root_source_file = .{ .path = "src/ramhorns_bench.zig" },
.root_source_file = b.path("src/ramhorns_bench.zig"),
.target = target,
.optimize = mode,
});
exe.root_module.addAnonymousImport("mustache", .{
.root_source_file = .{ .path = "../src/mustache.zig" },
.root_source_file = b.path("../src/mustache.zig"),
});
exe.linkLibC();
b.installArtifact(exe);
Expand Down
2 changes: 1 addition & 1 deletion install_zig.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/env sh
set -eu

ZIG_RELEASE_DEFAULT="latest"
ZIG_RELEASE_DEFAULT="0.13.0"
# Default to the release build, or allow the latest dev build, or an explicit release version:
ZIG_RELEASE=${1:-$ZIG_RELEASE_DEFAULT}
if [ "$ZIG_RELEASE" = "latest" ]; then
Expand Down
4 changes: 2 additions & 2 deletions samples/dotnet/mustache.samples/mustache.samples.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net6.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<RollForward>LatestMajor</RollForward>
Expand All @@ -21,5 +21,5 @@
<Content Include="../../../lib/osx-x64/libmustache.dylib" Condition="$([MSBuild]::IsOSPlatform('OSX'))">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
</ItemGroup>
</ItemGroup>
</Project>
2 changes: 1 addition & 1 deletion samples/dotnet/mustache/mustache.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<AllowUnsafeBlocks>True</AllowUnsafeBlocks>
Expand Down
4 changes: 2 additions & 2 deletions samples/zig/build.zig
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@ pub fn build(b: *std.Build) void {
const exe = b.addExecutable(
.{
.name = "samples",
.root_source_file = .{ .path = "src/main.zig" },
.root_source_file = b.path("src/main.zig"),
.target = target,
.optimize = mode,
},
);
exe.root_module.addAnonymousImport("mustache", .{
.root_source_file = .{ .path = "../../src/mustache.zig" },
.root_source_file = b.path("../../src/mustache.zig"),
});
b.installArtifact(exe);

Expand Down

0 comments on commit ae5ecc1

Please sign in to comment.