summary refs log tree commit diff stats
path: root/default.nix
diff options
context:
space:
mode:
authorAlan Pearce2024-06-29 17:36:24 +0200
committerAlan Pearce2024-06-29 17:36:24 +0200
commitcf942bc3c88e6d4482b6f99c1a31b5c13efe8e69 (patch)
tree247ab90505579d296d474c42bbe8317edb863ccd /default.nix
downloadgopkgs-cf942bc3c88e6d4482b6f99c1a31b5c13efe8e69.tar.lz
gopkgs-cf942bc3c88e6d4482b6f99c1a31b5c13efe8e69.tar.zst
gopkgs-cf942bc3c88e6d4482b6f99c1a31b5c13efe8e69.zip
initial commit
Diffstat (limited to 'default.nix')
-rw-r--r--default.nix28
1 files changed, 28 insertions, 0 deletions
diff --git a/default.nix b/default.nix
new file mode 100644
index 0000000..4c20919
--- /dev/null
+++ b/default.nix
@@ -0,0 +1,28 @@
+{ lib
+, buildGoModule
+, fetchFromGitHub
+}:
+
+buildGoModule rec {
+  pname = "vanity-imports";
+  version = "0.0.12";
+
+  src = fetchFromGitHub {
+    owner = "mlcdf";
+    repo = "vanity-imports";
+    rev = "v${version}";
+    hash = "sha256-4JoJL079hBkwWVvOTRbCM1WZhM7hPlKQ+HEAUr7fWP8=";
+  };
+
+  vendorHash = "sha256-w0LaXevbGm1xpHvKxxyubHCOVRN712UzLyOd+hVikKg=";
+
+  ldflags = [ "-s" "-w" ];
+
+  meta = with lib; {
+    description = "Use a custom domain in your Go import path";
+    homepage = "https://github.com/mlcdf/vanity-imports";
+    license = licenses.mit;
+    maintainers = with maintainers; [ alanpearce ];
+    mainProgram = "vanity-imports";
+  };
+}