diff --git a/common/themes/default.nix b/common/themes/default.nix index ab0b092..156629b 100644 --- a/common/themes/default.nix +++ b/common/themes/default.nix @@ -13,7 +13,7 @@ let # {{{ Catppuccin mocha catppuccin-mocha = { stylix = { - image = ./wallpapers/breaking_phos.jpg; + image = ./wallpapers/purplecliffs.jpg; base16Scheme = base16 "catppuccin-mocha"; opacity = transparency 0.7; polarity = "dark"; @@ -84,7 +84,7 @@ let }; # Select your current theme here! - currentTheme = themes.catppuccin-macchiato; + currentTheme = themes.catppuccin-mocha; in { # We apply the current theme here. diff --git a/common/themes/wallpapers/purplecliffs.jpg b/common/themes/wallpapers/purplecliffs.jpg new file mode 100644 index 0000000..c1ff433 Binary files /dev/null and b/common/themes/wallpapers/purplecliffs.jpg differ diff --git a/home/calypso.nix b/home/calypso.nix index 412b74f..f747a64 100644 --- a/home/calypso.nix +++ b/home/calypso.nix @@ -8,6 +8,7 @@ ./features/desktop/obsidian.nix ./features/desktop/foot.nix ./features/desktop/steam.nix + ./features/desktop/edopro.nix ./features/desktop/firefox ./features/desktop/discord ./features/cli/productivity diff --git a/home/features/cli/git.nix b/home/features/cli/git.nix index 7aea677..7e1a076 100644 --- a/home/features/cli/git.nix +++ b/home/features/cli/git.nix @@ -55,7 +55,7 @@ # {{{ URL rewriting url."git@github.com:".insteadOf = [ # Normalize GitHub URLs to SSH to avoid authentication issues with HTTPS. - "https://github.com/" + # "https://github.com/" # Allows typing `git clone github:owner/repo`. "github:" diff --git a/home/features/desktop/discord/default.nix b/home/features/desktop/discord/default.nix index 6b2a73a..23620e6 100644 --- a/home/features/desktop/discord/default.nix +++ b/home/features/desktop/discord/default.nix @@ -1,36 +1,35 @@ { config, pkgs, ... }: let - themeMap = pkgs.callPackage (import ./themes.nix) { }; - - # REASON: newer discord versions don't work with the one in nixpkgs - discocss = pkgs.discocss.overrideAttrs (old: rec { - version = "unstable-2023-09-02"; - src = pkgs.fetchFromGitHub { - owner = "bddvlpr"; - repo = "discocss"; - rev = "37f1520bc90822b35e60baa9036df7a05f43fab8"; - sha256 = "1559mxmc0ppl4jxvdzszphysp1j31k2hm93qv7yz87xn9j0z2m04"; - }; - }); in +# themeMap = pkgs.callPackage (import ./themes.nix) { }; +# REASON: newer discord versions don't work with the one in nixpkgs +# discocss = pkgs.discocss.overrideAttrs (old: rec { +# version = "unstable-2023-09-02"; +# src = pkgs.fetchFromGitHub { +# owner = "bddvlpr"; +# repo = "discocss"; +# rev = "37f1520bc90822b35e60baa9036df7a05f43fab8"; +# sha256 = "1559mxmc0ppl4jxvdzszphysp1j31k2hm93qv7yz87xn9j0z2m04"; +# }; +# }); +# vencord = pkgs.discord.override { withVencord = true; }; { programs.discord = { enable = true; disableUpdateCheck = true; enableDevtools = true; + package = pkgs.vesktop; }; - home.packages = [ discocss ]; - xdg.configFile."discocss/custom.css".source = config.satellite.theming.get themeMap; + # xdg.configFile."discocss/custom.css".source = config.satellite.theming.get themeMap; # {{{ Storage # Clean cache older than 10 days - systemd.user.tmpfiles.rules = [ - "d ${config.xdg.configHome}/discord/Cache/Cache_Data - - - 10d" - ]; + systemd.user.tmpfiles.rules = [ "d ${config.xdg.configHome}/discord/Cache/Cache_Data - - - 10d" ]; satellite.persistence.at.state.apps.discord.directories = [ "${config.xdg.configHome}/discord" # Why tf does discord store it's state here 💀 + "${config.xdg.configHome}/vesktop" ]; # }}} } diff --git a/home/features/desktop/edopro.nix b/home/features/desktop/edopro.nix new file mode 100644 index 0000000..3a1cd5d --- /dev/null +++ b/home/features/desktop/edopro.nix @@ -0,0 +1,32 @@ +# EDOPro is a fanmade Yu-Gi-Oh! simulator. +# I am installing the game the traditional way, and +# adding a desktop entry which runs it via `steam-run`. +{ + config, + lib, + pkgs, + ... +}: +let + persistState = config.satellite.persistence.at.state.home; + installPath = "${persistState}/yugioh/.local/share/edopro"; + launchScript = pkgs.writeShellScript "start-edopro" '' + ${lib.getExe pkgs.steam-run} ${installPath}/EDOPro + ''; +in +{ + # This is a nix-ified version of the .desktop file EDOPro comes with. + xdg.desktopEntries.edopro = { + name = "EDOPro"; + type = "Application"; + comment = "The bleeding-edge automatic duel simulator"; + icon = "${installPath}/textures/AppIcon.png"; + categories = [ "Game" ]; + + settings.StartupWMClass = "EDOPro"; + settings.Path = installPath; + + terminal = false; + exec = builtins.toString launchScript; + }; +} diff --git a/home/features/desktop/firefox/default.nix b/home/features/desktop/firefox/default.nix index 0403497..7b2b727 100644 --- a/home/features/desktop/firefox/default.nix +++ b/home/features/desktop/firefox/default.nix @@ -177,6 +177,12 @@ in ]; }; + "NPM" = mkBasicSearchEngine { + url = "https://www.npmjs.com/search"; + param = "q"; + aliases = [ "@npm" ]; + }; + "Wikipedia" = mkBasicSearchEngine { url = "https://en.wikipedia.org/wiki/Special:Search"; param = "search"; diff --git a/home/features/neovim/default.nix b/home/features/neovim/default.nix index 21f9a8e..dd5a7d3 100644 --- a/home/features/neovim/default.nix +++ b/home/features/neovim/default.nix @@ -1526,6 +1526,7 @@ let # }}} # {{{ discord rich presence discord-rich-presence = { + enabled = false; package = "andweeb/presence.nvim"; main = "presence"; diff --git a/home/features/neovim/snippets/tex.miros b/home/features/neovim/snippets/tex.miros index a1f8d07..3c3907b 100644 --- a/home/features/neovim/snippets/tex.miros +++ b/home/features/neovim/snippets/tex.miros @@ -55,7 +55,7 @@ block text pattern ([Ll]et) name definition - snip @0 \$$1 = $2\$ @0 + snip @1 \$$1 = $2\$ @0 block auto string $ diff --git a/home/features/wayland/hyprland/hyprland.conf b/home/features/wayland/hyprland/hyprland.conf index 21c64ec..f5611a2 100644 --- a/home/features/wayland/hyprland/hyprland.conf +++ b/home/features/wayland/hyprland/hyprland.conf @@ -93,7 +93,7 @@ bind = $mod, L, exec, loginctl lock-session # Lock screen bind = $mod, P, exec, anyrun bind = $mod, B, exec, wlsunset-toggle # Toggle blue light filter thingy bind = $mod, V, exec, foot vimclip # Vim anywhere! -bind = $mod, W, exec, ~/projects/form-filler/type.sh +# bind = $mod, W, exec, ~/projects/form-filler/type.sh # Work with the special workspace bind = $mod, x, togglespecialworkspace, diff --git a/hosts/nixos/calypso/default.nix b/hosts/nixos/calypso/default.nix index 63631a5..ba44a0c 100644 --- a/hosts/nixos/calypso/default.nix +++ b/hosts/nixos/calypso/default.nix @@ -52,11 +52,15 @@ # {{{ A few ad-hoc programs programs.kdeconnect.enable = true; programs.firejail.enable = true; + programs.nix-ld.enable = true; # Useful for running non-nix executables # }}} # {{{ SSH keys users.users.pilot.openssh.authorizedKeys.keyFiles = [ ../tethys/keys/id_ed25519.pub ]; # }}} + programs.adb.enable = true; + users.users.pilot.extraGroups = [ "adbusers" ]; + satellite.pilot.name = "moon"; boot.loader.systemd-boot.enable = true; } diff --git a/hosts/nixos/common/optional/services/restic/default.nix b/hosts/nixos/common/optional/services/restic/default.nix index b421491..e2b06ee 100644 --- a/hosts/nixos/common/optional/services/restic/default.nix +++ b/hosts/nixos/common/optional/services/restic/default.nix @@ -16,7 +16,7 @@ let initialize = true; repository = "sftp:${backupUrl}:backups/${name}"; passwordFile = config.sops.secrets.backup_password.path; - extraOptions = [ "sftp.args='-i ${config.users.users.pilot.home}/.ssh/id_ed25519'" ]; + extraOptions = [ "sftp.args='-i /persist/state/etc/ssh/ssh_host_ed25519_key'" ]; exclude = [ ".direnv" # Direnv @@ -35,6 +35,8 @@ in # {{{ Data data = createBackup { name = "data"; + + # Kept for at most 1 year pruneOpts = [ "--keep-daily 7" "--keep-weekly 4" @@ -55,6 +57,8 @@ in # {{{ State state = createBackup { name = "state"; + + # Kept for at most 1 month pruneOpts = [ "--keep-daily 3" "--keep-weekly 1" @@ -65,11 +69,20 @@ in paths = [ "/persist/state" ]; exclude = let - home = "/persist/state/${config.users.users.pilot.home}"; + home = "/persist/state${config.users.users.pilot.home}"; in [ - "${home}/discord" # There's lots of cache stored in here - "${home}/steam" # Games can be quite big + "/persist/state/var/log" + "${home}/discord" + "${home}/element" + "${home}/firefox" + "${home}/lutris" + "${home}/qmk" + "${home}/signal" + "${home}/spotify" + "${home}/steam" + "${home}/whatsapp" + "${home}/wine" ]; }; # }}} diff --git a/hosts/nixos/tethys/keys/id_ed25519.pub b/hosts/nixos/tethys/keys/id_ed25519.pub index fcb8d99..5f0506a 100644 --- a/hosts/nixos/tethys/keys/id_ed25519.pub +++ b/hosts/nixos/tethys/keys/id_ed25519.pub @@ -1 +1 @@ -ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINmdOiG0elKHvJ5yoUMd8I5qQdygvjdq45bxv65K230G tethys +ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINmdOiG0elKHvJ5yoUMd8I5qQdygvjdq45bxv65K230G adrielus@tethys diff --git a/modules/common/korora-neovim.nix b/modules/common/korora-neovim.nix index c1557cf..75bd7da 100644 --- a/modules/common/korora-neovim.nix +++ b/modules/common/korora-neovim.nix @@ -86,6 +86,7 @@ let ); nix = k.listOf types.derivation; } [ ]; + enabled = k.bool; cond = types.oneOrMany types.luaLiteral; init = types.luaEagerOrLazy ( k.union [ diff --git a/scripts/setup-rsync-ssh.sh b/scripts/setup-rsync-ssh.sh index 470da9c..8a59a41 100755 --- a/scripts/setup-rsync-ssh.sh +++ b/scripts/setup-rsync-ssh.sh @@ -3,7 +3,7 @@ tmpfile=$(mktemp) # Concat files -cat hosts/nixos/*/keys/id_*.pub > $tmpfile +cat hosts/nixos/*/keys/*.pub > $tmpfile # Copy concat result scp $tmpfile $(cat hosts/nixos/common/optional/services/restic/url.txt):.ssh/authorized_keys