about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorAlan Pearce2025-03-11 19:51:17 +0100
committerAlan Pearce2025-03-11 19:51:17 +0100
commit5cdcac9f7a09b7cfd2fa699550092065b4d9a6c4 (patch)
tree4082e348d10be617267990f1e5bf0513bc0ee940
parent2a7480c9f1052556a5a28ba14eb7497bc43cbc34 (diff)
downloadsearchix-5cdcac9f7a09b7cfd2fa699550092065b4d9a6c4.tar.lz
searchix-5cdcac9f7a09b7cfd2fa699550092065b4d9a6c4.tar.zst
searchix-5cdcac9f7a09b7cfd2fa699550092065b4d9a6c4.zip
fix: nixos import fails with default settings
Fixes: https://todo.sr.ht/~alanpearce/searchix/14
-rw-r--r--defaults.toml4
-rw-r--r--internal/config/default.go4
2 files changed, 4 insertions, 4 deletions
diff --git a/defaults.toml b/defaults.toml
index 5b417b1..be96d3a 100644
--- a/defaults.toml
+++ b/defaults.toml
@@ -88,7 +88,7 @@ Channel = 'darwin'
 # (Fetcher=channel) Remote URL for channel, (Fetcher=download) Path containing files named 'revision' and 'options.json'.
 URL = 'https://github.com/LnL7/nix-darwin/archive/master.tar.gz'
 # (Fetcher=channel) Nix attribute name (i.e. nix-build -A) that builds an {options,packages}.json
-Attribute = 'options'
+Attribute = 'docs.optionsJSON'
 # (Fetcher=channel) Sub-path of imported channel which contains the attribute above, e.g. release.nix
 ImportPath = 'release.nix'
 # Abort import if it takes longer than this.
@@ -168,7 +168,7 @@ Channel = 'nixpkgs'
 # (Fetcher=channel) Remote URL for channel, (Fetcher=download) Path containing files named 'revision' and 'options.json'.
 URL = 'https://channels.nixos.org/nixos-unstable/nixexprs.tar.xz'
 # (Fetcher=channel) Nix attribute name (i.e. nix-build -A) that builds an {options,packages}.json
-Attribute = 'docs.optionsJSON'
+Attribute = 'options'
 # (Fetcher=channel) Sub-path of imported channel which contains the attribute above, e.g. release.nix
 ImportPath = 'nixos/release.nix'
 # Abort import if it takes longer than this.
diff --git a/internal/config/default.go b/internal/config/default.go
index 752d4e3..9208a33 100644
--- a/internal/config/default.go
+++ b/internal/config/default.go
@@ -62,7 +62,7 @@ var DefaultConfig = Config{
 				Channel:    "nixpkgs",
 				URL:        "https://channels.nixos.org/nixos-unstable/nixexprs.tar.xz",
 				ImportPath: "nixos/release.nix",
-				Attribute:  "docs.optionsJSON",
+				Attribute:  "options",
 				OutputPath: "share/doc/nixos",
 				Timeout:    Duration{5 * time.Minute},
 				Repo:       nixpkgs,
@@ -77,7 +77,7 @@ var DefaultConfig = Config{
 				Channel:    "darwin",
 				URL:        "https://github.com/LnL7/nix-darwin/archive/master.tar.gz",
 				ImportPath: "release.nix",
-				Attribute:  "options",
+				Attribute:  "docs.optionsJSON",
 				OutputPath: "share/doc/darwin",
 				Timeout:    Duration{5 * time.Minute},
 				Repo: Repository{