aboutsummaryrefslogtreecommitdiff
path: root/templates/go/.drone.yml
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--templates/go/.drone.yml32
1 files changed, 32 insertions, 0 deletions
diff --git a/templates/go/.drone.yml b/templates/go/.drone.yml
new file mode 100644
index 0000000..13b4026
--- /dev/null
+++ b/templates/go/.drone.yml
@@ -0,0 +1,32 @@
+---
+kind: pipeline
+type: docker
+name: checks
+
+trigger:
+ event:
+ - push
+ - pull_request
+
+steps:
+ - name: Run checks
+ image: nixpkgs/nix-flakes:nixos-22.11
+ commands:
+ - nix develop --command pre-commit run --verbose --hook-stage commit --all-files --show-diff-on-failure
+
+---
+kind: pipeline
+type: docker
+name: build
+
+trigger:
+ event:
+ - push
+ - pull_request
+
+steps:
+ - name: Run tests and build
+ image: nixpkgs/nix-flakes:nixos-22.11
+ commands:
+ - nix develop --command go test -race ./...
+ - nix build