diff options
author | Alan Pearce | 2024-05-12 21:29:56 +0200 |
---|---|---|
committer | Alan Pearce | 2024-05-12 21:34:57 +0200 |
commit | fe79b4509dd580542fa28186673826df603677bb (patch) | |
tree | df338a6e8d4a66855879ff4f2b6fe49aec251146 /internal/importer | |
parent | 2e56008ef28109f0895b5918e2d0caeb16a08d8a (diff) | |
download | searchix-fe79b4509dd580542fa28186673826df603677bb.tar.lz searchix-fe79b4509dd580542fa28186673826df603677bb.tar.zst searchix-fe79b4509dd580542fa28186673826df603677bb.zip |
feat: enable using channel URLs if unable to resolve via NIX_PATH
Diffstat (limited to 'internal/importer')
-rw-r--r-- | internal/importer/channel.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/internal/importer/channel.go b/internal/importer/channel.go index 97f0a27..70aa9de 100644 --- a/internal/importer/channel.go +++ b/internal/importer/channel.go @@ -45,6 +45,10 @@ func (i *ChannelImporter) FetchIfNeeded(parent context.Context) (bool, error) { dest, } + if i.Source.URL != "" { + args = append(args, "-I", fmt.Sprintf("%s=%s", i.Source.Channel, i.Source.URL)) + } + i.Logger.Debug("nix-build command", "args", args) cmd := exec.CommandContext(ctx, "nix-build", args...) out, err := cmd.Output() |