Compare commits
6 Commits
79e77c40eb
...
b0ef8ebe63
Author | SHA1 | Date | |
---|---|---|---|
b0ef8ebe63 | |||
c5436c4e0a | |||
2457ad2c7b | |||
cd43ead0ff | |||
eb97787671 | |||
7cfc669a1d |
10
.github/workflows/zig-build.yaml
vendored
10
.github/workflows/zig-build.yaml
vendored
|
@ -7,21 +7,23 @@ on:
|
||||||
- '!zig-develop*'
|
- '!zig-develop*'
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
- uses: elerch/setup-zig@v3
|
- uses: elerch/setup-zig@v3
|
||||||
with:
|
with:
|
||||||
version: 0.12.0
|
version: 0.12.0
|
||||||
- uses: Hanaasagi/zig-action-cache@v1.1.5
|
- uses: elerch/zig-action-cache@v1.1.6
|
||||||
- name: Build project
|
- name: Build project
|
||||||
run: zig build
|
run: zig build --summary all
|
||||||
- name: Run tests
|
- name: Run tests
|
||||||
run: zig build test --summary all
|
run: zig build test --summary all
|
||||||
- name: Notify
|
- name: Notify
|
||||||
uses: elerch/action-notify-ntfy@v2
|
uses: elerch/action-notify-ntfy@v2.github
|
||||||
if: ${{ github.env.GITEA_ACTIONS == 'true' }}
|
if: always() && env.GITEA_ACTIONS == 'true'
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.NTFY_HOST }}
|
host: ${{ secrets.NTFY_HOST }}
|
||||||
topic: ${{ secrets.NTFY_TOPIC }}
|
topic: ${{ secrets.NTFY_TOPIC }}
|
||||||
|
status: ${{ job.status }}
|
||||||
user: ${{ secrets.NTFY_USER }}
|
user: ${{ secrets.NTFY_USER }}
|
||||||
password: ${{ secrets.NTFY_PASSWORD }}
|
password: ${{ secrets.NTFY_PASSWORD }}
|
||||||
|
|
2
.gitignore
vendored
2
.gitignore
vendored
|
@ -1,3 +1,3 @@
|
||||||
zig-cache
|
|
||||||
zig-out
|
zig-out
|
||||||
core
|
core
|
||||||
|
.zig-cache
|
||||||
|
|
|
@ -19,7 +19,7 @@ pub fn build(b: *std.Build) void {
|
||||||
.name = "smithy",
|
.name = "smithy",
|
||||||
// In this case the main source file is merely a path, however, in more
|
// In this case the main source file is merely a path, however, in more
|
||||||
// complicated build scripts, this could be a generated file.
|
// complicated build scripts, this could be a generated file.
|
||||||
.root_source_file = .{ .path = "src/smithy.zig" },
|
.root_source_file = b.path("src/smithy.zig"),
|
||||||
.target = target,
|
.target = target,
|
||||||
.optimize = optimize,
|
.optimize = optimize,
|
||||||
});
|
});
|
||||||
|
@ -30,14 +30,14 @@ pub fn build(b: *std.Build) void {
|
||||||
b.installArtifact(lib);
|
b.installArtifact(lib);
|
||||||
|
|
||||||
const module = b.addModule("smithy", .{
|
const module = b.addModule("smithy", .{
|
||||||
.root_source_file = .{ .path = "src/smithy.zig" },
|
.root_source_file = b.path("src/smithy.zig"),
|
||||||
});
|
});
|
||||||
lib.root_module.addImport("smithy", module);
|
lib.root_module.addImport("smithy", module);
|
||||||
|
|
||||||
// Creates a step for unit testing. This only builds the test executable
|
// Creates a step for unit testing. This only builds the test executable
|
||||||
// but does not run it.
|
// but does not run it.
|
||||||
const main_tests = b.addTest(.{
|
const main_tests = b.addTest(.{
|
||||||
.root_source_file = .{ .path = "src/smithy.zig" },
|
.root_source_file = b.path("src/smithy.zig"),
|
||||||
.target = target,
|
.target = target,
|
||||||
.optimize = optimize,
|
.optimize = optimize,
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue
Block a user