Add quotes to the preview command to prevent the shell from interpreting options with `<name>` as writing the output of the command name to a file with the name of the remainder of the option name.
22 lines
608 B
Nix
22 lines
608 B
Nix
{ lib, pkgs, ... }:
|
|
{
|
|
programs.television.enable = true;
|
|
|
|
programs.nix-search-tv.enable = true;
|
|
|
|
nmt.script = ''
|
|
assertFileExists home-files/.config/television/cable/nix-search-tv.toml
|
|
assertFileContent home-files/.config/television/cable/nix-search-tv.toml \
|
|
${pkgs.writeText "settings-expected" ''
|
|
[metadata]
|
|
description = "Search nix options and packages"
|
|
name = "nix-search-tv"
|
|
|
|
[preview]
|
|
command = "${lib.getExe pkgs.nix-search-tv} preview \"{}\""
|
|
|
|
[source]
|
|
command = "${lib.getExe pkgs.nix-search-tv} print"
|
|
''}
|
|
'';
|
|
}
|