This commit is contained in:
Renée Kooi 2019-10-05 12:54:14 +02:00
parent 9c9bb8d697
commit f1d92abfe0
No known key found for this signature in database
GPG Key ID: 497533BAECCD642A
3 changed files with 30 additions and 0 deletions

10
.github/workflows/ci.yml vendored Normal file
View File

@ -0,0 +1,10 @@
name: CI
jobs:
smoke-test:
steps:
- uses: actions/checkout@v1
- uses: .
inputs:
version: 0.5.0
- run: zig run src/main.zig
working-directory: test

14
test/build.zig Normal file
View File

@ -0,0 +1,14 @@
const Builder = @import("std").build.Builder;
pub fn build(b: *Builder) void {
const mode = b.standardReleaseOptions();
const exe = b.addExecutable("test", "src/main.zig");
exe.setBuildMode(mode);
exe.install();
const run_cmd = exe.run();
run_cmd.step.dependOn(b.getInstallStep());
const run_step = b.step("run", "Run the app");
run_step.dependOn(&run_cmd.step);
}

6
test/src/main.zig Normal file
View File

@ -0,0 +1,6 @@
const io = @import("std").io;
pub fn main() anyerror!void {
const stdout = try io.getStdOut();
try stdout.write("it works!\n");
}