Compare commits

...

5 commits

Author SHA1 Message Date
9b36d4bd8e
🧑 feat(nix): Auto gc; disable git tree dirty warning 2024-11-03 21:34:46 -08:00
7ff99d5206
feat(bun): Install bun 2024-11-03 21:32:44 -08:00
0200116b6a
🐛 fix(gtk): Make GTK2 respect XDG 2024-11-03 20:18:33 -08:00
83f4dbff57
feat(modules): Add iconTheme module
Allows setting iconTheme globally.
2024-11-03 20:15:06 -08:00
bfd3d6c289
🐛 fix(tmux): Stop capturing pane contents
It wasn't working.
2024-11-03 19:14:36 -08:00
8 changed files with 93 additions and 21 deletions

View file

@ -48,6 +48,7 @@
modules = [ modules = [
inputs.rose-pine.homeManagerModules.rose-pine inputs.rose-pine.homeManagerModules.rose-pine
./modules/home/shellAbbrs.nix ./modules/home/shellAbbrs.nix
./modules/home/iconTheme.nix
./home ./home
]; ];
}; };

View file

@ -6,6 +6,11 @@
rose-pine.pointerCursor.enable = true; rose-pine.pointerCursor.enable = true;
home.iconTheme = {
package = pkgs.kora-icon-theme;
name = "kora";
};
fonts.fontconfig.defaultFonts.monospace = [ "Maple Mono NF" ]; fonts.fontconfig.defaultFonts.monospace = [ "Maple Mono NF" ];
imports = [ imports = [

View file

@ -1,13 +1,10 @@
{ pkgs, ... }: { config, ... }:
{ {
gtk = { gtk = {
enable = true; enable = true;
rose-pine.enable = true; rose-pine.enable = true;
iconTheme = { gtk2.configLocation = "${config.xdg.configHome}/gtk-2.0/gtkrc";
package = pkgs.kora-icon-theme;
name = "kora";
};
}; };
} }

View file

@ -19,12 +19,22 @@
# Tell nix what version it is. # Tell nix what version it is.
nix.package = pkgs.nix; nix.package = pkgs.nix;
nix = {
# Enable flakes. # Enable flakes.
nix.settings.experimental-features = [ settings.experimental-features = [
"nix-command" "nix-command"
"flakes" "flakes"
]; ];
# Disable that annoying "git tree is dirty" warning.
extraOptions = ''
warn-dirty = false
'';
# Garbage collection.
gc.automatic = true;
};
xdg.configFile."nixpkgs/config.nix".text = # nix xdg.configFile."nixpkgs/config.nix".text = # nix
'' ''
{ {

10
home/programs/bun.nix Normal file
View file

@ -0,0 +1,10 @@
{ ... }:
{
programs.bun = {
enable = true;
settings = {
telemetry = false;
};
};
}

View file

@ -37,10 +37,6 @@
plugins = with pkgs.tmuxPlugins; [ plugins = with pkgs.tmuxPlugins; [
{ {
plugin = resurrect; plugin = resurrect;
extraConfig = # tmux
''
set -g @resurrect-capture-pane-contents 'on'
'';
} }
{ {

View file

@ -1,5 +1,4 @@
{ {
pkgs,
config, config,
lib, lib,
... ...
@ -12,12 +11,6 @@
# drop-in weirdness. # drop-in weirdness.
rose-pine.enable = false; rose-pine.enable = false;
# TODO: Set this globally and import it.
iconTheme = {
package = pkgs.kora-icon-theme;
name = "Kora";
};
settings = lib.mkMerge [ settings = lib.mkMerge [
### Rose Pine ### ### Rose Pine ###
# TODO: Set this conditionally based on current theme. # TODO: Set this conditionally based on current theme.

View file

@ -0,0 +1,60 @@
{ lib, config, ... }:
with lib;
let
# https://github.com/nix-community/home-manager/blob/master/modules/misc/gtk.nix
iconThemeType = types.submodule {
options = {
package = mkOption {
type = types.nullOr types.package;
default = null;
example = literalExpression "pkgs.gnome.adwaita-icon-theme";
description = ''
Package providing the icon theme. This package will be installed
to your profile. If `null` then the theme
is assumed to already be available in your profile.
'';
};
name = mkOption {
type = types.str;
example = "Adwaita";
description = "The name of the icon theme within the package.";
};
};
};
in
{
options = {
home = {
iconTheme = mkOption {
type = types.nullOr iconThemeType;
default = null;
description = ''
The icon theme to use.
'';
};
};
};
config =
let
cfg = config.home.iconTheme;
in
{
gtk = mkIf config.gtk.enable (mkDefault {
iconTheme = {
name = cfg.name;
package = cfg.package;
};
});
services.dunst = mkIf config.services.dunst.enable (mkDefault {
iconTheme = {
name = cfg.name;
package = cfg.package;
};
});
};
}