From ea52f5f7bd29e59cc03af7762a625a0286ba31cf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fabi=C3=A1n=20Montero?= Date: Thu, 24 Mar 2022 00:50:15 -0600 Subject: [PATCH] arregla script de teclado --- home/i3/default.nix | 6 +++--- home/i3/keyboard.nix | 9 +++++++++ home/i3/keyboard.sh | 3 --- home/steam/default.nix | 4 ++-- 4 files changed, 14 insertions(+), 8 deletions(-) create mode 100755 home/i3/keyboard.nix delete mode 100755 home/i3/keyboard.sh diff --git a/home/i3/default.nix b/home/i3/default.nix index ed66d06..2a66aa4 100644 --- a/home/i3/default.nix +++ b/home/i3/default.nix @@ -1,4 +1,4 @@ -{maim, xclip, ...}: '' +{maim, xclip, callPackage, ...}: '' # See https://i3wm.org/docs/userguide.html for a complete reference! @@ -22,7 +22,7 @@ exec_always --no-startup-id xrandr --output DisplayPort-0 --primary --mode 1920x exec_always --no-startup-id compton -b # exec_always --no-startup-id $HOME/.config/polybar/launch.sh -exec --no-startup-id ./keyboard.sh +exec --no-startup-id ${callPackage ./keyboard.nix {}}/bin/setkeyboard # exec --no-startup-id ./wallpaper.sh # exec --no-startup-id dunst -config .config/dunst/dunstrc @@ -183,7 +183,7 @@ gaps outer 10 gaps inner 10 # screenshot -bindsym $mod+Shift+s exec ${maim} -s -u | ${xclip} -selection clipboard -t image/png -i +bindsym $mod+Shift+s exec ${maim}/bin/maim -s -u | ${xclip}/bin/xclip -selection clipboard -t image/png -i # 2 screens workspace $ws1 output DisplayPort-0 diff --git a/home/i3/keyboard.nix b/home/i3/keyboard.nix new file mode 100755 index 0000000..e66bce7 --- /dev/null +++ b/home/i3/keyboard.nix @@ -0,0 +1,9 @@ +{setxkbmap, writeShellApplication, ...}: +writeShellApplication { + name = "setkeyboard"; + runtimeInputs = [ setxkbmap ]; + text = '' + setxkbmap -layout us,latam + setxkbmap -option 'grp:alt_shift_toggle' + ''; +} diff --git a/home/i3/keyboard.sh b/home/i3/keyboard.sh deleted file mode 100755 index 5a2a81e..0000000 --- a/home/i3/keyboard.sh +++ /dev/null @@ -1,3 +0,0 @@ -setxkbmap -layout us,latam -setxkbmap -option 'grp:alt_shift_toggle' -export EDITOR=nvim diff --git a/home/steam/default.nix b/home/steam/default.nix index a5415a0..04d3c0f 100644 --- a/home/steam/default.nix +++ b/home/steam/default.nix @@ -1,4 +1,4 @@ -{callPackage, lib, config, ...}: +{pkgs, lib, config, ...}: with lib; let cfg = config.programs.steam; in { @@ -7,7 +7,7 @@ in { }; config = mkIf cfg.enable { home.packages = [ - (callPackage ./package.nix {}) + (pkgs.callPackage ./package.nix {}) ]; }; }