continuation of configuration and stuff

This commit is contained in:
Schrottkatze 2023-05-12 16:21:05 +02:00
parent fc1c0ffba1
commit 8f4207ff75
5 changed files with 69 additions and 30 deletions

View file

@ -7,5 +7,6 @@
./zsh.nix
./flatpak.nix
./firewall.nix
./helix.nix
];
}

View file

@ -54,6 +54,7 @@ in with lib; {
./mail.nix
./specific-hardware
./xmonad.nix
./i3
]).content;
options.jade.desktop = {
enable = mkEnableOption "Enable the i3 setup";

View file

@ -1,13 +1,24 @@
{ config, lib, pkgs, ... }:
with lib; {
let
searchwolf = import ../../../other/scripts/desktop/searchwolf.nix { inherit pkgs; };
desktop-ctl = import ../../../other/scripts/desktop/desktopctl.nix { inherit pkgs; };
pc-get = pkgs.writeShellScriptBin "pc-get.sh" (builtins.readFile ../../../other/scripts/desktop/permaclip/pc-get.sh);
pc-set = pkgs.writeShellScriptBin "pc-set.sh" (builtins.readFile ../../../other/scripts/desktop/permaclip/pc-set.sh);
em-record = pkgs.writeShellScriptBin "em-record.sh" (builtins.readFile ../../../other/scripts/desktop/macros/record.sh);
em-play = pkgs.writeShellScriptBin "em-play.sh" (builtins.readFile ../../../other/scripts/desktop/macros/play.sh);
em-play-loop = pkgs.writeShellScriptBin "em-play-loop.sh" (builtins.readFile ../../../other/scripts/desktop/macros/play-loop.sh);
ocr-screenshot = pkgs.writeShellScriptBin "ocr-screenshot.sh" (builtins.readFile ../../../other/scripts/desktop/ocr-screenshot.sh);
# rofi calculator copied from https://github.com/barbuk/menu-qalc
menu-qalc = pkgs.writeShellScriptBin "menu-qalc" (builtins.readFile ../../../other/scripts/desktop/menu-qalc.sh);
in with lib; {
options.jade.desktop.i3wm = {
enable = mkEnableOption "Enable i3wm";
};
config = mkIf cfg.enable {
config = mkIf config.jade.desktop.i3wm.enable {
services.xserver.windowManager.i3.enable = true;
home-manager.users.jade = { pkgs, ... }: {
xsession.windowManager.i3 = {
enable = false;
enable = true;
config = {
bars = [];
workspaceAutoBackAndForth = true;
@ -18,7 +29,7 @@ with lib; {
startup = [
# wallpaper
{
command = "feh --bg-fill ${../../other/wallpaper.jpg}";
command = "feh --bg-fill ${../../../other/wallpaper.jpg}";
always = true;
notification = false;
}
@ -90,10 +101,10 @@ with lib; {
"${mod}+t" = "exec ocr-screenshot.sh";
# rofi fuckery
"${mod}+d" = "exec --no-startup-id rofi -show drun -theme ${../../other/rofi-themes/applauncher.rasi}";
"${mod}+space" = "exec --no-startup-id rofi -show combi -combi-show window#run -modes combi -theme ${../../other/rofi-themes/applauncher.rasi}";
"${mod}+d" = "exec --no-startup-id rofi -show drun -theme ${../../../other/rofi-themes/applauncher.rasi}";
"${mod}+space" = "exec --no-startup-id rofi -show combi -combi-show window#run -modes combi -theme ${../../../other/rofi-themes/applauncher.rasi}";
"${mod}+i" = "exec --no-startup-id rofimoji -f alchemical_symbols anatolian_hieroglyphs emojis braille_patterns box_drawing chess_symbols emoticons geometric_shapes gothic greek_extended math mathematical_alphanumeric_symbols mathematical_operators miscellaneous_symbols miscellaneous_mathematical_symbols-a miscellaneous_mathematical_symbols-b miscellaneous_symbols_and_arrows miscellaneous_symbols_and_pictographs miscellaneous_technical modi modifier_tone_letters musical_symbols nerd_font number_forms shorthand_format_controls specials variation_selectors vertical_forms -a copy";
"${mod}+Shift+e" = "exec --no-startup-id rofi -show \"desktopctl\" -modes \"desktopctl:${desktop-ctl.outPath}/bin/desktopctl\" -theme ${../../other/rofi-themes/applauncher.rasi}";
"${mod}+Shift+e" = "exec --no-startup-id rofi -show \"desktopctl\" -modes \"desktopctl:${desktop-ctl.outPath}/bin/desktopctl\" -theme ${../../../other/rofi-themes/applauncher.rasi}";
"${mod}+m" = "exec --no-startup-id menu-qalc";
"${mod}+o" = "exec --no-startup-id rofi -show searchwolf -modes \"searchwolf:${searchwolf.outPath}/bin/searchwolf\"";

23
modules/helix.nix Normal file
View file

@ -0,0 +1,23 @@
{ config, lib, pkgs, ... }:
let cfg = config.jade.helix;
in with lib; {
options.jade.helix = {
enable = mkEnableOption "Enable helix";
};
config = mkIf cfg.enable {
home-manager.users.jade = { pkgs, ... }: {
programs.helix = {
enable = true;
settings = {
theme = "gruvbox";
editor = {
line-number = "relative";
lsp.display-messages = true;
};
};
};
};
};
}