project-wide: nixdirfmt

This commit is contained in:
kat witch 2021-03-27 03:01:35 +00:00
parent 2eadee0323
commit 7fd895536a
No known key found for this signature in database
GPG key ID: 1B477797DCA5EC72
15 changed files with 232 additions and 203 deletions

View file

@ -24,8 +24,8 @@ in {
avidemux
gst_all_1.gstreamer.dev
gst_all_1.gstreamer
gst_all_1.gst-plugins-base
gst_all_1.gst-plugins-good
gst_all_1.gst-plugins-base
gst_all_1.gst-plugins-good
gst_all_1.gst-plugins-bad
gst_all_1.gst-plugins-ugly
vlc

View file

@ -1,7 +1,7 @@
{ config, lib, pkgs, ... }: {
config = lib.mkIf config.deploy.profile.gui {
networking = {
# networkmanager.enable = true;
# networkmanager.enable = true;
resolvconf.useLocalResolver = true;
networkmanager.dns = "none";
};

View file

@ -2,12 +2,8 @@
{
config = lib.mkIf config.deploy.profile.kat {
xdg.dataFile = {
"z/.keep".text = "";
};
home.packages = with pkgs; [
fzf fd
];
xdg.dataFile = { "z/.keep".text = ""; };
home.packages = with pkgs; [ fzf fd ];
programs.zsh = {
enable = true;
enableAutosuggestions = true;
@ -21,7 +17,7 @@
};
localVariables = {
_Z_DATA = "${config.xdg.dataHome}/z/data";
ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE="fg=3,bold";
ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE = "fg=3,bold";
ZSH_AUTOSUGGEST_USE_ASYNC = 1;
};
plugins = [

View file

@ -27,27 +27,52 @@
fi
'';
wayland.windowManager.sway = let
cfg = config.wayland.windowManager.sway.config;
bindsym = k: v: "bindsym ${k} ${v}";
bindWorkspace = key: workspace: {
"${cfg.modifier}+${key}" = "workspace number ${workspace}";
"${cfg.modifier}+shift+${key}" = "move container to workspace number ${workspace}";
};
workspaceBindings =
map (v: bindWorkspace v "${v}:${v}") ["1" "2" "3" "4" "5" "6" "7" "8" "9"]
++ [(bindWorkspace "0" "10:10")]
++ lib.imap1 (i: v: bindWorkspace v "${toString (10 + i)}:${v}") ["F1" "F2" "F3" "F4" "F5" "F6" "F7" "F8" "F9" "F10" "F11" "F12"];
workspaceBindings' =
map (lib.mapAttrsToList bindsym) workspaceBindings;
workspaceBindingsStr =
lib.concatStringsSep "\n" (lib.flatten workspaceBindings');
wayland.windowManager.sway = let
cfg = config.wayland.windowManager.sway.config;
bindsym = k: v: "bindsym ${k} ${v}";
bindWorkspace = key: workspace: {
"${cfg.modifier}+${key}" = "workspace number ${workspace}";
"${cfg.modifier}+shift+${key}" =
"move container to workspace number ${workspace}";
};
workspaceBindings = map (v: bindWorkspace v "${v}:${v}") [
"1"
"2"
"3"
"4"
"5"
"6"
"7"
"8"
"9"
] ++ [ (bindWorkspace "0" "10:10") ]
++ lib.imap1 (i: v: bindWorkspace v "${toString (10 + i)}:${v}") [
"F1"
"F2"
"F3"
"F4"
"F5"
"F6"
"F7"
"F8"
"F9"
"F10"
"F11"
"F12"
];
workspaceBindings' = map (lib.mapAttrsToList bindsym) workspaceBindings;
workspaceBindingsStr =
lib.concatStringsSep "\n" (lib.flatten workspaceBindings');
in {
enable = true;
config = let
dmenu =
"${pkgs.bemenu}/bin/bemenu --fn '${witch.style.font.name} ${witch.style.font.size}' --nb '${witch.style.base16.color0}' --nf '${witch.style.base16.color7}' --sb '${witch.style.base16.color1}' --sf '${witch.style.base16.color7}' -l 5 -m -1 -i";
lockCommand = "swaylock -i eDP-1:${../../../private/files/wallpapers/main.png} -i HDMI-A-1:${../../../private/files/wallpapers/main.png} -i DP-1:${../../../private/files/wallpapers/left.jpg} -i DVI-D-1:${../../../private/files/wallpapers/right.jpg} -s fill";
lockCommand = "swaylock -i eDP-1:${
../../../private/files/wallpapers/main.png
} -i HDMI-A-1:${../../../private/files/wallpapers/main.png} -i DP-1:${
../../../private/files/wallpapers/left.jpg
} -i DVI-D-1:${../../../private/files/wallpapers/right.jpg} -s fill";
in {
bars = [{ command = "${pkgs.waybar}/bin/waybar"; }];
@ -88,15 +113,9 @@
middle_emulation = "enabled";
click_method = "clickfinger";
};
"5824:1503:screenstub-tablet" = {
events = "disabled";
};
"5824:1503:screenstub-mouse" = {
events = "disabled";
};
"5824:1503:screenstub-kbd" = {
events = "disabled";
};
"5824:1503:screenstub-tablet" = { events = "disabled"; };
"5824:1503:screenstub-mouse" = { events = "disabled"; };
"5824:1503:screenstub-kbd" = { events = "disabled"; };
"*" = {
xkb_layout = "gb";
# xkb_variant = "nodeadkeys";
@ -143,7 +162,8 @@
"${cfg.modifier}+space" = "focus mode_toggle";
"${cfg.modifier}+Tab" = "workspace back_and_forth";
"${cfg.modifier}+Shift+Tab" = "${pkgs.i3gopher}/bin/i3gopher --focus-last";
"${cfg.modifier}+Shift+Tab" =
"${pkgs.i3gopher}/bin/i3gopher --focus-last";
"${cfg.modifier}+Ctrl+Left" = "workspace prev_on_output";
"${cfg.modifier}+Ctrl+Right" = "workspace next_on_output";
@ -167,8 +187,7 @@
"exec ${pkgs.kat-scrot}/bin/kat-scrot --notify upload area";
"${cfg.modifier}+Mod1+Print" =
"exec ${pkgs.kat-scrot}/bin/kat-scrot --notify upload window";
"Print" =
"exec ${pkgs.kat-scrot}/bin/kat-scrot --notify save screen";
"Print" = "exec ${pkgs.kat-scrot}/bin/kat-scrot --notify save screen";
"Shift+Print" =
"exec ${pkgs.kat-scrot}/bin/kat-scrot --notify save area";
"Mod1+Print" =

View file

@ -12,10 +12,22 @@
Type = "simple";
ExecStart = ''
${pkgs.swayidle}/bin/swayidle -w \
timeout 300 '${pkgs.swaylock}/bin/swaylock -f -i eDP-1:${../../../private/files/wallpapers/main.png} -i HDMI-A-1:${../../../private/files/wallpapers/main.png} -i DP-1:${../../../private/files/wallpapers/left.jpg} -i DVI-D-1:${../../../private/files/wallpapers/right.jpg}' \
timeout 300 '${pkgs.swaylock}/bin/swaylock -f -i eDP-1:${
../../../private/files/wallpapers/main.png
} -i HDMI-A-1:${
../../../private/files/wallpapers/main.png
} -i DP-1:${
../../../private/files/wallpapers/left.jpg
} -i DVI-D-1:${../../../private/files/wallpapers/right.jpg}' \
timeout 600 'swaymsg "output * dpms off"' \
resume 'swaymsg "output * dpms on"' \
before-sleep '${pkgs.swaylock}/bin/swaylock -f -i eDP-1:${../../../private/files/wallpapers/main.png} -i HDMI-A-1:${../../../private/files/wallpapers/main.png} -i DP-1:${../../../private/files/wallpapers/left.jpg} -i DVI-D-1:${../../../private/files/wallpapers/right.jpg}'
before-sleep '${pkgs.swaylock}/bin/swaylock -f -i eDP-1:${
../../../private/files/wallpapers/main.png
} -i HDMI-A-1:${
../../../private/files/wallpapers/main.png
} -i DP-1:${
../../../private/files/wallpapers/left.jpg
} -i DVI-D-1:${../../../private/files/wallpapers/right.jpg}'
'';
RestartSec = 3;
Restart = "always";

View file

@ -28,9 +28,7 @@
];
modules = {
"sway/workspaces" = {
format = "{name}";
};
"sway/workspaces" = { format = "{name}"; };
#"custom/weather" = {
# format = "{}";
# interval = 3600;
@ -43,11 +41,11 @@
on-click = "xdg-open 'https://google.com/search?q=weather'";
exec =
"${pkgs.kat-weather}/bin/kat-weather ${witch.secrets.profiles.sway.city} ${witch.secrets.profiles.sway.api_key}";
};
"custom/gpg-status" = {
format = "{}";
interval= 300;
exec = "${pkgs.kat-gpg-status}/bin/kat-gpg-status";
};
"custom/gpg-status" = {
format = "{}";
interval = 300;
exec = "${pkgs.kat-gpg-status}/bin/kat-gpg-status";
};
cpu = { format = " {usage}%"; };
#mpd = {