about summary refs log tree commit diff
path: root/ops/kontemplate
diff options
context:
space:
mode:
Diffstat (limited to 'ops/kontemplate')
-rw-r--r--ops/kontemplate/README.md13
-rw-r--r--ops/kontemplate/context/context_test.go8
-rw-r--r--ops/kontemplate/release.nix22
-rw-r--r--ops/kontemplate/templater/templater_test.go2
4 files changed, 24 insertions, 21 deletions
diff --git a/ops/kontemplate/README.md b/ops/kontemplate/README.md
index 998e61a619..803a1c4f16 100644
--- a/ops/kontemplate/README.md
+++ b/ops/kontemplate/README.md
@@ -1,8 +1,8 @@
 Kontemplate - A simple Kubernetes templater
 ===========================================
 
-[Kontemplate][] is a simple CLI tool that can take sets of Kubernetes resource
-files with placeholders and insert values per environment.
+Kontemplate is a simple CLI tool that can take sets of Kubernetes resource files
+with placeholders and insert values per environment.
 
 This tool was made because in many cases all I want in terms of Kubernetes
 configuration is simple value interpolation per environment (i.e. Kubernetes
@@ -111,14 +111,14 @@ Releases are signed with the GPG key `DCF34CFAC1AC44B87E26333136EE34814F6D294A`.
 
 ### Building from source
 
-You can clone Kontemplate either by cloning the full
-[depot][https://git.tazj.in/] or by just cloning the kontemplate
+You can clone Kontemplate either by cloning the full TVL
+[depot][https://code.tvl.fyi] or by just cloning the kontemplate
 subtree like so:
 
-    git clone -b kontemplate https://git.tazj.in kontemplate
+    git clone https://code.tvl.fyi/depot.git:/ops/kontemplate.git
 
 The `go` tooling can be used as normal with this cloned repository. In
-a full clone of the dpeot, Nix can be used to build Kontemplate:
+a full clone of the depot, Nix can be used to build Kontemplate:
 
     nix-build -A ops.kontemplate
 
@@ -181,6 +181,5 @@ in the `LICENSE` file.
 
 Please follow the [code of conduct](CODE_OF_CONDUCT.md).
 
-[Kontemplate]: http://kontemplate.works
 [Helm]: https://helm.sh/
 [releases page]: https://github.com/tazjin/kontemplate/releases
diff --git a/ops/kontemplate/context/context_test.go b/ops/kontemplate/context/context_test.go
index 7ecd9d587d..471eb246cf 100644
--- a/ops/kontemplate/context/context_test.go
+++ b/ops/kontemplate/context/context_test.go
@@ -333,15 +333,15 @@ func TestSetInvalidVariablesFromArguments(t *testing.T) {
 // This test ensures that variables are merged in the correct order.
 // Please consult the test data in `testdata/merging`.
 func TestValueMergePrecedence(t *testing.T) {
-	cliVars:= []string{"cliVar=cliVar"}
+	cliVars := []string{"cliVar=cliVar"}
 	ctx, _ := LoadContext("testdata/merging/context.yaml", &cliVars)
 
 	expected := map[string]interface{}{
 		"defaultVar": "defaultVar",
-		"importVar": "importVar",
-		"globalVar": "globalVar",
+		"importVar":  "importVar",
+		"globalVar":  "globalVar",
 		"includeVar": "includeVar",
-		"cliVar": "cliVar",
+		"cliVar":     "cliVar",
 	}
 
 	result := ctx.ResourceSets[0].Values
diff --git a/ops/kontemplate/release.nix b/ops/kontemplate/release.nix
index 8a04109526..6a3dbd5efe 100644
--- a/ops/kontemplate/release.nix
+++ b/ops/kontemplate/release.nix
@@ -10,13 +10,17 @@
 # This file is the Nix derivation used to build release binaries for
 # several different architectures and operating systems.
 
-let pkgs = import ((import <nixpkgs> {}).fetchFromGitHub {
-  owner = "NixOS";
-  repo = "nixpkgs-channels";
-  rev = "541d9cce8af7a490fb9085305939569567cb58e6";
-  sha256 = "0jgz72hhzkd5vyq5v69vpljjlnf0lqaz7fh327bvb3cvmwbfxrja";
-}) {};
-in with pkgs; buildGoPackage rec {
+let
+  pkgs = import
+    ((import <nixpkgs> { }).fetchFromGitHub {
+      owner = "NixOS";
+      repo = "nixpkgs-channels";
+      rev = "541d9cce8af7a490fb9085305939569567cb58e6";
+      sha256 = "0jgz72hhzkd5vyq5v69vpljjlnf0lqaz7fh327bvb3cvmwbfxrja";
+    })
+    { };
+in
+with pkgs; buildGoPackage rec {
   name = "kontemplate-${version}";
   version = "canon";
   src = ./.;
@@ -29,8 +33,8 @@ in with pkgs; buildGoPackage rec {
   # reason for setting the 'allowGoReference' flag.
   dontStrip = true; # Linker configuration handles stripping
   allowGoReference = true;
-  CGO_ENABLED="0";
-  GOCACHE="off";
+  CGO_ENABLED = "0";
+  GOCACHE = "off";
 
   # Configure release builds via the "build-matrix" script:
   buildInputs = [ git ];
diff --git a/ops/kontemplate/templater/templater_test.go b/ops/kontemplate/templater/templater_test.go
index c20858c203..9d9fc8d1ff 100644
--- a/ops/kontemplate/templater/templater_test.go
+++ b/ops/kontemplate/templater/templater_test.go
@@ -185,7 +185,7 @@ func TestInsertTemplateFunction(t *testing.T) {
 	resourceSet := context.ResourceSet{
 		Path: "testdata",
 		Values: map[string]interface{}{
-			"testName":        "TestInsertTemplateFunction",
+			"testName": "TestInsertTemplateFunction",
 		},
 	}