all repos — searchix @ bdb5a54c661407c39668096074a1f4a57898eb77

Search engine for NixOS, nix-darwin, home-manager and NUR users

feat: store fetched files in data directory

Alan Pearce
commit

bdb5a54c661407c39668096074a1f4a57898eb77

parent

3e928369c3af69d0ef24a2f5d20c938689b15aa1

1 file changed, 6 insertions(+), 0 deletions(-)

changed files
M internal/config/structs.gointernal/config/structs.go
@@ -5,6 +5,7 @@ // keep config structs here so that lll ignores the long lines (go doesn't support multi-line struct tags)
import ( "fmt" + "path/filepath" "strings" "github.com/creasty/defaults"
@@ -83,3 +84,8 @@ if defaults.CanUpdate(source.Name) {
source.Name = strings.ToTitle(source.Key[0:1]) + source.Key[1:] } } + +func (source *Source) JoinPath(name string) string { + //nolint:forbidigo // is not absolute + return filepath.Join("sources", source.Key, name) +}