Skip to content

Commit

Permalink
Upgrade to Zig 0.13 (#19)
Browse files Browse the repository at this point in the history
  • Loading branch information
abhinav authored Aug 10, 2024
1 parent 6010295 commit d15805f
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 5 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:

- uses: goto-bus-stop/setup-zig@v2
with:
version: 0.12.0 # most recent stable
version: 0.13.0 # most recent stable

- name: Check formatting
run: zig fmt --check .
Expand All @@ -31,7 +31,7 @@ jobs:
continue-on-error: ${{ matrix.allow-fail }}
strategy:
matrix:
zig-version: ['0.12.0']
zig-version: ['0.13.0']
os: [ubuntu-latest, windows-latest]
allow-fail: [false]
include:
Expand Down
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/cover
/zig-out
/zig-cache
/.zig-cache
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## Unreleased
### Changed
- Switch to Zig 0.13.0.

## 0.5.0 - 2024-05-02
### Changed
- Revert release 0.4.0.
Expand Down
4 changes: 2 additions & 2 deletions build.zig
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ pub fn build(b: *std.Build) void {
) orelse b.pathFromRoot("cover");

const txtar = b.addModule("txtar", .{
.root_source_file = .{ .path = "src/txtar.zig" },
.root_source_file = b.path("src/txtar.zig"),
});

const lib = b.addStaticLibrary(.{
Expand All @@ -33,7 +33,7 @@ pub fn build(b: *std.Build) void {

if (cover) {
run_unit_tests.has_side_effects = true;
run_unit_tests.argv.insertSlice(0, &[_]std.Build.Step.Run.Arg{
run_unit_tests.argv.insertSlice(b.allocator, 0, &[_]std.Build.Step.Run.Arg{
.{ .bytes = b.dupe("kcov") },
.{ .bytes = b.fmt("--include-path={s}", .{b.pathFromRoot("src")}) },
.{ .bytes = b.fmt("--strip-path={s}", .{b.pathFromRoot(".")}) },
Expand Down

0 comments on commit d15805f

Please sign in to comment.