aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Garrelou <simon.garrelou@airbus.com>2023-12-12 15:03:34 +0100
committerSimon Garrelou <simon.garrelou@airbus.com>2023-12-12 15:03:34 +0100
commit92d411a74def7d46b7c7e8af22e0664b829b840d (patch)
tree333de71a8291d8d75af7c1e3fd3453dabdeff43c
parent44ce82f234722677bb06f74bb98e42c320857f65 (diff)
downloadnix-tools-92d411a74def7d46b7c7e8af22e0664b829b840d.tar.gz
nix-tools-92d411a74def7d46b7c7e8af22e0664b829b840d.zip
Move nix-search cache to ~/.cache
-rw-r--r--README.md2
-rw-r--r--cmd/nix-search/main.go2
2 files changed, 2 insertions, 2 deletions
diff --git a/README.md b/README.md
index 1992d20..73a83e5 100644
--- a/README.md
+++ b/README.md
@@ -13,7 +13,7 @@ $ go build ./cmd/nixos-search
13 13
14## nix-search 14## nix-search
15 15
16`nix-search` searches for Nix derivations in your local `nixpkgs` repository. The package list is compiled using `nix-env`, and cached in `~/.nix_search.cache.gz`. 16`nix-search` searches for Nix derivations in your local `nixpkgs` repository. The package list is compiled using `nix-env`, and cached in `~/cache/nix_search.gz`.
17 17
18Creating the cache is done with the command: 18Creating the cache is done with the command:
19 19
diff --git a/cmd/nix-search/main.go b/cmd/nix-search/main.go
index 039606d..8736c3a 100644
--- a/cmd/nix-search/main.go
+++ b/cmd/nix-search/main.go
@@ -9,7 +9,7 @@ import (
9 nix_search "git.sixfoisneuf.fr/nix-tools/nix" 9 nix_search "git.sixfoisneuf.fr/nix-tools/nix"
10) 10)
11 11
12var CACHE_FILE = os.ExpandEnv("$HOME/.nix_search.cache.gz") 12var CACHE_FILE = os.ExpandEnv("$HOME/.cache/nix_search.gz")
13 13
14func usage() { 14func usage() {
15 fmt.Fprintf(os.Stderr, "Usage: %s SEARCH_TERM ...\n\nParameters:\n", os.Args[0]) 15 fmt.Fprintf(os.Stderr, "Usage: %s SEARCH_TERM ...\n\nParameters:\n", os.Args[0])