I took the OP packages/default.nix and fixed the obvious syntax errors, then I tried to build with the go-template-lsp.nix from the replied to post.
I again fixed issues as I went, never seeing the error you mentioned.
What I did though was using nix-build -A go-template-lsp.lsp, as that is the attribute path you have choosen for whatever reason.
I was able to get to the point that the deps should be fetched, though that fails, as the repo in question is broken, as it doesn’t commit a go.sum (lock file for go modules), this is required.
The changes I made so far to get where I am now:
diff --git a/default.nix b/default.nix
index 2cd0113f92..74a95b9996 100644
--- a/default.nix
+++ b/default.nix
@@ -1,4 +1,4 @@
let
- nixpkgs = fetchTarball “https://github.com/NixOS/nixpkgs/tarball/nixos-25.11”;
- pkgs = import nixpkgs {config = { };overlays = ;};
+ nixpkgs = fetchTarball "https://github.com/NixOS/nixpkgs/tarball/nixos-25.11";
+ pkgs = import nixpkgs {config = { };overlays = [];};
in { go-template-lsp = pkgs.callPackage ./go-template-lsp.nix { }; }
diff --git a/go-template-lsp.nix b/go-template-lsp.nix
index b1bd945ebd..7f22f6be90 100644
--- a/go-template-lsp.nix
+++ b/go-template-lsp.nix
@@ -1,15 +1,17 @@
-{ buildGoModule, fetchFromGithub }: {
+{ buildGoModule, fetchFromGitHub }: {
lsp = buildGoModule (finalAttrs: {
pname = "go-template-lsp.nix";
version = "0.3.4";
- src = fetchFromGithub {
+ src = fetchFromGitHub {
owner = "yayolande";
repo = "go-template-lsp";
- version = "v${finalAttrs.version}";
- hash = "sha256-18jcyknq9yhbcilk0gbshvbiszyffbjhxn2g6gcrrmnbykns7gj4";
+ tag = "v${finalAttrs.version}";
+ hash = "sha256-ArfnJzPS4I4BsqOSlosuJNQfpU5V/FeTzSQyC/Xnfro=";
};
+ vendorHash = "";
+
meta = {
description =
"Language server to be used with Hugo static page generator";