mirror of
https://github.com/nmasur/dotfiles
synced 2024-09-08 01:14:14 +00:00
refactor colors and options
preparing for light mode, even though specializations aren't working
This commit is contained in:
parent
b2850e8b79
commit
41d289c5db
@ -3,9 +3,9 @@
|
||||
imports =
|
||||
[ ../modules/shell ../modules/neovim ../modules/repositories/dotfiles.nix ];
|
||||
|
||||
options = with lib; {
|
||||
user = mkOption {
|
||||
type = types.str;
|
||||
options = rec {
|
||||
user = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
description = "Primary user of the system";
|
||||
};
|
||||
fullName = lib.mkOption {
|
||||
@ -27,17 +27,30 @@
|
||||
default = "/etc/ssh/ssh_host_ed25519_key";
|
||||
};
|
||||
gui = {
|
||||
enable = mkEnableOption {
|
||||
description = "Enable graphics";
|
||||
enable = lib.mkEnableOption {
|
||||
description = "Enable graphics.";
|
||||
default = false;
|
||||
};
|
||||
};
|
||||
colorscheme = mkOption {
|
||||
type = types.attrs;
|
||||
description = "Base16 color scheme";
|
||||
theme = {
|
||||
colors = lib.mkOption {
|
||||
type = lib.types.attrs;
|
||||
description = "Base16 color scheme.";
|
||||
default = (import ../modules/colorscheme/gruvbox).dark;
|
||||
};
|
||||
dark = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
description = "Enable dark mode.";
|
||||
default = true;
|
||||
};
|
||||
};
|
||||
homePath = mkOption {
|
||||
type = types.path;
|
||||
|
||||
# colorscheme = lib.mkOption {
|
||||
# type = types.attrs;
|
||||
# description = "Base16 color scheme";
|
||||
# };
|
||||
homePath = lib.mkOption {
|
||||
type = lib.types.path;
|
||||
description = "Path of user's home directory.";
|
||||
default = builtins.toPath (if pkgs.stdenv.isDarwin then
|
||||
"/Users/${config.user}"
|
||||
@ -45,17 +58,17 @@
|
||||
"/home/${config.user}");
|
||||
};
|
||||
|
||||
dotfilesPath = mkOption {
|
||||
type = types.path;
|
||||
dotfilesPath = lib.mkOption {
|
||||
type = lib.types.path;
|
||||
description = "Path of dotfiles repository.";
|
||||
default = config.homePath + "/dev/personal/dotfiles";
|
||||
};
|
||||
dotfilesRepo = mkOption {
|
||||
type = types.str;
|
||||
dotfilesRepo = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
description = "Link to dotfiles repository.";
|
||||
};
|
||||
unfreePackages = mkOption {
|
||||
type = types.listOf types.str;
|
||||
unfreePackages = lib.mkOption {
|
||||
type = lib.types.listOf lib.types.str;
|
||||
description = "List of unfree packages to allow.";
|
||||
default = [ ];
|
||||
};
|
||||
|
@ -15,15 +15,13 @@ nixpkgs.lib.nixosSystem {
|
||||
# Set registry to flake packages, used for nix X commands
|
||||
nix.registry.nixpkgs.flake = nixpkgs;
|
||||
identityFile = "/home/${globals.user}/.ssh/id_ed25519";
|
||||
gaming.steam = true;
|
||||
gaming.legendary = true;
|
||||
gui = {
|
||||
enable = true;
|
||||
compositor.enable = true;
|
||||
wallpaper = "${wallpapers}/gruvbox/road.jpg";
|
||||
gtk.theme = { name = "Adwaita-dark"; };
|
||||
gui.enable = true;
|
||||
theme = {
|
||||
colors = (import ../../modules/colorscheme/gruvbox).dark;
|
||||
dark = true;
|
||||
};
|
||||
colorscheme = (import ../../modules/colorscheme/gruvbox);
|
||||
wallpaper = "${wallpapers}/gruvbox/road.jpg";
|
||||
gtk.theme.name = nixpkgs.lib.mkDefault "Adwaita-dark";
|
||||
passwordHash =
|
||||
"$6$PZYiMGmJIIHAepTM$Wx5EqTQ5GApzXx58nvi8azh16pdxrN6Qrv1wunDlzveOgawitWzcIxuj76X9V868fsPi/NOIEO8yVXqwzS9UF.";
|
||||
}
|
||||
@ -33,14 +31,17 @@ nixpkgs.lib.nixosSystem {
|
||||
../../modules/hardware
|
||||
../../modules/nixos
|
||||
../../modules/graphical
|
||||
../../modules/gaming
|
||||
../../modules/applications
|
||||
../../modules/gaming/steam.nix
|
||||
../../modules/gaming/legendary.nix
|
||||
../../modules/applications/media.nix
|
||||
../../modules/applications/firefox.nix
|
||||
../../modules/applications/kitty.nix
|
||||
../../modules/applications/discord.nix
|
||||
../../modules/applications/nautilus.nix
|
||||
../../modules/mail/default.nix
|
||||
../../modules/repositories/notes.nix
|
||||
../../modules/services/keybase.nix
|
||||
../../modules/services/gnupg.nix
|
||||
../../modules/services/mullvad.nix
|
||||
../../modules/programming/nix.nix
|
||||
../../modules/programming/haskell.nix
|
||||
];
|
||||
}
|
||||
|
@ -54,32 +54,32 @@
|
||||
];
|
||||
colors = {
|
||||
primary = {
|
||||
background = config.colorscheme.base00;
|
||||
foreground = config.colorscheme.base05;
|
||||
background = config.theme.colors.base00;
|
||||
foreground = config.theme.colors.base05;
|
||||
};
|
||||
cursor = {
|
||||
text = "#1d2021";
|
||||
cursor = config.colorscheme.base05;
|
||||
cursor = config.theme.colors.base05;
|
||||
};
|
||||
normal = {
|
||||
black = "#1d2021";
|
||||
red = config.colorscheme.base08;
|
||||
green = config.colorscheme.base0B;
|
||||
yellow = config.colorscheme.base0A;
|
||||
blue = config.colorscheme.base0D;
|
||||
magenta = config.colorscheme.base0E;
|
||||
cyan = config.colorscheme.base0C;
|
||||
white = config.colorscheme.base05;
|
||||
red = config.theme.colors.base08;
|
||||
green = config.theme.colors.base0B;
|
||||
yellow = config.theme.colors.base0A;
|
||||
blue = config.theme.colors.base0D;
|
||||
magenta = config.theme.colors.base0E;
|
||||
cyan = config.theme.colors.base0C;
|
||||
white = config.theme.colors.base05;
|
||||
};
|
||||
bright = {
|
||||
black = config.colorscheme.base03;
|
||||
red = config.colorscheme.base09;
|
||||
green = config.colorscheme.base01;
|
||||
yellow = config.colorscheme.base02;
|
||||
blue = config.colorscheme.base04;
|
||||
magenta = config.colorscheme.base06;
|
||||
cyan = config.colorscheme.base0F;
|
||||
white = config.colorscheme.base07;
|
||||
black = config.theme.colors.base03;
|
||||
red = config.theme.colors.base09;
|
||||
green = config.theme.colors.base01;
|
||||
yellow = config.theme.colors.base02;
|
||||
blue = config.theme.colors.base04;
|
||||
magenta = config.theme.colors.base06;
|
||||
cyan = config.theme.colors.base0F;
|
||||
white = config.theme.colors.base07;
|
||||
};
|
||||
};
|
||||
draw_bold_text_with_bright_colors = false;
|
||||
|
@ -48,65 +48,65 @@
|
||||
};
|
||||
userChrome = ''
|
||||
:root {
|
||||
--focus-outline-color: ${config.colorscheme.base04} !important;
|
||||
--toolbar-color: ${config.colorscheme.base07} !important;
|
||||
--focus-outline-color: ${config.theme.colors.base04} !important;
|
||||
--toolbar-color: ${config.theme.colors.base07} !important;
|
||||
--tab-min-height: 30px !important;
|
||||
}
|
||||
/* Background of tab bar */
|
||||
.toolbar-items {
|
||||
background-color: ${config.colorscheme.base00} !important;
|
||||
background-color: ${config.theme.colors.base00} !important;
|
||||
}
|
||||
/* Tabs themselves */
|
||||
.tabbrowser-tab .tab-stack {
|
||||
border-radius: 5px 5px 0 0;
|
||||
overflow: hidden;
|
||||
background-color: ${config.colorscheme.base00};
|
||||
color: ${config.colorscheme.base06} !important;
|
||||
background-color: ${config.theme.colors.base00};
|
||||
color: ${config.theme.colors.base06} !important;
|
||||
}
|
||||
.tab-content {
|
||||
border-bottom: 2px solid color-mix(in srgb, var(--identity-tab-color) 40%, transparent);
|
||||
border-radius: 5px 5px 0 0;
|
||||
background-color: ${config.colorscheme.base00};
|
||||
color: ${config.colorscheme.base06} !important;
|
||||
background-color: ${config.theme.colors.base00};
|
||||
color: ${config.theme.colors.base06} !important;
|
||||
}
|
||||
.tab-content[selected=true] {
|
||||
border-bottom: 2px solid color-mix(in srgb, var(--identity-tab-color) 25%, transparent);
|
||||
background-color: ${config.colorscheme.base01} !important;
|
||||
color: ${config.colorscheme.base07} !important;
|
||||
background-color: ${config.theme.colors.base01} !important;
|
||||
color: ${config.theme.colors.base07} !important;
|
||||
}
|
||||
/* Below tab bar */
|
||||
#nav-bar {
|
||||
background: ${config.colorscheme.base01} !important;
|
||||
background: ${config.theme.colors.base01} !important;
|
||||
}
|
||||
/* URL bar in nav bar */
|
||||
#urlbar[focused=true] {
|
||||
color: ${config.colorscheme.base07} !important;
|
||||
background: ${config.colorscheme.base02} !important;
|
||||
caret-color: ${config.colorscheme.base05} !important;
|
||||
color: ${config.theme.colors.base07} !important;
|
||||
background: ${config.theme.colors.base02} !important;
|
||||
caret-color: ${config.theme.colors.base05} !important;
|
||||
}
|
||||
#urlbar:not([focused=true]) {
|
||||
color: ${config.colorscheme.base04} !important;
|
||||
background: ${config.colorscheme.base02} !important;
|
||||
color: ${config.theme.colors.base04} !important;
|
||||
background: ${config.theme.colors.base02} !important;
|
||||
}
|
||||
#urlbar ::-moz-selection {
|
||||
color: ${config.colorscheme.base07} !important;
|
||||
background: ${config.colorscheme.base02} !important;
|
||||
color: ${config.theme.colors.base07} !important;
|
||||
background: ${config.theme.colors.base02} !important;
|
||||
}
|
||||
#urlbar-input-container {
|
||||
border: 1px solid ${config.colorscheme.base01} !important;
|
||||
border: 1px solid ${config.theme.colors.base01} !important;
|
||||
}
|
||||
#urlbar-background {
|
||||
background: ${config.colorscheme.base01} !important;
|
||||
background: ${config.theme.colors.base01} !important;
|
||||
}
|
||||
/* Text in URL bar */
|
||||
#urlbar-input, #urlbar-scheme, .searchbar-textbox {
|
||||
color: ${config.colorscheme.base07} !important;
|
||||
color: ${config.theme.colors.base07} !important;
|
||||
}
|
||||
'';
|
||||
userContent = ''
|
||||
@-moz-document url-prefix(about:blank) {
|
||||
* {
|
||||
background-color:${config.colorscheme.base01} !important;
|
||||
background-color:${config.theme.colors.base01} !important;
|
||||
}
|
||||
}
|
||||
'';
|
||||
|
@ -16,47 +16,47 @@
|
||||
settings = {
|
||||
|
||||
# Colors (adapted from: https://github.com/kdrag0n/base16-kitty/blob/master/templates/default-256.mustache)
|
||||
background = config.colorscheme.base00;
|
||||
foreground = config.colorscheme.base05;
|
||||
selection_background = config.colorscheme.base05;
|
||||
selection_foreground = config.colorscheme.base00;
|
||||
url_color = config.colorscheme.base04;
|
||||
cursor = config.colorscheme.base05;
|
||||
active_border_color = config.colorscheme.base03;
|
||||
inactive_border_color = config.colorscheme.base01;
|
||||
active_tab_background = config.colorscheme.base00;
|
||||
active_tab_foreground = config.colorscheme.base05;
|
||||
inactive_tab_background = config.colorscheme.base01;
|
||||
inactive_tab_foreground = config.colorscheme.base04;
|
||||
tab_bar_background = config.colorscheme.base01;
|
||||
background = config.theme.colors.base00;
|
||||
foreground = config.theme.colors.base05;
|
||||
selection_background = config.theme.colors.base05;
|
||||
selection_foreground = config.theme.colors.base00;
|
||||
url_color = config.theme.colors.base04;
|
||||
cursor = config.theme.colors.base05;
|
||||
active_border_color = config.theme.colors.base03;
|
||||
inactive_border_color = config.theme.colors.base01;
|
||||
active_tab_background = config.theme.colors.base00;
|
||||
active_tab_foreground = config.theme.colors.base05;
|
||||
inactive_tab_background = config.theme.colors.base01;
|
||||
inactive_tab_foreground = config.theme.colors.base04;
|
||||
tab_bar_background = config.theme.colors.base01;
|
||||
|
||||
# normal
|
||||
color0 = config.colorscheme.base00;
|
||||
color1 = config.colorscheme.base08;
|
||||
color2 = config.colorscheme.base0B;
|
||||
color3 = config.colorscheme.base0A;
|
||||
color4 = config.colorscheme.base0D;
|
||||
color5 = config.colorscheme.base0E;
|
||||
color6 = config.colorscheme.base0C;
|
||||
color7 = config.colorscheme.base05;
|
||||
color0 = config.theme.colors.base00;
|
||||
color1 = config.theme.colors.base08;
|
||||
color2 = config.theme.colors.base0B;
|
||||
color3 = config.theme.colors.base0A;
|
||||
color4 = config.theme.colors.base0D;
|
||||
color5 = config.theme.colors.base0E;
|
||||
color6 = config.theme.colors.base0C;
|
||||
color7 = config.theme.colors.base05;
|
||||
|
||||
# bright
|
||||
color8 = config.colorscheme.base03;
|
||||
color9 = config.colorscheme.base08;
|
||||
color10 = config.colorscheme.base0B;
|
||||
color11 = config.colorscheme.base0A;
|
||||
color12 = config.colorscheme.base0D;
|
||||
color13 = config.colorscheme.base0E;
|
||||
color14 = config.colorscheme.base0C;
|
||||
color15 = config.colorscheme.base07;
|
||||
color8 = config.theme.colors.base03;
|
||||
color9 = config.theme.colors.base08;
|
||||
color10 = config.theme.colors.base0B;
|
||||
color11 = config.theme.colors.base0A;
|
||||
color12 = config.theme.colors.base0D;
|
||||
color13 = config.theme.colors.base0E;
|
||||
color14 = config.theme.colors.base0C;
|
||||
color15 = config.theme.colors.base07;
|
||||
|
||||
# extended base16 colors
|
||||
color16 = config.colorscheme.base09;
|
||||
color17 = config.colorscheme.base0F;
|
||||
color18 = config.colorscheme.base01;
|
||||
color19 = config.colorscheme.base02;
|
||||
color20 = config.colorscheme.base04;
|
||||
color21 = config.colorscheme.base06;
|
||||
color16 = config.theme.colors.base09;
|
||||
color17 = config.theme.colors.base0F;
|
||||
color18 = config.theme.colors.base01;
|
||||
color19 = config.theme.colors.base02;
|
||||
color20 = config.theme.colors.base04;
|
||||
color21 = config.theme.colors.base06;
|
||||
|
||||
# Scrollback
|
||||
scrolling_lines = 10000;
|
||||
|
@ -2,21 +2,42 @@
|
||||
name = "gruvbox"; # Dark, Medium
|
||||
author =
|
||||
"Dawid Kurek (dawikur@gmail.com), morhetz (https://github.com/morhetz/gruvbox)";
|
||||
base00 = "#282828"; # ----
|
||||
base01 = "#3c3836"; # ---
|
||||
base02 = "#504945"; # --
|
||||
base03 = "#665c54"; # -
|
||||
base04 = "#bdae93"; # +
|
||||
base05 = "#d5c4a1"; # ++
|
||||
base06 = "#ebdbb2"; # +++
|
||||
base07 = "#fbf1c7"; # ++++
|
||||
base08 = "#fb4934"; # red
|
||||
base09 = "#fe8019"; # orange
|
||||
base0A = "#fabd2f"; # yellow
|
||||
base0B = "#b8bb26"; # green
|
||||
base0C = "#8ec07c"; # aqua/cyan
|
||||
base0D = "#83a598"; # blue
|
||||
base0E = "#d3869b"; # purple
|
||||
base0F = "#d65d0e"; # brown
|
||||
neovimConfig = ./neovim.lua;
|
||||
dark = {
|
||||
base00 = "#282828"; # ----
|
||||
base01 = "#3c3836"; # ---
|
||||
base02 = "#504945"; # --
|
||||
base03 = "#665c54"; # -
|
||||
base04 = "#bdae93"; # +
|
||||
base05 = "#d5c4a1"; # ++
|
||||
base06 = "#ebdbb2"; # +++
|
||||
base07 = "#fbf1c7"; # ++++
|
||||
base08 = "#fb4934"; # red
|
||||
base09 = "#fe8019"; # orange
|
||||
base0A = "#fabd2f"; # yellow
|
||||
base0B = "#b8bb26"; # green
|
||||
base0C = "#8ec07c"; # aqua/cyan
|
||||
base0D = "#83a598"; # blue
|
||||
base0E = "#d3869b"; # purple
|
||||
base0F = "#d65d0e"; # brown
|
||||
neovimConfig = ./neovim.lua;
|
||||
};
|
||||
light = {
|
||||
base00 = "#fbf1c7"; # ----
|
||||
base01 = "#ebdbb2"; # ---
|
||||
base02 = "#d5c4a1"; # --
|
||||
base03 = "#bdae93"; # -
|
||||
base04 = "#665c54"; # +
|
||||
base05 = "#504945"; # ++
|
||||
base06 = "#3c3836"; # +++
|
||||
base07 = "#282828"; # ++++
|
||||
base08 = "#9d0006"; # red
|
||||
base09 = "#af3a03"; # orange
|
||||
base0A = "#b57614"; # yellow
|
||||
base0B = "#79740e"; # green
|
||||
base0C = "#427b58"; # aqua/cyan
|
||||
base0D = "#076678"; # blue
|
||||
base0E = "#8f3f71"; # purple
|
||||
base0F = "#d65d0e"; # brown
|
||||
neovimConfig = ./neovim-light.lua;
|
||||
};
|
||||
}
|
||||
|
@ -6,6 +6,7 @@ M.packer = function(use)
|
||||
config = function()
|
||||
vim.g.gruvbox_italicize_strings = 0
|
||||
vim.cmd("colorscheme gruvbox8")
|
||||
vim.cmd("set background=dark")
|
||||
end,
|
||||
})
|
||||
end
|
||||
|
@ -1,7 +1,5 @@
|
||||
{ config, ... }: {
|
||||
|
||||
imports = [ ./leagueoflegends.nix ./lutris.nix ./steam.nix ./legendary.nix ];
|
||||
|
||||
config = {
|
||||
hardware.opengl = {
|
||||
enable = true;
|
||||
|
@ -4,10 +4,9 @@ let home-packages = config.home-manager.users.${config.user}.home.packages;
|
||||
|
||||
in {
|
||||
|
||||
options.gaming.legendary =
|
||||
lib.mkEnableOption "Legendary - Epic Games Launcher";
|
||||
imports = [ ./. ];
|
||||
|
||||
config = lib.mkIf config.gaming.legendary {
|
||||
config = {
|
||||
environment.systemPackages = with pkgs; [
|
||||
legendary-gl
|
||||
rare # GUI for Legendary (not working)
|
||||
|
@ -1,8 +1,8 @@
|
||||
{ config, pkgs, lib, ... }: {
|
||||
|
||||
options.gaming.steam = lib.mkEnableOption "Steam";
|
||||
imports = [ ./. ];
|
||||
|
||||
config = lib.mkIf config.gaming.steam {
|
||||
config = {
|
||||
hardware.steam-hardware.enable = true;
|
||||
unfreePackages = [ "steam" "steam-original" "steamcmd" "steam-run" ];
|
||||
environment.systemPackages = with pkgs; [
|
||||
|
@ -1,53 +1,29 @@
|
||||
{ lib, ... }: {
|
||||
|
||||
imports = [
|
||||
./xorg.nix
|
||||
./fonts.nix
|
||||
./i3.nix
|
||||
./polybar.nix
|
||||
./picom.nix
|
||||
# ./dmenu.nix
|
||||
./rofi.nix
|
||||
];
|
||||
imports =
|
||||
[ ./xorg.nix ./fonts.nix ./i3.nix ./polybar.nix ./picom.nix ./rofi.nix ];
|
||||
|
||||
options = with lib; {
|
||||
options = {
|
||||
|
||||
gui = {
|
||||
compositor.enable = mkEnableOption {
|
||||
description = "Enable transparency, blur, shadows";
|
||||
default = false;
|
||||
};
|
||||
launcherCommand = mkOption {
|
||||
type = types.str;
|
||||
description = "Command to use for launching";
|
||||
};
|
||||
systemdSearch = mkOption {
|
||||
type = types.str;
|
||||
description = "Command to use for interacting with systemd";
|
||||
};
|
||||
altTabCommand = mkOption {
|
||||
type = types.str;
|
||||
description = "Command to use for choosing windows";
|
||||
};
|
||||
toggleBarCommand = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
description = "Command to hide and show the status bar.";
|
||||
};
|
||||
gtk.theme = {
|
||||
name = mkOption {
|
||||
type = types.str;
|
||||
description = "Theme name for GTK applications";
|
||||
};
|
||||
package = mkOption {
|
||||
type = types.str;
|
||||
description = "Theme package name for GTK applications";
|
||||
default = "gnome-themes-extra";
|
||||
};
|
||||
};
|
||||
wallpaper = mkOption {
|
||||
type = types.path;
|
||||
description = "Wallpaper background image file";
|
||||
};
|
||||
launcherCommand = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
description = "Command to use for launching";
|
||||
};
|
||||
systemdSearch = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
description = "Command to use for interacting with systemd";
|
||||
};
|
||||
altTabCommand = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
description = "Command to use for choosing windows";
|
||||
};
|
||||
toggleBarCommand = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
description = "Command to hide and show the status bar.";
|
||||
};
|
||||
wallpaper = lib.mkOption {
|
||||
type = lib.types.path;
|
||||
description = "Wallpaper background image file";
|
||||
};
|
||||
|
||||
};
|
||||
|
@ -5,10 +5,9 @@ let
|
||||
lockCmd =
|
||||
"${pkgs.betterlockscreen}/bin/betterlockscreen --lock --display 1 --blur 0.5 --span";
|
||||
lockUpdate =
|
||||
"${pkgs.betterlockscreen}/bin/betterlockscreen --update ${config.gui.wallpaper} --display 1 --span";
|
||||
"${pkgs.betterlockscreen}/bin/betterlockscreen --update ${config.wallpaper} --display 1 --span";
|
||||
|
||||
in
|
||||
{
|
||||
in {
|
||||
|
||||
config = {
|
||||
|
||||
@ -28,223 +27,219 @@ in
|
||||
xsession.windowManager.i3 = {
|
||||
enable = config.services.xserver.enable;
|
||||
package = pkgs.i3-gaps;
|
||||
config =
|
||||
let
|
||||
modifier = "Mod4"; # Super key
|
||||
ws1 = "1:I";
|
||||
ws2 = "2:II";
|
||||
ws3 = "3:III";
|
||||
ws4 = "4:IV";
|
||||
ws5 = "5:V";
|
||||
ws6 = "6:VI";
|
||||
ws7 = "7:VII";
|
||||
ws8 = "8:VIII";
|
||||
ws9 = "9:IX";
|
||||
ws10 = "10:X";
|
||||
in
|
||||
{
|
||||
modifier = modifier;
|
||||
assigns = {
|
||||
"${ws1}" = [{ class = "Firefox"; }];
|
||||
"${ws2}" = [{ class = "kitty"; }];
|
||||
"${ws3}" = [{ class = "discord"; }];
|
||||
"${ws4}" = [{ class = "Steam"; }];
|
||||
};
|
||||
bars = [{ command = "echo"; }]; # Disable i3bar
|
||||
colors =
|
||||
let
|
||||
background = config.colorscheme.base00;
|
||||
inactiveBackground = config.colorscheme.base01;
|
||||
border = config.colorscheme.base01;
|
||||
inactiveBorder = config.colorscheme.base01;
|
||||
text = config.colorscheme.base07;
|
||||
inactiveText = config.colorscheme.base04;
|
||||
urgentBackground = config.colorscheme.base08;
|
||||
indicator = "#00000000";
|
||||
in
|
||||
{
|
||||
background = config.colorscheme.base00;
|
||||
focused = {
|
||||
inherit background indicator text border;
|
||||
childBorder = background;
|
||||
};
|
||||
focusedInactive = {
|
||||
inherit indicator;
|
||||
background = inactiveBackground;
|
||||
border = inactiveBorder;
|
||||
childBorder = inactiveBackground;
|
||||
text = inactiveText;
|
||||
};
|
||||
# placeholder = { };
|
||||
unfocused = {
|
||||
inherit indicator;
|
||||
background = inactiveBackground;
|
||||
border = inactiveBorder;
|
||||
childBorder = inactiveBackground;
|
||||
text = inactiveText;
|
||||
};
|
||||
urgent = {
|
||||
inherit text indicator;
|
||||
background = urgentBackground;
|
||||
border = urgentBackground;
|
||||
childBorder = urgentBackground;
|
||||
};
|
||||
};
|
||||
floating.modifier = modifier;
|
||||
focus = {
|
||||
mouseWarping = true;
|
||||
newWindow = "urgent";
|
||||
followMouse = false;
|
||||
};
|
||||
keybindings = {
|
||||
|
||||
# Adjust screen brightness
|
||||
"Shift+F12" =
|
||||
"exec ${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 + 30 && sleep 1; exec ${pkgs.ddcutil}/bin/ddcutil --display 2 setvcp 10 + 30";
|
||||
"Shift+F11" =
|
||||
"exec ${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 - 30 && sleep 1; exec ${pkgs.ddcutil}/bin/ddcutil --display 2 setvcp 10 - 30";
|
||||
"XF86MonBrightnessUp" =
|
||||
"exec ${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 + 30 && sleep 1; exec ${pkgs.ddcutil}/bin/ddcutil --display 2 setvcp 10 + 30";
|
||||
"XF86MonBrightnessDown" =
|
||||
"exec ${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 - 30 && sleep 1; exec ${pkgs.ddcutil}/bin/ddcutil --display 2 setvcp 10 - 30";
|
||||
|
||||
# Media player controls
|
||||
"XF86AudioPlay" = "exec ${pkgs.playerctl}/bin/playerctl play-pause";
|
||||
"XF86AudioStop" = "exec ${pkgs.playerctl}/bin/playerctl stop";
|
||||
"XF86AudioNext" = "exec ${pkgs.playerctl}/bin/playerctl next";
|
||||
"XF86AudioPrev" = "exec ${pkgs.playerctl}/bin/playerctl previous";
|
||||
|
||||
# Launchers
|
||||
"${modifier}+Return" =
|
||||
"exec --no-startup-id kitty; workspace ${ws2}; layout tabbed";
|
||||
"${modifier}+space" =
|
||||
"exec --no-startup-id ${config.gui.launcherCommand}";
|
||||
"${modifier}+Shift+s" =
|
||||
"exec --no-startup-id ${config.gui.systemdSearch}";
|
||||
"Mod1+Tab" = "exec --no-startup-id ${config.gui.altTabCommand}";
|
||||
"${modifier}+Shift+c" = "reload";
|
||||
"${modifier}+Shift+r" = "restart";
|
||||
"${modifier}+Shift+q" = ''
|
||||
exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -B 'Yes, exit i3' 'i3-msg exit'"'';
|
||||
"${modifier}+Shift+x" = "exec ${lockCmd}";
|
||||
|
||||
# Window options
|
||||
"${modifier}+q" = "kill";
|
||||
"${modifier}+b" = "exec ${config.gui.toggleBarCommand}";
|
||||
"${modifier}+f" = "fullscreen toggle";
|
||||
"${modifier}+h" = "focus left";
|
||||
"${modifier}+j" = "focus down";
|
||||
"${modifier}+k" = "focus up";
|
||||
"${modifier}+l" = "focus right";
|
||||
"${modifier}+Left" = "focus left";
|
||||
"${modifier}+Down" = "focus down";
|
||||
"${modifier}+Up" = "focus up";
|
||||
"${modifier}+Right" = "focus right";
|
||||
"${modifier}+Shift+h" = "move left";
|
||||
"${modifier}+Shift+j" = "move down";
|
||||
"${modifier}+Shift+k" = "move up";
|
||||
"${modifier}+Shift+l" = "move right";
|
||||
"${modifier}+Shift+Left" = "move left";
|
||||
"${modifier}+Shift+Down" = "move down";
|
||||
"${modifier}+Shift+Up" = "move up";
|
||||
"${modifier}+Shift+Right" = "move right";
|
||||
|
||||
# Tiling
|
||||
"${modifier}+i" = "split h";
|
||||
"${modifier}+v" = "split v";
|
||||
"${modifier}+s" = "layout stacking";
|
||||
"${modifier}+t" = "layout tabbed";
|
||||
"${modifier}+e" = "layout toggle split";
|
||||
"${modifier}+Shift+space" = "floating toggle";
|
||||
"${modifier}+Control+space" = "focus mode_toggle";
|
||||
"${modifier}+a" = "focus parent";
|
||||
|
||||
# Workspaces
|
||||
"${modifier}+1" = "workspace ${ws1}";
|
||||
"${modifier}+2" = "workspace ${ws2}";
|
||||
"${modifier}+3" = "workspace ${ws3}";
|
||||
"${modifier}+4" = "workspace ${ws4}";
|
||||
"${modifier}+5" = "workspace ${ws5}";
|
||||
"${modifier}+6" = "workspace ${ws6}";
|
||||
"${modifier}+7" = "workspace ${ws7}";
|
||||
"${modifier}+8" = "workspace ${ws8}";
|
||||
"${modifier}+9" = "workspace ${ws9}";
|
||||
"${modifier}+0" = "workspace ${ws10}";
|
||||
|
||||
# Move windows
|
||||
"${modifier}+Shift+1" =
|
||||
"move container to workspace ${ws1}; workspace ${ws1}";
|
||||
"${modifier}+Shift+2" =
|
||||
"move container to workspace ${ws2}; workspace ${ws2}";
|
||||
"${modifier}+Shift+3" =
|
||||
"move container to workspace ${ws3}; workspace ${ws3}";
|
||||
"${modifier}+Shift+4" =
|
||||
"move container to workspace ${ws4}; workspace ${ws4}";
|
||||
"${modifier}+Shift+5" =
|
||||
"move container to workspace ${ws5}; workspace ${ws5}";
|
||||
"${modifier}+Shift+6" =
|
||||
"move container to workspace ${ws6}; workspace ${ws6}";
|
||||
"${modifier}+Shift+7" =
|
||||
"move container to workspace ${ws7}; workspace ${ws7}";
|
||||
"${modifier}+Shift+8" =
|
||||
"move container to workspace ${ws8}; workspace ${ws8}";
|
||||
"${modifier}+Shift+9" =
|
||||
"move container to workspace ${ws9}; workspace ${ws9}";
|
||||
"${modifier}+Shift+0" =
|
||||
"move container to workspace ${ws10}; workspace ${ws10}";
|
||||
|
||||
# Move screens
|
||||
"${modifier}+Control+l" = "move workspace to output right";
|
||||
"${modifier}+Control+h" = "move workspace to output left";
|
||||
|
||||
# Resizing
|
||||
"${modifier}+r" = ''mode "resize"'';
|
||||
"${modifier}+Control+Shift+h" =
|
||||
"resize shrink width 10 px or 10 ppt";
|
||||
"${modifier}+Control+Shift+j" =
|
||||
"resize grow height 10 px or 10 ppt";
|
||||
"${modifier}+Control+Shift+k" =
|
||||
"resize shrink height 10 px or 10 ppt";
|
||||
"${modifier}+Control+Shift+l" = "resize grow width 10 px or 10 ppt";
|
||||
};
|
||||
modes = { };
|
||||
startup = [
|
||||
{
|
||||
command = "feh --bg-fill ${config.gui.wallpaper}";
|
||||
always = true;
|
||||
notification = false;
|
||||
}
|
||||
{
|
||||
command =
|
||||
"i3-msg workspace ${ws2}, move workspace to output right";
|
||||
notification = false;
|
||||
}
|
||||
{
|
||||
command =
|
||||
"i3-msg workspace ${ws1}, move workspace to output left";
|
||||
notification = false;
|
||||
}
|
||||
];
|
||||
window = {
|
||||
border = 0;
|
||||
hideEdgeBorders = "smart";
|
||||
titlebar = false;
|
||||
};
|
||||
workspaceAutoBackAndForth = false;
|
||||
workspaceOutputAssign = [ ];
|
||||
# gaps = {
|
||||
# bottom = 8;
|
||||
# top = 8;
|
||||
# left = 8;
|
||||
# right = 8;
|
||||
# horizontal = 15;
|
||||
# vertical = 15;
|
||||
# inner = 15;
|
||||
# outer = 0;
|
||||
# smartBorders = "off";
|
||||
# smartGaps = false;
|
||||
# };
|
||||
config = let
|
||||
modifier = "Mod4"; # Super key
|
||||
ws1 = "1:I";
|
||||
ws2 = "2:II";
|
||||
ws3 = "3:III";
|
||||
ws4 = "4:IV";
|
||||
ws5 = "5:V";
|
||||
ws6 = "6:VI";
|
||||
ws7 = "7:VII";
|
||||
ws8 = "8:VIII";
|
||||
ws9 = "9:IX";
|
||||
ws10 = "10:X";
|
||||
in {
|
||||
modifier = modifier;
|
||||
assigns = {
|
||||
"${ws1}" = [{ class = "Firefox"; }];
|
||||
"${ws2}" = [{ class = "kitty"; }];
|
||||
"${ws3}" = [{ class = "discord"; }];
|
||||
"${ws4}" = [{ class = "Steam"; }];
|
||||
};
|
||||
bars = [{ command = "echo"; }]; # Disable i3bar
|
||||
colors = let
|
||||
background = config.theme.colors.base00;
|
||||
inactiveBackground = config.theme.colors.base01;
|
||||
border = config.theme.colors.base01;
|
||||
inactiveBorder = config.theme.colors.base01;
|
||||
text = config.theme.colors.base07;
|
||||
inactiveText = config.theme.colors.base04;
|
||||
urgentBackground = config.theme.colors.base08;
|
||||
indicator = "#00000000";
|
||||
in {
|
||||
background = config.theme.colors.base00;
|
||||
focused = {
|
||||
inherit background indicator text border;
|
||||
childBorder = background;
|
||||
};
|
||||
focusedInactive = {
|
||||
inherit indicator;
|
||||
background = inactiveBackground;
|
||||
border = inactiveBorder;
|
||||
childBorder = inactiveBackground;
|
||||
text = inactiveText;
|
||||
};
|
||||
# placeholder = { };
|
||||
unfocused = {
|
||||
inherit indicator;
|
||||
background = inactiveBackground;
|
||||
border = inactiveBorder;
|
||||
childBorder = inactiveBackground;
|
||||
text = inactiveText;
|
||||
};
|
||||
urgent = {
|
||||
inherit text indicator;
|
||||
background = urgentBackground;
|
||||
border = urgentBackground;
|
||||
childBorder = urgentBackground;
|
||||
};
|
||||
};
|
||||
floating.modifier = modifier;
|
||||
focus = {
|
||||
mouseWarping = true;
|
||||
newWindow = "urgent";
|
||||
followMouse = false;
|
||||
};
|
||||
keybindings = {
|
||||
|
||||
# Adjust screen brightness
|
||||
"Shift+F12" =
|
||||
"exec ${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 + 30 && sleep 1; exec ${pkgs.ddcutil}/bin/ddcutil --display 2 setvcp 10 + 30";
|
||||
"Shift+F11" =
|
||||
"exec ${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 - 30 && sleep 1; exec ${pkgs.ddcutil}/bin/ddcutil --display 2 setvcp 10 - 30";
|
||||
"XF86MonBrightnessUp" =
|
||||
"exec ${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 + 30 && sleep 1; exec ${pkgs.ddcutil}/bin/ddcutil --display 2 setvcp 10 + 30";
|
||||
"XF86MonBrightnessDown" =
|
||||
"exec ${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 - 30 && sleep 1; exec ${pkgs.ddcutil}/bin/ddcutil --display 2 setvcp 10 - 30";
|
||||
|
||||
# Media player controls
|
||||
"XF86AudioPlay" = "exec ${pkgs.playerctl}/bin/playerctl play-pause";
|
||||
"XF86AudioStop" = "exec ${pkgs.playerctl}/bin/playerctl stop";
|
||||
"XF86AudioNext" = "exec ${pkgs.playerctl}/bin/playerctl next";
|
||||
"XF86AudioPrev" = "exec ${pkgs.playerctl}/bin/playerctl previous";
|
||||
|
||||
# Launchers
|
||||
"${modifier}+Return" =
|
||||
"exec --no-startup-id kitty; workspace ${ws2}; layout tabbed";
|
||||
"${modifier}+space" =
|
||||
"exec --no-startup-id ${config.launcherCommand}";
|
||||
"${modifier}+Shift+s" =
|
||||
"exec --no-startup-id ${config.systemdSearch}";
|
||||
"Mod1+Tab" = "exec --no-startup-id ${config.altTabCommand}";
|
||||
"${modifier}+Shift+c" = "reload";
|
||||
"${modifier}+Shift+r" = "restart";
|
||||
"${modifier}+Shift+q" = ''
|
||||
exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -B 'Yes, exit i3' 'i3-msg exit'"'';
|
||||
"${modifier}+Shift+x" = "exec ${lockCmd}";
|
||||
|
||||
# Window options
|
||||
"${modifier}+q" = "kill";
|
||||
"${modifier}+b" = "exec ${config.toggleBarCommand}";
|
||||
"${modifier}+f" = "fullscreen toggle";
|
||||
"${modifier}+h" = "focus left";
|
||||
"${modifier}+j" = "focus down";
|
||||
"${modifier}+k" = "focus up";
|
||||
"${modifier}+l" = "focus right";
|
||||
"${modifier}+Left" = "focus left";
|
||||
"${modifier}+Down" = "focus down";
|
||||
"${modifier}+Up" = "focus up";
|
||||
"${modifier}+Right" = "focus right";
|
||||
"${modifier}+Shift+h" = "move left";
|
||||
"${modifier}+Shift+j" = "move down";
|
||||
"${modifier}+Shift+k" = "move up";
|
||||
"${modifier}+Shift+l" = "move right";
|
||||
"${modifier}+Shift+Left" = "move left";
|
||||
"${modifier}+Shift+Down" = "move down";
|
||||
"${modifier}+Shift+Up" = "move up";
|
||||
"${modifier}+Shift+Right" = "move right";
|
||||
|
||||
# Tiling
|
||||
"${modifier}+i" = "split h";
|
||||
"${modifier}+v" = "split v";
|
||||
"${modifier}+s" = "layout stacking";
|
||||
"${modifier}+t" = "layout tabbed";
|
||||
"${modifier}+e" = "layout toggle split";
|
||||
"${modifier}+Shift+space" = "floating toggle";
|
||||
"${modifier}+Control+space" = "focus mode_toggle";
|
||||
"${modifier}+a" = "focus parent";
|
||||
|
||||
# Workspaces
|
||||
"${modifier}+1" = "workspace ${ws1}";
|
||||
"${modifier}+2" = "workspace ${ws2}";
|
||||
"${modifier}+3" = "workspace ${ws3}";
|
||||
"${modifier}+4" = "workspace ${ws4}";
|
||||
"${modifier}+5" = "workspace ${ws5}";
|
||||
"${modifier}+6" = "workspace ${ws6}";
|
||||
"${modifier}+7" = "workspace ${ws7}";
|
||||
"${modifier}+8" = "workspace ${ws8}";
|
||||
"${modifier}+9" = "workspace ${ws9}";
|
||||
"${modifier}+0" = "workspace ${ws10}";
|
||||
|
||||
# Move windows
|
||||
"${modifier}+Shift+1" =
|
||||
"move container to workspace ${ws1}; workspace ${ws1}";
|
||||
"${modifier}+Shift+2" =
|
||||
"move container to workspace ${ws2}; workspace ${ws2}";
|
||||
"${modifier}+Shift+3" =
|
||||
"move container to workspace ${ws3}; workspace ${ws3}";
|
||||
"${modifier}+Shift+4" =
|
||||
"move container to workspace ${ws4}; workspace ${ws4}";
|
||||
"${modifier}+Shift+5" =
|
||||
"move container to workspace ${ws5}; workspace ${ws5}";
|
||||
"${modifier}+Shift+6" =
|
||||
"move container to workspace ${ws6}; workspace ${ws6}";
|
||||
"${modifier}+Shift+7" =
|
||||
"move container to workspace ${ws7}; workspace ${ws7}";
|
||||
"${modifier}+Shift+8" =
|
||||
"move container to workspace ${ws8}; workspace ${ws8}";
|
||||
"${modifier}+Shift+9" =
|
||||
"move container to workspace ${ws9}; workspace ${ws9}";
|
||||
"${modifier}+Shift+0" =
|
||||
"move container to workspace ${ws10}; workspace ${ws10}";
|
||||
|
||||
# Move screens
|
||||
"${modifier}+Control+l" = "move workspace to output right";
|
||||
"${modifier}+Control+h" = "move workspace to output left";
|
||||
|
||||
# Resizing
|
||||
"${modifier}+r" = ''mode "resize"'';
|
||||
"${modifier}+Control+Shift+h" =
|
||||
"resize shrink width 10 px or 10 ppt";
|
||||
"${modifier}+Control+Shift+j" =
|
||||
"resize grow height 10 px or 10 ppt";
|
||||
"${modifier}+Control+Shift+k" =
|
||||
"resize shrink height 10 px or 10 ppt";
|
||||
"${modifier}+Control+Shift+l" = "resize grow width 10 px or 10 ppt";
|
||||
};
|
||||
modes = { };
|
||||
startup = [
|
||||
{
|
||||
command = "feh --bg-fill ${config.wallpaper}";
|
||||
always = true;
|
||||
notification = false;
|
||||
}
|
||||
{
|
||||
command =
|
||||
"i3-msg workspace ${ws2}, move workspace to output right";
|
||||
notification = false;
|
||||
}
|
||||
{
|
||||
command =
|
||||
"i3-msg workspace ${ws1}, move workspace to output left";
|
||||
notification = false;
|
||||
}
|
||||
];
|
||||
window = {
|
||||
border = 0;
|
||||
hideEdgeBorders = "smart";
|
||||
titlebar = false;
|
||||
};
|
||||
workspaceAutoBackAndForth = false;
|
||||
workspaceOutputAssign = [ ];
|
||||
# gaps = {
|
||||
# bottom = 8;
|
||||
# top = 8;
|
||||
# left = 8;
|
||||
# right = 8;
|
||||
# horizontal = 15;
|
||||
# vertical = 15;
|
||||
# inner = 15;
|
||||
# outer = 0;
|
||||
# smartBorders = "off";
|
||||
# smartGaps = false;
|
||||
# };
|
||||
};
|
||||
extraConfig = "";
|
||||
};
|
||||
|
||||
@ -258,10 +253,9 @@ in
|
||||
# Update lock screen cache only if cache is empty
|
||||
home.activation.updateLockScreenCache =
|
||||
let cacheDir = "${config.homePath}/.cache/betterlockscreen/current";
|
||||
in
|
||||
lib.mkIf config.services.xserver.enable
|
||||
(config.home-manager.users.${config.user}.lib.dag.entryAfter
|
||||
[ "writeBoundary" ] ''
|
||||
in lib.mkIf config.services.xserver.enable
|
||||
(config.home-manager.users.${config.user}.lib.dag.entryAfter
|
||||
[ "writeBoundary" ] ''
|
||||
if [ ! -d ${cacheDir} ] || [ -z "$(ls ${cacheDir})" ]; then
|
||||
$DRY_RUN_CMD ${lockUpdate}
|
||||
fi
|
||||
|
@ -1,50 +1,49 @@
|
||||
{ config, lib, ... }: {
|
||||
|
||||
config =
|
||||
lib.mkIf (config.services.xserver.enable && config.gui.compositor.enable) {
|
||||
home-manager.users.${config.user} = {
|
||||
config = lib.mkIf (config.services.xserver.enable) {
|
||||
home-manager.users.${config.user} = {
|
||||
|
||||
services.picom = {
|
||||
enable = true;
|
||||
backend = "glx";
|
||||
settings = {
|
||||
blur = false;
|
||||
blurExclude = [ ];
|
||||
inactiveDim = "0.05";
|
||||
noDNDShadow = false;
|
||||
noDockShadow = false;
|
||||
# shadow-radius = 20
|
||||
# '';
|
||||
# shadow-radius = 20
|
||||
# corner-radius = 10
|
||||
# blur-size = 20
|
||||
# rounded-corners-exclude = [
|
||||
# "window_type = 'dock'",
|
||||
# "class_g = 'i3-frame'"
|
||||
# ]
|
||||
# '';
|
||||
};
|
||||
fade = false;
|
||||
experimentalBackends = true;
|
||||
inactiveOpacity = 1.0;
|
||||
menuOpacity = 1.0;
|
||||
opacityRules = [
|
||||
"0:_NET_WM_STATE@[0]:32a = '_NET_WM_STATE_HIDDEN'" # Hide tabbed windows
|
||||
];
|
||||
shadow = false;
|
||||
shadowExclude = [ ];
|
||||
shadowOffsets = [ (-10) (-10) ];
|
||||
shadowOpacity = 0.5;
|
||||
vSync = true;
|
||||
services.picom = {
|
||||
enable = true;
|
||||
backend = "glx";
|
||||
settings = {
|
||||
blur = false;
|
||||
blurExclude = [ ];
|
||||
inactiveDim = "0.05";
|
||||
noDNDShadow = false;
|
||||
noDockShadow = false;
|
||||
# shadow-radius = 20
|
||||
# '';
|
||||
# shadow-radius = 20
|
||||
# corner-radius = 10
|
||||
# blur-size = 20
|
||||
# rounded-corners-exclude = [
|
||||
# "window_type = 'dock'",
|
||||
# "class_g = 'i3-frame'"
|
||||
# ]
|
||||
# '';
|
||||
};
|
||||
|
||||
xsession.windowManager.i3.config.startup = [{
|
||||
command = "systemctl --user restart picom";
|
||||
always = true;
|
||||
notification = false;
|
||||
}];
|
||||
|
||||
fade = false;
|
||||
experimentalBackends = true;
|
||||
inactiveOpacity = 1.0;
|
||||
menuOpacity = 1.0;
|
||||
opacityRules = [
|
||||
"0:_NET_WM_STATE@[0]:32a = '_NET_WM_STATE_HIDDEN'" # Hide tabbed windows
|
||||
];
|
||||
shadow = false;
|
||||
shadowExclude = [ ];
|
||||
shadowOffsets = [ (-10) (-10) ];
|
||||
shadowOpacity = 0.5;
|
||||
vSync = true;
|
||||
};
|
||||
|
||||
xsession.windowManager.i3.config.startup = [{
|
||||
command = "systemctl --user restart picom";
|
||||
always = true;
|
||||
notification = false;
|
||||
}];
|
||||
|
||||
};
|
||||
};
|
||||
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
config = lib.mkIf config.services.xserver.enable {
|
||||
|
||||
gui.toggleBarCommand = "polybar-msg cmd toggle";
|
||||
toggleBarCommand = "polybar-msg cmd toggle";
|
||||
|
||||
home-manager.users.${config.user} = {
|
||||
|
||||
@ -23,14 +23,14 @@
|
||||
# offset-y = -5;
|
||||
# offset-y = "5%";
|
||||
# dpi = 96;
|
||||
background = config.colorscheme.base01;
|
||||
foreground = config.colorscheme.base05;
|
||||
background = config.theme.colors.base01;
|
||||
foreground = config.theme.colors.base05;
|
||||
line-size = "3pt";
|
||||
border-top-size = 0;
|
||||
border-right-size = 0;
|
||||
border-left-size = 0;
|
||||
border-bottom-size = "4pt";
|
||||
border-color = config.colorscheme.base00;
|
||||
border-color = config.theme.colors.base00;
|
||||
padding-left = 2;
|
||||
padding-right = 2;
|
||||
module-margin = 1;
|
||||
@ -58,35 +58,35 @@
|
||||
fuzzy-match = true;
|
||||
format = "<label-state> <label-mode>";
|
||||
label-focused = "%name%";
|
||||
label-focused-foreground = config.colorscheme.base01;
|
||||
label-focused-background = config.colorscheme.base05;
|
||||
label-focused-underline = config.colorscheme.base03;
|
||||
label-focused-foreground = config.theme.colors.base01;
|
||||
label-focused-background = config.theme.colors.base05;
|
||||
label-focused-underline = config.theme.colors.base03;
|
||||
label-focused-padding = padding;
|
||||
label-unfocused = "%name%";
|
||||
label-unfocused-padding = padding;
|
||||
label-visible = "%name%";
|
||||
label-visible-underline = config.colorscheme.base01;
|
||||
label-visible-underline = config.theme.colors.base01;
|
||||
label-visible-padding = padding;
|
||||
label-urgent = "%name%";
|
||||
label-urgent-foreground = config.colorscheme.base00;
|
||||
label-urgent-background = config.colorscheme.base08;
|
||||
label-urgent-underline = config.colorscheme.base0F;
|
||||
label-urgent-foreground = config.theme.colors.base00;
|
||||
label-urgent-background = config.theme.colors.base08;
|
||||
label-urgent-underline = config.theme.colors.base0F;
|
||||
label-urgent-padding = padding;
|
||||
};
|
||||
"module/xworkspaces" = {
|
||||
type = "internal/xworkspaces";
|
||||
label-active = "%name%";
|
||||
label-active-background = config.colorscheme.base05;
|
||||
label-active-foreground = config.colorscheme.base01;
|
||||
label-active-underline = config.colorscheme.base03;
|
||||
label-active-background = config.theme.colors.base05;
|
||||
label-active-foreground = config.theme.colors.base01;
|
||||
label-active-underline = config.theme.colors.base03;
|
||||
label-active-padding = 1;
|
||||
label-occupied = "%name%";
|
||||
label-occupied-padding = 1;
|
||||
label-urgent = "%name%";
|
||||
label-urgent-background = config.colorscheme.base08;
|
||||
label-urgent-background = config.theme.colors.base08;
|
||||
label-urgent-padding = 1;
|
||||
label-empty = "%name%";
|
||||
label-empty-foreground = config.colorscheme.base06;
|
||||
label-empty-foreground = config.theme.colors.base06;
|
||||
label-empty-padding = 1;
|
||||
};
|
||||
"module/xwindow" = {
|
||||
@ -108,10 +108,10 @@
|
||||
format-volume = "<ramp-volume> <label-volume>";
|
||||
# format-volume-background = colors.background;
|
||||
# label-volume-background = colors.background;
|
||||
format-volume-foreground = config.colorscheme.base0B;
|
||||
format-volume-foreground = config.theme.colors.base0B;
|
||||
label-volume = "%percentage%%";
|
||||
label-muted = "ﱝ ---";
|
||||
label-muted-foreground = config.colorscheme.base03;
|
||||
label-muted-foreground = config.theme.colors.base03;
|
||||
ramp-volume-0 = "";
|
||||
ramp-volume-1 = "墳";
|
||||
ramp-volume-2 = "";
|
||||
@ -163,7 +163,7 @@
|
||||
date = "%d %b %l:%M %p";
|
||||
date-alt = "%Y-%m-%d %H:%M:%S";
|
||||
label = "%date%";
|
||||
label-foreground = config.colorscheme.base0A;
|
||||
label-foreground = config.theme.colors.base0A;
|
||||
# format-background = colors.background;
|
||||
};
|
||||
"settings" = {
|
||||
|
@ -25,19 +25,19 @@
|
||||
# Inspired by https://github.com/sherubthakur/dotfiles/blob/master/users/modules/desktop-environment/rofi/launcher.rasi
|
||||
|
||||
"*" = {
|
||||
background-color = mkLiteral config.colorscheme.base00;
|
||||
foreground-color = mkLiteral config.colorscheme.base07;
|
||||
text-color = mkLiteral config.colorscheme.base07;
|
||||
border-color = mkLiteral config.colorscheme.base04;
|
||||
background-color = mkLiteral config.theme.colors.base00;
|
||||
foreground-color = mkLiteral config.theme.colors.base07;
|
||||
text-color = mkLiteral config.theme.colors.base07;
|
||||
border-color = mkLiteral config.theme.colors.base04;
|
||||
};
|
||||
|
||||
# Holds the entire window
|
||||
"#window" = {
|
||||
transparency = "real";
|
||||
background-color = mkLiteral config.colorscheme.base00;
|
||||
text-color = mkLiteral config.colorscheme.base07;
|
||||
background-color = mkLiteral config.theme.colors.base00;
|
||||
text-color = mkLiteral config.theme.colors.base07;
|
||||
border = mkLiteral "4px";
|
||||
border-color = mkLiteral config.colorscheme.base04;
|
||||
border-color = mkLiteral config.theme.colors.base04;
|
||||
border-radius = mkLiteral "4px";
|
||||
width = mkLiteral "850px";
|
||||
padding = mkLiteral "15px";
|
||||
@ -45,10 +45,10 @@
|
||||
|
||||
# Wrapper around bar and results
|
||||
"#mainbox" = {
|
||||
background-color = mkLiteral config.colorscheme.base00;
|
||||
background-color = mkLiteral config.theme.colors.base00;
|
||||
border = mkLiteral "0px";
|
||||
border-radius = mkLiteral "0px";
|
||||
border-color = mkLiteral config.colorscheme.base04;
|
||||
border-color = mkLiteral config.theme.colors.base04;
|
||||
children = map mkLiteral [ "inputbar" "listview" ];
|
||||
spacing = mkLiteral "10px";
|
||||
padding = mkLiteral "10px";
|
||||
@ -59,7 +59,7 @@
|
||||
expand = false;
|
||||
str = ":";
|
||||
margin = mkLiteral "0px 0.3em 0em 0em";
|
||||
text-color = mkLiteral config.colorscheme.base07;
|
||||
text-color = mkLiteral config.theme.colors.base07;
|
||||
};
|
||||
|
||||
# Command prompt left of the input
|
||||
@ -67,7 +67,7 @@
|
||||
|
||||
# Actual text box
|
||||
"#entry" = {
|
||||
placeholder-color = mkLiteral config.colorscheme.base03;
|
||||
placeholder-color = mkLiteral config.theme.colors.base03;
|
||||
expand = true;
|
||||
horizontal-align = "0";
|
||||
placeholder = "Launch Program";
|
||||
@ -85,7 +85,7 @@
|
||||
|
||||
# Results
|
||||
"#listview" = {
|
||||
background-color = mkLiteral config.colorscheme.base00;
|
||||
background-color = mkLiteral config.theme.colors.base00;
|
||||
padding = mkLiteral "0px";
|
||||
columns = 1;
|
||||
lines = 12;
|
||||
@ -104,9 +104,9 @@
|
||||
"#element.selected" = {
|
||||
border = mkLiteral "1px";
|
||||
border-radius = mkLiteral "4px";
|
||||
border-color = mkLiteral config.colorscheme.base07;
|
||||
background-color = mkLiteral config.colorscheme.base04;
|
||||
text-color = mkLiteral config.colorscheme.base00;
|
||||
border-color = mkLiteral config.theme.colors.base07;
|
||||
background-color = mkLiteral config.theme.colors.base04;
|
||||
text-color = mkLiteral config.theme.colors.base00;
|
||||
};
|
||||
|
||||
"#element-text" = {
|
||||
@ -116,8 +116,8 @@
|
||||
margin = mkLiteral "0px 2.5px 0px 2.5px";
|
||||
};
|
||||
"#element-text.selected" = {
|
||||
background-color = mkLiteral config.colorscheme.base04;
|
||||
text-color = mkLiteral config.colorscheme.base00;
|
||||
background-color = mkLiteral config.theme.colors.base04;
|
||||
text-color = mkLiteral config.theme.colors.base00;
|
||||
};
|
||||
|
||||
# Not sure how to get icons
|
||||
@ -125,11 +125,11 @@
|
||||
size = mkLiteral "18px";
|
||||
border = mkLiteral "0px";
|
||||
padding = mkLiteral "2px 5px 2px 2px";
|
||||
background-color = mkLiteral config.colorscheme.base00;
|
||||
background-color = mkLiteral config.theme.colors.base00;
|
||||
};
|
||||
"#element-icon.selected" = {
|
||||
background-color = mkLiteral config.colorscheme.base04;
|
||||
text-color = mkLiteral config.colorscheme.base00;
|
||||
background-color = mkLiteral config.theme.colors.base04;
|
||||
text-color = mkLiteral config.theme.colors.base00;
|
||||
};
|
||||
|
||||
};
|
||||
@ -144,9 +144,9 @@
|
||||
|
||||
};
|
||||
|
||||
gui.launcherCommand = "${pkgs.rofi}/bin/rofi -show run -modi run";
|
||||
gui.systemdSearch = "${pkgs.rofi-systemd}/bin/rofi-systemd";
|
||||
gui.altTabCommand = "${pkgs.rofi}/bin/rofi -show window -modi window";
|
||||
launcherCommand = "${pkgs.rofi}/bin/rofi -show run -modi run";
|
||||
systemdSearch = "${pkgs.rofi-systemd}/bin/rofi-systemd";
|
||||
altTabCommand = "${pkgs.rofi}/bin/rofi -show window -modi window";
|
||||
|
||||
};
|
||||
|
||||
|
@ -1,15 +1,25 @@
|
||||
{ config, pkgs, lib, ... }:
|
||||
{ config, pkgs, lib, ... }: {
|
||||
|
||||
let
|
||||
|
||||
gtkTheme = {
|
||||
name = config.gui.gtk.theme.name;
|
||||
package = pkgs.${config.gui.gtk.theme.package};
|
||||
options = {
|
||||
gtk.theme = {
|
||||
name = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
description = "Theme name for GTK applications";
|
||||
};
|
||||
package = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
description = "Theme package name for GTK applications";
|
||||
default = "gnome-themes-extra";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
in {
|
||||
|
||||
config = lib.mkIf config.gui.enable {
|
||||
config = let
|
||||
gtkTheme = {
|
||||
name = config.gtk.theme.name;
|
||||
package = pkgs."${config.gtk.theme.package}";
|
||||
};
|
||||
in lib.mkIf config.gui.enable {
|
||||
|
||||
# Enable the X11 windowing system.
|
||||
services.xserver = {
|
||||
@ -22,7 +32,7 @@ in {
|
||||
displayManager = {
|
||||
lightdm = {
|
||||
enable = config.services.xserver.enable;
|
||||
background = config.gui.wallpaper;
|
||||
background = config.wallpaper;
|
||||
|
||||
# Make the login screen dark
|
||||
greeters.gtk.theme = gtkTheme;
|
||||
@ -46,7 +56,7 @@ in {
|
||||
services.dbus.packages = [ pkgs.dconf ];
|
||||
programs.dconf.enable = true;
|
||||
|
||||
environment.sessionVariables = { GTK_THEME = config.gui.gtk.theme.name; };
|
||||
environment.sessionVariables = { GTK_THEME = config.gtk.theme.name; };
|
||||
|
||||
home-manager.users.${config.user} = {
|
||||
|
||||
@ -55,7 +65,10 @@ in {
|
||||
pbpaste = "xclip -selection clipboard -out";
|
||||
};
|
||||
|
||||
gtk = let gtkExtraConfig = { gtk-application-prefer-dark-theme = true; };
|
||||
gtk = let
|
||||
gtkExtraConfig = {
|
||||
gtk-application-prefer-dark-theme = config.theme.dark;
|
||||
};
|
||||
in {
|
||||
enable = true;
|
||||
theme = gtkTheme;
|
||||
|
@ -15,7 +15,12 @@
|
||||
source = ./lua;
|
||||
recursive = true; # Allows adding more files
|
||||
};
|
||||
"nvim/lua/packer/colors.lua".source = config.colorscheme.neovimConfig;
|
||||
"nvim/lua/packer/colors.lua".source = config.theme.colors.neovimConfig;
|
||||
"nvim/lua/background.lua".text = ''
|
||||
vim.cmd("set background=${
|
||||
if config.theme.dark == true then "dark" else "light"
|
||||
}")
|
||||
'';
|
||||
};
|
||||
|
||||
programs.git.extraConfig.core.editor = "nvim";
|
||||
|
@ -1,3 +1,4 @@
|
||||
require("packer_init")
|
||||
require("settings")
|
||||
require("keybinds")
|
||||
require("background")
|
||||
|
Loading…
Reference in New Issue
Block a user