extract_url: move to profiles/desktop

this won't work on servers anyway (no firefox)
main
Motiejus Jakštys 2024-04-15 16:53:23 +03:00 committed by Motiejus Jakštys
parent f1d6bc0fde
commit eba9fd966c
2 changed files with 14 additions and 11 deletions

View File

@ -257,6 +257,20 @@ in {
imports = [./plasma.nix];
xdg.configFile."awesome/rc.lua".source = ./rc.lua;
programs.tmux.extraConfig = let
cmd = "${pkgs.extract_url}/bin/extract_url";
cfg = pkgs.writeText "urlviewrc" "COMMAND firefox";
script = pkgs.writeShellApplication {
name = "urlview";
text = ''
tmux bind-key u capture-pane -J \\\; \
save-buffer "''${TMPDIR:-/tmp}/tmux-buffer" \\\; \
delete-buffer \\\; \
split-window -l 10 "${cmd} -c ${cfg} ''${TMPDIR:-/tmp}/tmux-buffer"
'';
};
in "run-shell ${script}/bin/urlview";
services = {
cbatticon.enable = true;
blueman-applet.enable = true;

View File

@ -205,17 +205,6 @@ in {
set-option -sg escape-time 10
set-option -g default-terminal "screen-256color"
set-option -sa terminal-features ',xterm-256color:RGB'
run-shell ${let
cmd = "${pkgs.extract_url}/bin/extract_url";
cfg = pkgs.writeText "urlviewrc" "COMMAND firefox";
in
pkgs.writeShellScript "urlview" ''
tmux bind-key u capture-pane -J \\\; \
save-buffer "''${TMPDIR:-/tmp}/tmux-buffer" \\\; \
delete-buffer \\\; \
split-window -l 10 "${cmd} -c ${cfg} ''${TMPDIR:-/tmp}/tmux-buffer"
''}
'';
};
}