finally, nix-rice
This commit is contained in:
parent
70b8efe0cb
commit
8c093b6658
6 changed files with 203 additions and 218 deletions
11
flake.nix
11
flake.nix
|
@ -38,7 +38,7 @@
|
|||
|
||||
hyprland.url = "github:hyprwm/Hyprland";
|
||||
|
||||
# declarative-cachix.url = "github:jonascarpay/declarative-cachix";
|
||||
# declarative-cachix.url = "github:jonascarpay/declarative-cachix";
|
||||
nix-rice.url = "github:bertof/nix-rice";
|
||||
};
|
||||
|
||||
|
@ -87,8 +87,8 @@
|
|||
home-manager.nixosModules.home-manager
|
||||
{
|
||||
home-manager.useGlobalPkgs = true;
|
||||
home-manager.extraSpecialArgs = { inherit inputs outputs; };
|
||||
home-manager.users.bolt.imports = [ ./home/bolt.nix ];
|
||||
home-manager.extraSpecialArgs = {inherit inputs outputs;};
|
||||
home-manager.users.bolt.imports = [./home/bolt.nix];
|
||||
}
|
||||
];
|
||||
};
|
||||
|
@ -103,12 +103,11 @@
|
|||
home-manager.nixosModules.home-manager
|
||||
{
|
||||
home-manager.useGlobalPkgs = true;
|
||||
home-manager.extraSpecialArgs = { inherit inputs outputs; };
|
||||
home-manager.users.plank.imports = [ ./home/plank.nix ];
|
||||
home-manager.extraSpecialArgs = {inherit inputs outputs;};
|
||||
home-manager.users.plank.imports = [./home/plank.nix];
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
};
|
||||
}
|
||||
|
|
|
@ -25,9 +25,9 @@ $white_a: #WHTA;
|
|||
$fg: #FG;
|
||||
$bg: #BG;
|
||||
|
||||
$border: $black;
|
||||
$shadow: $black;
|
||||
$border: $black_a;
|
||||
$shadow: $black_a;
|
||||
$base: $bg;
|
||||
$bg1: $black;
|
||||
$text: $fg;
|
||||
$outline: $black;
|
||||
$outline: $black_a;
|
||||
|
|
|
@ -9,12 +9,12 @@
|
|||
@define-color noti-bg-hover #NOTIBGHOVER;
|
||||
@define-color noti-bg-focus #NOTIBGFOCUS;
|
||||
@define-color noti-close-bg #NOTIBGCLOSE;
|
||||
@define-color noti-close-bg-hover #NOTIBGHOVERCLOSE;
|
||||
@define-color noti-close-bg-hover #NOTIBGHVERCLOSE;
|
||||
|
||||
@define-color bg-selected #BGSELECTED;
|
||||
|
||||
* {
|
||||
font-family: "FONT", sans-serif;
|
||||
font-family: "#FONT", sans-serif;
|
||||
}
|
||||
|
||||
.notification-row {
|
||||
|
|
257
home/home.nix
257
home/home.nix
|
@ -57,18 +57,12 @@ in {
|
|||
|
||||
mpv
|
||||
|
||||
meslo-lgs-nf
|
||||
|
||||
# libsForQt5.qtstyleplugin-kvantum
|
||||
|
||||
gtk-engine-murrine
|
||||
material-icons
|
||||
material-design-icons
|
||||
pkgs.rice.fonts.sans.package
|
||||
pkgs.rice.fonts.serif.package
|
||||
pkgs.rice.fonts.monospace.package
|
||||
pkgs.rice.fonts.emoji.package
|
||||
];
|
||||
] ++ pkgs.rice.fonts.pkgs;
|
||||
|
||||
fonts.fontconfig.enable = true;
|
||||
|
||||
services.syncthing = {
|
||||
enable = true;
|
||||
|
@ -83,67 +77,73 @@ in {
|
|||
hidpi = false;
|
||||
};
|
||||
recommendedEnvironment = true;
|
||||
extraConfig = with pkgs.rice; (builtins.replaceStrings
|
||||
["#BGIMAGE"
|
||||
"#GTKTHEME"
|
||||
"#FONT"
|
||||
"#ICONTHEME"
|
||||
"#ACTIVEBORDER"
|
||||
"#BORDER"
|
||||
"#THICK"
|
||||
"#ROUND"]
|
||||
["${bg.image}"
|
||||
gtk.name
|
||||
fonts.sans.name
|
||||
icons.name
|
||||
palette-shex.util.fg
|
||||
palette-shex.util.bg
|
||||
(builtins.toString borders.thickness)
|
||||
(builtins.toString borders.rounding)]
|
||||
extraConfig = with pkgs.rice; (builtins.replaceStrings
|
||||
[
|
||||
"#BGIMAGE"
|
||||
"#GTKTHEME"
|
||||
"#FONT"
|
||||
"#ICONTHEME"
|
||||
"#ACTIVEBORDER"
|
||||
"#BORDER"
|
||||
"#THICK"
|
||||
"#ROUND"
|
||||
]
|
||||
[
|
||||
"${bg.image}"
|
||||
gtk-theme.name
|
||||
fonts.sans.name
|
||||
icons.name
|
||||
palette-shex.bright.yellow
|
||||
palette-shex.bright.black
|
||||
(builtins.toString borders.thickness)
|
||||
(builtins.toString borders.rounding)
|
||||
]
|
||||
(builtins.readFile dots/hyprland/hyprland.conf));
|
||||
};
|
||||
|
||||
|
||||
programs.eww-hyprland = {
|
||||
enable = true;
|
||||
colors = with palette-hex;
|
||||
(builtins.replaceStrings
|
||||
["#BLACK"
|
||||
"#BLCKA"
|
||||
"#RED"
|
||||
"#RDA"
|
||||
"#GREEN"
|
||||
"#GRNA"
|
||||
"#YELLOW"
|
||||
"#YLWA"
|
||||
"#BLUE"
|
||||
"#BLUA"
|
||||
"#MAGENTA"
|
||||
"#MGNA"
|
||||
"#CYAN"
|
||||
"#CYNA"
|
||||
"#WHITE"
|
||||
"#WHTA"
|
||||
"#FG"
|
||||
"#BG" ]
|
||||
[normal.black
|
||||
bright.black
|
||||
normal.red
|
||||
bright.red
|
||||
normal.green
|
||||
bright.green
|
||||
normal.yellow
|
||||
bright.yellow
|
||||
normal.blue
|
||||
bright.blue
|
||||
normal.magenta
|
||||
bright.magenta
|
||||
normal.cyan
|
||||
bright.cyan
|
||||
normal.white
|
||||
bright.white
|
||||
util.fg
|
||||
util.bg] (builtins.readFile dots/eww/colors.scss));
|
||||
colors = with palette-hex; (builtins.replaceStrings
|
||||
[
|
||||
"#BLACK"
|
||||
"#BLCKA"
|
||||
"#RED"
|
||||
"#RDA"
|
||||
"#GREEN"
|
||||
"#GRNA"
|
||||
"#YELLOW"
|
||||
"#YLWA"
|
||||
"#BLUE"
|
||||
"#BLUA"
|
||||
"#MAGENTA"
|
||||
"#MGNA"
|
||||
"#CYAN"
|
||||
"#CYNA"
|
||||
"#WHITE"
|
||||
"#WHTA"
|
||||
"#FG"
|
||||
"#BG"
|
||||
]
|
||||
[
|
||||
normal.black
|
||||
bright.black
|
||||
normal.red
|
||||
bright.red
|
||||
normal.green
|
||||
bright.green
|
||||
normal.yellow
|
||||
bright.yellow
|
||||
normal.blue
|
||||
bright.blue
|
||||
normal.magenta
|
||||
bright.magenta
|
||||
normal.cyan
|
||||
bright.cyan
|
||||
normal.white
|
||||
bright.white
|
||||
util.fg
|
||||
util.bg
|
||||
] (builtins.readFile dots/eww/colors.scss));
|
||||
};
|
||||
|
||||
systemd.user.startServices = "sd-switch";
|
||||
|
@ -162,27 +162,27 @@ in {
|
|||
|
||||
xdg.enable = true;
|
||||
xresources.properties = with palette-hex; {
|
||||
"*.foreground" = util.fg;
|
||||
"*.background" = util.bg;
|
||||
"*.cursorColor" = util.cursor;
|
||||
"*.selection_foreground" = util.fg_sel;
|
||||
"*.selection_background" = util.bg_sel;
|
||||
"*.color0" = normal.black;
|
||||
"*.color1" = normal.red;
|
||||
"*.color2" = normal.green;
|
||||
"*.color3" = normal.yellow;
|
||||
"*.color4" = normal.blue;
|
||||
"*.color5" = normal.magenta;
|
||||
"*.color6" = normal.cyan;
|
||||
"*.color7" = normal.white;
|
||||
"*.color8" = bright.black;
|
||||
"*.color9" = bright.red;
|
||||
"*.color10" = bright.green;
|
||||
"*.color11" = bright.yellow;
|
||||
"*.color12" = bright.blue;
|
||||
"*.color13" = bright.magenta;
|
||||
"*.color14" = bright.cyan;
|
||||
"*.color15" = bright.white;
|
||||
"*.foreground" = util.fg;
|
||||
"*.background" = util.bg;
|
||||
"*.cursorColor" = util.cursor;
|
||||
"*.selection_foreground" = util.fg_sel;
|
||||
"*.selection_background" = util.bg_sel;
|
||||
"*.color0" = normal.black;
|
||||
"*.color1" = normal.red;
|
||||
"*.color2" = normal.green;
|
||||
"*.color3" = normal.yellow;
|
||||
"*.color4" = normal.blue;
|
||||
"*.color5" = normal.magenta;
|
||||
"*.color6" = normal.cyan;
|
||||
"*.color7" = normal.white;
|
||||
"*.color8" = bright.black;
|
||||
"*.color9" = bright.red;
|
||||
"*.color10" = bright.green;
|
||||
"*.color11" = bright.yellow;
|
||||
"*.color12" = bright.blue;
|
||||
"*.color13" = bright.magenta;
|
||||
"*.color14" = bright.cyan;
|
||||
"*.color15" = bright.white;
|
||||
};
|
||||
xdg.configFile =
|
||||
builtins.mapAttrs (name: value: {
|
||||
|
@ -192,28 +192,34 @@ in {
|
|||
{
|
||||
"swaync/config.json" = dots/swaync/config.json;
|
||||
"swaync/configSchema.json" = dots/swaync/configSchema.json;
|
||||
} //
|
||||
{
|
||||
}
|
||||
// {
|
||||
"swaync/style.css" = {
|
||||
enable = true;
|
||||
text = with palette-hex; (builtins.replaceStrings
|
||||
["#PANELBG"
|
||||
enable = true;
|
||||
text = with palette-hex; (builtins.replaceStrings
|
||||
[
|
||||
"#PANELBG"
|
||||
"#BORDER"
|
||||
"#NOTIBGNORM"
|
||||
"#NOTIBGHOVER"
|
||||
"#NOTIBGFOCUS"
|
||||
"#NOTIBGCLOSE"
|
||||
"#NOTIBGHOVERCLOSE"
|
||||
"#BGSELECTED"]
|
||||
[util.bg
|
||||
"#NOTIBGHVERCLOSE"
|
||||
"#BGSELECTED"
|
||||
"#FONT"
|
||||
]
|
||||
[
|
||||
util.bg
|
||||
normal.black
|
||||
util.bg
|
||||
bright.black
|
||||
bright.black
|
||||
normal.black
|
||||
bright.black
|
||||
bright.black]
|
||||
(builtins.readFile dots/swaync/style.css));
|
||||
bright.black
|
||||
pkgs.rice.fonts.sans.name
|
||||
]
|
||||
(builtins.readFile dots/swaync/style.css));
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -222,25 +228,29 @@ in {
|
|||
"${pkgs.gsettings-desktop-schemas}/share/gsettings-schemas/${pkgs.gsettings-desktop-schemas.name}"
|
||||
];
|
||||
|
||||
home.sessionVariables = {
|
||||
GTK_THEME = pkgs.rice.gtk.name;
|
||||
};
|
||||
# home.sessionVariables = {
|
||||
# GTK_THEME = pkgs.rice.gtk.name;
|
||||
# };
|
||||
programs.wlogout = {
|
||||
enable = true;
|
||||
layout = (builtins.fromJSON (builtins.readFile dots/wlogout/layout));
|
||||
layout = builtins.fromJSON (builtins.readFile dots/wlogout/layout);
|
||||
style = with palette-hex; (builtins.replaceStrings
|
||||
["/usr/share/wlogout"
|
||||
"/etc/wlogout"
|
||||
"#WINBG"
|
||||
"#BTNCOL"
|
||||
"#BTNBG"
|
||||
"#BTNFOCUSBG"]
|
||||
["${pkgs.wlogout}/share/wlogout"
|
||||
"${pkgs.wlogout}/etc/wlogout"
|
||||
util.bg
|
||||
util.fg
|
||||
util.bg_sel
|
||||
normal.yellow]
|
||||
[
|
||||
"/usr/share/wlogout"
|
||||
"/etc/wlogout"
|
||||
"#WINBG"
|
||||
"#BTNCOL"
|
||||
"#BTNBG"
|
||||
"#BTNFOCUSBG"
|
||||
]
|
||||
[
|
||||
"${pkgs.wlogout}/share/wlogout"
|
||||
"${pkgs.wlogout}/etc/wlogout"
|
||||
util.bg
|
||||
util.fg
|
||||
util.bg_sel
|
||||
normal.yellow
|
||||
]
|
||||
(builtins.readFile dots/wlogout/style.css));
|
||||
};
|
||||
|
||||
|
@ -249,7 +259,7 @@ in {
|
|||
settings = {
|
||||
main = {
|
||||
dpi-aware = "no";
|
||||
font = with fonts.sans; lib.strings.concatStrings [name ":size=" (builtins.toString size)];
|
||||
font = with fonts.sans; lib.strings.concatStrings [name ":size=" (builtins.toString (size + 2))];
|
||||
icon-theme = icons.name;
|
||||
terminal = "kitty";
|
||||
};
|
||||
|
@ -264,23 +274,24 @@ in {
|
|||
background = lib.strings.concatStrings [palette-hex.util.bg "FF"];
|
||||
text = lib.strings.concatStrings [palette-hex.util.fg "FF"];
|
||||
selection = lib.strings.concatStrings [palette-hex.util.bg_sel "FF"];
|
||||
selection-text = lib.strings.concatStrings [palette-hex.util.fg_sel "FF"];
|
||||
selection-match = lib.strings.concatStrings [palette-hex.util.cursor "FF"];
|
||||
selection-text = lib.strings.concatStrings [palette-hex.bright.black "FF"];
|
||||
selection-match = lib.strings.concatStrings [palette-hex.bright.green "FF"];
|
||||
match = lib.strings.concatStrings [palette-hex.util.fg_sel "FF"];
|
||||
border = lib.strings.concatStrings [palette-hex.util.bg_sel "FF"];
|
||||
border = lib.strings.concatStrings [palette-hex.bright.yellow "FF"];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
gtk = {
|
||||
gtk = with pkgs.rice; {
|
||||
enable = true;
|
||||
theme = with pkgs.rice.gtk; {
|
||||
package = package;
|
||||
name = name;
|
||||
theme = with gtk-theme; {
|
||||
inherit package name;
|
||||
};
|
||||
iconTheme = with pkgs.rice.icons; {
|
||||
package = package;
|
||||
name = name;
|
||||
iconTheme = with icons; {
|
||||
inherit package name;
|
||||
};
|
||||
font = with fonts.sans; {
|
||||
inherit name size package;
|
||||
};
|
||||
};
|
||||
|
||||
|
|
105
rice.nix
105
rice.nix
|
@ -1,81 +1,90 @@
|
|||
self: super: let
|
||||
theme = super.lib.nix-rice.kitty-themes.getThemeByName "rose-pine";
|
||||
final: prev:
|
||||
with prev.lib.nix-rice; let
|
||||
theme = kitty-themes.getThemeByName "rose-pine";
|
||||
in rec {
|
||||
rice = {
|
||||
palette = with super.lib.nix-rice; rec {
|
||||
normal = palette.defaultPalette // {
|
||||
black = theme.color0;
|
||||
red = theme.color1;
|
||||
green = theme.color2;
|
||||
yellow = theme.color3;
|
||||
blue = theme.color4;
|
||||
magenta = theme.color5;
|
||||
cyan = theme.color6;
|
||||
white = theme.color7;
|
||||
};
|
||||
bright = palette.defaultPalette // {
|
||||
black = theme.color8;
|
||||
red = theme.color9;
|
||||
green = theme.color10;
|
||||
yellow = theme.color11;
|
||||
blue = theme.color12;
|
||||
magenta = theme.color13;
|
||||
cyan = theme.color14;
|
||||
white = theme.color15;
|
||||
};
|
||||
util = palette.defaultPalette // {
|
||||
fg = theme.foreground;
|
||||
bg = theme.background;
|
||||
fg_sel = theme.selection_foreground;
|
||||
bg_sel = theme.selection_background;
|
||||
cursor = theme.cursor;
|
||||
cursor_text = theme.cursor_text_color;
|
||||
url = theme.url_color;
|
||||
};
|
||||
} // theme;
|
||||
palette =
|
||||
rec {
|
||||
bright =
|
||||
palette.defaultPalette
|
||||
// {
|
||||
black = theme.color0;
|
||||
red = theme.color1;
|
||||
green = theme.color2;
|
||||
yellow = theme.color3;
|
||||
blue = theme.color4;
|
||||
magenta = theme.color5;
|
||||
cyan = theme.color6;
|
||||
white = theme.color7;
|
||||
};
|
||||
normal =
|
||||
palette.darken 15 bright;
|
||||
util =
|
||||
palette.defaultPalette
|
||||
// {
|
||||
fg = theme.foreground;
|
||||
bg = theme.background;
|
||||
fg_sel = theme.selection_foreground;
|
||||
bg_sel = theme.selection_background;
|
||||
cursor = theme.cursor;
|
||||
cursor_text = theme.cursor_text_color;
|
||||
url = theme.url_color;
|
||||
};
|
||||
}
|
||||
// theme;
|
||||
|
||||
fonts = {
|
||||
fonts = rec {
|
||||
sans = {
|
||||
name = "Inria Sans";
|
||||
size = 14;
|
||||
package = self.inriafonts;
|
||||
size = 12;
|
||||
package = final.inriafonts;
|
||||
};
|
||||
serif = {
|
||||
name = "Inria Serif";
|
||||
size = 14;
|
||||
package = self.inriafonts;
|
||||
size = 12;
|
||||
package = final.inriafonts;
|
||||
};
|
||||
monospace = {
|
||||
name = "Fira Code";
|
||||
size = 10;
|
||||
package = self.fira-code;
|
||||
package = final.fira-code;
|
||||
};
|
||||
emoji = {
|
||||
name = "Twitter Color Emoji";
|
||||
size = 14;
|
||||
package = self.twemoji-color-font;
|
||||
size = 12;
|
||||
package = final.twemoji-color-font;
|
||||
};
|
||||
pkgs = with final; [
|
||||
sans.package
|
||||
serif.package
|
||||
monospace.package
|
||||
emoji.package
|
||||
meslo-lgs-nf
|
||||
material-icons
|
||||
material-design-icons
|
||||
];
|
||||
};
|
||||
|
||||
icons = {
|
||||
name = "RosePine-Main";
|
||||
package = self.rose-pine-icons;
|
||||
name = "Rose-Pine";
|
||||
package = final.rose-pine-icons;
|
||||
};
|
||||
|
||||
gtk = {
|
||||
package = self.rose-pine-theme;
|
||||
gtk-theme = {
|
||||
name = "RosePine-Main";
|
||||
package = final.rose-pine-theme;
|
||||
};
|
||||
|
||||
|
||||
borders = {
|
||||
thickness = 4;
|
||||
rounding = 10;
|
||||
};
|
||||
|
||||
bg = {
|
||||
image = super.fetchurl {
|
||||
sha256 = "sha256-VenNP2aJ55hU8AfqZ4KHzTkiq+9GveHqL69vgSmRPlE=";
|
||||
url = "https://github.com/rose-pine/wallpapers/blob/main/blockwavemoon.png?raw=true";
|
||||
image = prev.fetchurl {
|
||||
url = "https://github.com/the-argus/wallpapers/blob/main/rose/minimal_squares_rosepine.png?raw=true";
|
||||
sha256 = "sha256-mZNgRDyEB5EzGucguv3vWTFaRBOEVS94bJjv7XVNW+Y=";
|
||||
};
|
||||
};
|
||||
}; # /rice
|
||||
|
|
|
@ -33,39 +33,6 @@
|
|||
# inputs.helix
|
||||
];
|
||||
|
||||
# stylix = {
|
||||
# polarity = "dark";
|
||||
# image = pkgs.fetchurl {
|
||||
# sha256 = "sha256-6BCoxgqK5pCxv5P7Rf5MoyLbHAShRd3YuacAcZ916C8=";
|
||||
# url = "https://gruvbox-wallpapers.pages.dev/wallpapers/irl/flowers-2.jpg";
|
||||
# };
|
||||
# base16Scheme = "${inputs.base16-schemes}/gruvbox-dark-hard.yaml";
|
||||
# fonts = {
|
||||
# sizes = {
|
||||
# desktop = 12;
|
||||
# popups = 12;
|
||||
# terminal = 10;
|
||||
# applications = 12;
|
||||
# };
|
||||
# monospace = {
|
||||
# name = "Fira Code";
|
||||
# package = pkgs.fira-code;
|
||||
# };
|
||||
# sansSerif = {
|
||||
# name = "Inria Sans";
|
||||
# package = pkgs.inriafonts;
|
||||
# };
|
||||
# serif = {
|
||||
# name = "Inria Serif";
|
||||
# package = pkgs.inriafonts;
|
||||
# };
|
||||
# emoji = {
|
||||
# name = "Twitter Color Emoji";
|
||||
# package = pkgs.twemoji-color-font;
|
||||
# };
|
||||
# };
|
||||
# };
|
||||
|
||||
# cachix = [
|
||||
# "nix-community"
|
||||
# ];
|
||||
|
@ -85,7 +52,7 @@
|
|||
boot.loader.timeout = 3;
|
||||
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
boot.tmpOnTmpfs = true;
|
||||
boot.tmp.useTmpfs = true;
|
||||
|
||||
networking.networkmanager.enable = true; # Easiest to use and most distros use this by default.
|
||||
|
||||
|
@ -207,8 +174,7 @@
|
|||
serviceConfig = {
|
||||
Type = "oneshot";
|
||||
User = "root";
|
||||
ExecStart = '' ${pkgs.bash}/bin/bash -c 'if [[ "$( ${pkgs.iproute2}/bin/ip rule | grep -e "62:.*52" | wc -l)" -eq 0 ]]; then ${pkgs.iproute2}/bin/ip rule add pref 62 table 52; fi''';
|
||||
# ExecStop = ''${pkgs.iproute2}/bin/ip rule del pref 62 table 52'';
|
||||
ExecStart = ''${pkgs.bash}/bin/bash -c "if [[ \"$( ${pkgs.iproute2}/bin/ip rule | grep -e \"62:.*52\" | wc -l)\" -eq 0 ]]; then ${pkgs.iproute2}/bin/ip rule add pref 62 table 52; fi"'';
|
||||
};
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue