Skip to content

Commit

Permalink
Taskfile build
Browse files Browse the repository at this point in the history
  • Loading branch information
cmbntr committed Jan 28, 2024
1 parent 22e71f2 commit 5b51d05
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 0 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
zig-cache
zig-out
release
23 changes: 23 additions & 0 deletions Taskfile.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# https://taskfile.dev

version: '3'

vars:
PROJECT: xorot
OPTIMIZE: ReleaseSmall

tasks:
default:
cmds:
- cmd: |
zig build install -Doptimize={{.OPTIMIZE}} -Dtarget={{.ITEM}} -p release/{{.PROJECT}}-{{.ITEM}}
cd release && zip -r {{.PROJECT}}-{{.ITEM}}.zip {{.PROJECT}}-{{.ITEM}}/
for:
- x86_64-linux-musl
- aarch64-linux-musl
- x86_64-windows-msvc
- wasm32-wasi-none
- x86_64-macos
- aarch64-macos
11 changes: 11 additions & 0 deletions default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{ pkgs ? import <nixpkgs> {} }:

pkgs.mkShell {
buildInputs = with pkgs; [
go-task
zip
zig
zls
];
}

0 comments on commit 5b51d05

Please sign in to comment.