This migrates from zig 0.13 to 0.15.2. In addition to dealing with breaking changes in the build system and standard library APIs, the architecture was changed substantially. We now build a standalone CLI, and use that to execute the commands. This avoids sandboxing issues related to TLS and enables easier testing. The commit also includes a simple zip implementation (store only, single file) which avoids the platform restriction (i.e. this build can now theoretically work on Windows).
36 lines
964 B
YAML
36 lines
964 B
YAML
# See https://pre-commit.com for more information
|
|
# See https://pre-commit.com/hooks.html for more hooks
|
|
repos:
|
|
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
rev: v3.2.0
|
|
hooks:
|
|
- id: trailing-whitespace
|
|
- id: end-of-file-fixer
|
|
- id: check-yaml
|
|
- id: check-added-large-files
|
|
- repo: https://github.com/batmac/pre-commit-zig
|
|
rev: v0.3.0
|
|
hooks:
|
|
- id: zig-fmt
|
|
- repo: local
|
|
hooks:
|
|
- id: zlint
|
|
name: Run zlint
|
|
entry: zlint
|
|
args: ["--deny-warnings", "--fix"]
|
|
language: system
|
|
types: [zig]
|
|
- repo: https://github.com/batmac/pre-commit-zig
|
|
rev: v0.3.0
|
|
hooks:
|
|
- id: zig-build
|
|
- repo: local
|
|
hooks:
|
|
- id: test
|
|
name: Run zig build test
|
|
entry: zig
|
|
# args: ["build", "coverage", "-Dcoverage-threshold=80"]
|
|
args: ["build", "test"]
|
|
language: system
|
|
types: [file]
|
|
pass_filenames: false
|