tests: reduce number of downloads
This replaces some derivation outputs by simple strings rather than full Nix store paths. This removes the need to download the whole derivation when all we need is a static string.
This commit is contained in:
parent
a177d0282f
commit
797c77a00a
19 changed files with 259 additions and 67 deletions
|
|
@ -2,27 +2,27 @@
|
|||
|
||||
with lib;
|
||||
|
||||
let
|
||||
|
||||
substituteExpected = path: pkgs.substituteAll {
|
||||
src = path;
|
||||
|
||||
sensible_rtp = pkgs.tmuxPlugins.sensible.rtp;
|
||||
};
|
||||
|
||||
in
|
||||
|
||||
{
|
||||
config = {
|
||||
programs.tmux = {
|
||||
enable = true;
|
||||
disableConfirmationPrompt = true;
|
||||
};
|
||||
|
||||
|
||||
nixpkgs.overlays = [
|
||||
(self: super: {
|
||||
tmuxPlugins = super.tmuxPlugins // {
|
||||
sensible = super.tmuxPlugins.sensible // {
|
||||
rtp = "@sensible_rtp@";
|
||||
};
|
||||
};
|
||||
})
|
||||
];
|
||||
|
||||
nmt.script = ''
|
||||
assertFileExists home-files/.tmux.conf
|
||||
assertFileContent home-files/.tmux.conf \
|
||||
${substituteExpected ./disable-confirmation-prompt.conf}
|
||||
${./disable-confirmation-prompt.conf}
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -37,18 +37,18 @@ set -g history-limit 2000
|
|||
# tmuxplugin-logging
|
||||
# ---------------------
|
||||
|
||||
run-shell @tmuxplugin_logging@/share/tmux-plugins/logging/logging.tmux
|
||||
run-shell @tmuxplugin_logging_rtp@
|
||||
|
||||
|
||||
# tmuxplugin-prefix-highlight
|
||||
# ---------------------
|
||||
|
||||
run-shell @tmuxplugin_prefix_highlight@/share/tmux-plugins/prefix-highlight/prefix_highlight.tmux
|
||||
run-shell @tmuxplugin_prefix_highlight_rtp@
|
||||
|
||||
|
||||
# tmuxplugin-fzf-tmux-url
|
||||
# ---------------------
|
||||
|
||||
run-shell @tmuxplugin_fzf_tmux_url@/share/tmux-plugins/fzf-tmux-url/fzf-url.tmux
|
||||
run-shell @tmuxplugin_fzf_tmux_url_rtp@
|
||||
|
||||
# ============================================= #
|
||||
|
|
|
|||
|
|
@ -2,19 +2,6 @@
|
|||
|
||||
with lib;
|
||||
|
||||
let
|
||||
|
||||
substituteExpected = path: pkgs.substituteAll {
|
||||
src = path;
|
||||
|
||||
tmuxplugin_fzf_tmux_url = pkgs.tmuxPlugins.fzf-tmux-url;
|
||||
tmuxplugin_logging = pkgs.tmuxPlugins.logging;
|
||||
tmuxplugin_prefix_highlight = pkgs.tmuxPlugins.prefix-highlight;
|
||||
tmuxplugin_sensible_rtp = pkgs.tmuxPlugins.sensible.rtp;
|
||||
};
|
||||
|
||||
in
|
||||
|
||||
{
|
||||
config = {
|
||||
programs.tmux = {
|
||||
|
|
@ -32,10 +19,31 @@ in
|
|||
];
|
||||
};
|
||||
|
||||
nixpkgs.overlays = [
|
||||
(self: super: {
|
||||
tmuxPlugins = super.tmuxPlugins // {
|
||||
fzf-tmux-url = super.tmuxPlugins.fzf-tmux-url // {
|
||||
rtp = "@tmuxplugin_fzf_tmux_url_rtp@";
|
||||
};
|
||||
|
||||
logging = super.tmuxPlugins.logging // {
|
||||
rtp = "@tmuxplugin_logging_rtp@";
|
||||
};
|
||||
|
||||
prefix-highlight = super.tmuxPlugins.prefix-highlight // {
|
||||
rtp = "@tmuxplugin_prefix_highlight_rtp@";
|
||||
};
|
||||
|
||||
sensible = super.tmuxPlugins.sensible // {
|
||||
rtp = "@tmuxplugin_sensible_rtp@";
|
||||
};
|
||||
};
|
||||
})
|
||||
];
|
||||
|
||||
nmt.script = ''
|
||||
assertFileExists home-files/.tmux.conf
|
||||
assertFileContent home-files/.tmux.conf \
|
||||
${substituteExpected ./emacs-with-plugins.conf}
|
||||
assertFileContent home-files/.tmux.conf ${./emacs-with-plugins.conf}
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,15 +2,7 @@
|
|||
|
||||
with lib;
|
||||
|
||||
let
|
||||
|
||||
substituteExpected = path: pkgs.substituteAll {
|
||||
src = path;
|
||||
|
||||
sensible_rtp = pkgs.tmuxPlugins.sensible.rtp;
|
||||
};
|
||||
|
||||
in {
|
||||
{
|
||||
config = {
|
||||
programs.tmux = {
|
||||
aggressiveResize = true;
|
||||
|
|
@ -21,10 +13,19 @@ in {
|
|||
reverseSplit = true;
|
||||
};
|
||||
|
||||
nixpkgs.overlays = [
|
||||
(self: super: {
|
||||
tmuxPlugins = super.tmuxPlugins // {
|
||||
sensible = super.tmuxPlugins.sensible // {
|
||||
rtp = "@sensible_rtp@";
|
||||
};
|
||||
};
|
||||
})
|
||||
];
|
||||
|
||||
nmt.script = ''
|
||||
assertFileExists home-files/.tmux.conf
|
||||
assertFileContent home-files/.tmux.conf \
|
||||
${substituteExpected ./vi-all-true.conf}
|
||||
assertFileContent home-files/.tmux.conf ${./vi-all-true.conf}
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue