[chore] Nixfmt and remove some unused vars

This commit is contained in:
Uttarayan Mondal
2024-03-19 11:13:57 +05:30
parent d912b2ae49
commit 1c50bbd91d
3 changed files with 38 additions and 46 deletions

View File

@@ -89,7 +89,6 @@
music = "${config.home.homeDirectory}/Nextcloud/Music"; music = "${config.home.homeDirectory}/Nextcloud/Music";
}; };
programs = { programs = {
direnv = { direnv = {
enable = true; enable = true;
@@ -174,8 +173,7 @@
enable = true; enable = true;
enableFishIntegration = true; enableFishIntegration = true;
enableNushellIntegration = true; enableNushellIntegration = true;
settings = settings = let flavour = "mocha"; # Replace with your preferred palette
let flavour = "mocha"; # Replace with your preferred palette
in { in {
# Check https://starship.rs/config/#prompt # Check https://starship.rs/config/#prompt
format = "$all$character"; format = "$all$character";
@@ -223,6 +221,7 @@
file = "Catppuccin Mocha.tmTheme"; file = "Catppuccin Mocha.tmTheme";
}; };
}; };
extraPackages = with pkgs.bat-extras; [ batdiff batman batgrep batwatch ];
}; };
rbw = { rbw = {
@@ -245,7 +244,6 @@
]; ];
}; };
home-manager = { enable = true; }; home-manager = { enable = true; };
}; };
@@ -253,8 +251,7 @@
home = { home = {
username = device.user; username = device.user;
homeDirectory = homeDirectory = if device.isMac then
if device.isMac then
lib.mkForce "/Users/${device.user}" lib.mkForce "/Users/${device.user}"
else else
lib.mkForce "/home/${device.user}"; lib.mkForce "/home/${device.user}";
@@ -269,11 +266,9 @@
EDITOR = "nvim"; EDITOR = "nvim";
SHELL = "${pkgs.nushellFull}/bin/nu"; SHELL = "${pkgs.nushellFull}/bin/nu";
CARGO_TARGET_DIR = "${config.xdg.cacheHome}/cargo/target"; CARGO_TARGET_DIR = "${config.xdg.cacheHome}/cargo/target";
BROWSER = "xdg-open"; BROWSER = if device.isMac then "open" else "xdg-open";
}; };
sessionPath = [ sessionPath = [ "${config.home.homeDirectory}/.cargo/bin" ];
"${config.home.homeDirectory}/.cargo/bin"
];
}; };
} }

View File

@@ -1,4 +1,4 @@
{ pkgs, device, ... }: { { pkgs, ... }: {
imports = [ ./yabai.nix ./skhd.nix ]; imports = [ ./yabai.nix ./skhd.nix ];
environment.systemPackages = with pkgs; [ nix neovim ]; environment.systemPackages = with pkgs; [ nix neovim ];
@@ -16,21 +16,20 @@
}; };
# security.pam.enableSudoTouchIdAuth = true; # security.pam.enableSudoTouchIdAuth = true;
system.patches = [ # system.patches = [
(pkgs.writeText "pam-reattach.patch" # (pkgs.writeText "pam-reattach.patch"
# diff # # diff
'' # ''
new file mode 100644 # new file mode 100644
index 0000000..e4293c0 # index 0000000..e4293c0
--- /dev/null # --- /dev/null
+++ b/etc/pam.d/sudo_local # +++ b/etc/pam.d/sudo_local
@@ -0,0 +1,3 @@ # @@ -0,0 +1,3 @@
+# sudo_local: local config file which survives system update and is included for sudo # +# sudo_local: local config file which survives system update and is included for sudo
+# uncomment following line to enable Touch ID for sudo # +# uncomment following line to enable Touch ID for sudo
+auth optional ${pkgs.pam-reattach}/lib/pam/pam_reattach.so # +auth optional ${pkgs.pam-reattach}/lib/pam/pam_reattach.so
'') # '')
# ];
];
programs.bash.enable = true; programs.bash.enable = true;
programs.zsh.enable = true; programs.zsh.enable = true;

View File

@@ -1,7 +1,5 @@
{ pkgs, config, lib, ... }: { pkgs, config, lib, ... }:
with lib; with lib;
let let
cfg = config.programs.goread; cfg = config.programs.goread;
# configDir = # configDir =