diff --git a/modules/applications.nix b/modules/applications.nix index 9664fac..38ee5c7 100755 --- a/modules/applications.nix +++ b/modules/applications.nix @@ -7,8 +7,8 @@ with import ../support.nix { inherit lib config; }; { config = rec { defaultApplications = { term = { - cmd = "${pkgs.konsole}/bin/konsole"; - desktop = "konsole"; + cmd = "${pkgs.alacritty}/bin/alacritty"; + desktop = "alacritty"; }; editor = { cmd = toString (pkgs.writeTextFile { diff --git a/modules/applications/alacritty.nix b/modules/applications/alacritty.nix new file mode 100644 index 0000000..7b7b8d5 --- /dev/null +++ b/modules/applications/alacritty.nix @@ -0,0 +1,42 @@ +{ config, pkgs, lib, ... }: +let thm = config.themes.colors; +in { + home-manager.users.balsoft.programs.alacritty = { + enable = true; + settings = { + + font = rec { + normal.family = "IBM Plex Mono"; + size = 11; + bold = { style = "Bold"; }; + }; + + window.padding = { + x = 2; + y = 2; + }; + + shell.program = "${pkgs.zsh}/bin/zsh"; + + cursor.style = "Beam"; + + colors = { + primary = { + background = thm.bg; + foreground = thm.fg; + }; + cursor = { + text = thm.alt; + cursor = thm.fg; + }; + normal = { + black = thm.bg; + inherit (thm) red green yellow blue cyan; + magenta = thm.purple; + white = thm.fg; + }; + }; + }; + }; + +} diff --git a/modules/applications/konsole.nix b/modules/applications/konsole.nix deleted file mode 100644 index 9c22e5c..0000000 --- a/modules/applications/konsole.nix +++ /dev/null @@ -1,51 +0,0 @@ -{ pkgs, lib, config, ... }: -with (import ../../support.nix { inherit lib config; }); { - home-manager.users.balsoft.xdg.dataFile = { - "konsole/Default.profile".text = genIni { - Appearance.ColorScheme = "generated"; - "Cursor Options".CursorShape = 1; - General = { - Command = "zsh"; - Name = "Default"; - Parent = "FALLBACK/"; - }; - Scrolling = { - HistoryMode = 2; - ScrollBarPosition = 2; - }; - "Terminal Features".BlinkingCursorEnabled = true; - }; - "konsole/generated.colorscheme".text = genIni { - General = { - Description = "generated"; - Opacity = 1; - Wallpaper = ""; - }; - Background.Color = thmDec.bg; - BackgroundIntense.Color = thmDec.bg; - Foreground.Color = thmDec.fg; - Color0.Color = thmDec.dark; - Color0Intense.Color = thmDec.alt; - Color1.Color = thmDec.red; - Color2.Color = thmDec.green; - Color3.Color = thmDec.yellow; - Color4.Color = thmDec.blue; - Color5.Color = thmDec.purple; - Color6.Color = thmDec.cyan; - Color7.Color = thmDec.fg; - }; - }; - home-manager.users.balsoft.xdg.configFile."konsolerc.home".text = genIni { - "Desktop Entry".DefaultProfile = "Default.profile"; - KonsoleWindow = { - SaveGeometryOnExit = false; - ShowMenuBarByDefault = false; - UseSingleInstance = true; - }; - }; - home-manager.users.balsoft.home.activation.konsole = { - data = "$DRY_RUN_CMD cp -f ~/.config/konsolerc.home ~/.config/konsolerc"; - before = [ ]; - after = [ "linkGeneration" ]; - }; -} diff --git a/modules/applications/spectral.nix b/modules/applications/spectral.nix new file mode 100644 index 0000000..7d5fc8d --- /dev/null +++ b/modules/applications/spectral.nix @@ -0,0 +1,19 @@ +{ pkgs, config, lib, ... }: +with import ../../support.nix { inherit lib config; }; { + nixpkgs.overlays = [ + (self: super: { + spectral = super.spectral.overrideAttrs (oldAttrs: { + prePatch = '' + sed -i \ + -e s/#303030/${config.themes.colors.bg}/ \ + -e s/#009DC2/${config.themes.colors.alt}/ \ + -e s/#673AB7/${config.themes.colors.alt}/ \ + -e s/#4285F4/${config.themes.colors.gray}/ \ + -e s/#242424/${config.themes.colors.bg}/ \ + -e 's/"#ff2b00", "#ff5500", "#ff8000", "#ffaa00", "#ffd500", "#ffff00", "#d4ff00", "#aaff00", "#80ff00", "#55ff00", "#2bff00", "#00ff00", "#00ff2b", "#00ff55", "#00ff80", "#00ffaa", "#00ffd5", "#00ffff", "#00d4ff", "#00aaff", "#007fff", "#0055ff", "#002bff", "#0000ff", "#2a00ff", "#5500ff", "#7f00ff", "#aa00ff", "#d400ff", "#ff00ff", "#ff00d4", "#ff00aa", "#ff0080", "#ff0055", "#ff002b", "#ff0000"/"${config.themes.colors.alt}"/' \ + $(find . -name "*.qml") + ''; + }); + }) + ]; +} diff --git a/modules/default.nix b/modules/default.nix index a78dbae..bc23c17 100755 --- a/modules/default.nix +++ b/modules/default.nix @@ -3,7 +3,7 @@ device: imports = [ ./applications/packages.nix ./applications/emacs - ./applications/konsole.nix + ./applications/alacritty.nix ./applications/sylpheed.nix ./applications/weechat.nix ./applications/okular.nix diff --git a/modules/matrix-synapse.nix b/modules/matrix-synapse.nix index c741e64..b5f0fdd 100644 --- a/modules/matrix-synapse.nix +++ b/modules/matrix-synapse.nix @@ -55,28 +55,6 @@ } ''; }; - # systemd.services.mautrix-telegram = { - # description = "A bridge between telegram and matrix"; - # requires = [ "matrix-synapse.service" ]; - # path = with pkgs; [ coreutils mautrix-telegram ]; - # serviceConfig = { - # Restart = "always"; - # RestartSec = 1; - # }; - # wantedBy = [ "network-online.target" ]; - # script = '' - # mkdir -p /var/lib/mautrix-telegram - # cp -r ${pkgs.mautrix-telegram}/* /var/lib/mautrix-telegram - # cd /var/lib/mautrix-telegram - # alembic upgrade head || echo "update failed" - # sleep 5 - # cp ${ - # builtins.toFile "config.yaml" - # (builtins.toJSON config.secrets.matrix.mautrix-telegram.config) - # } ./config.yaml - # timeout 900 mautrix-telegram - # ''; - # }; services.mautrix-telegram = { enable = true; diff --git a/secret.nix b/secret.nix index 4c19105..f2de0ac 100644 Binary files a/secret.nix and b/secret.nix differ