nixos-config/modules/themes/fair-and-square/default.nix

117 lines
3.0 KiB
Nix
Raw Normal View History

2020-08-16 08:33:44 +00:00
{ config, options, lib, pkgs, ... }:
2020-10-25 15:49:14 +00:00
with lib; {
2020-08-16 08:33:44 +00:00
options.modules.themes."fair-and-square" = {
enable = mkOption {
type = types.bool;
default = false;
};
};
config = mkIf config.modules.themes."fair-and-square".enable {
services = {
2020-10-06 22:24:55 +00:00
# Enable picom compositor.
2020-08-16 08:33:44 +00:00
picom = {
enable = true;
fade = false;
shadow = false;
};
2020-10-06 22:24:55 +00:00
# Enable certain Xorg-related services.
2020-08-16 08:33:44 +00:00
xserver = {
displayManager = {
lightdm.enable = true;
defaultSession = "none+bspwm";
};
enable = true;
libinput.enable = true;
windowManager.bspwm.enable = true;
};
};
my.env.TERMINAL = "alacritty";
2020-08-16 08:33:44 +00:00
my.home = {
2020-10-06 22:24:55 +00:00
# Enable GTK configuration.
gtk.enable = true;
2020-10-20 15:56:10 +00:00
# Set the wallpaper.
home.file.".background-image".source = ./config/wallpaper;
2020-10-06 22:24:55 +00:00
# Enable QT configuration and set it to the same GTK config.
qt.enable = true;
qt.platformTheme = "gtk";
2020-08-16 08:33:44 +00:00
# Install all of the configurations in the XDG config home.
xdg.configFile = mkMerge [
2020-10-25 15:49:14 +00:00
(let
recursiveXdgConfig = name: {
source = ./config + "/${name}";
recursive = true;
};
in {
2020-08-16 08:33:44 +00:00
"alacritty" = recursiveXdgConfig "alacritty";
"bspwm" = recursiveXdgConfig "bspwm";
"dunst" = recursiveXdgConfig "dunst";
"polybar" = recursiveXdgConfig "polybar";
"rofi" = recursiveXdgConfig "rofi";
"sxhkd" = {
source = <config/sxhkd>;
recursive = true;
};
})
2020-10-06 22:24:55 +00:00
# Applying the theme for GTK.
({
2020-08-16 08:33:44 +00:00
"gtk-3.0/settings.ini".text = ''
[Settings]
2020-08-16 08:33:44 +00:00
gtk-theme-name=Arc
gtk-icon-theme-name=Arc
gtk-fallback-icon-theme=gnome
gtk-application-prefer-dark-theme=true
gtk-cursor-theme-name=Adwaita
gtk-xft-hinting=1
gtk-xft-hintstyle=hintfull
gtk-xft-rgba=none
'';
2020-10-06 22:24:55 +00:00
"gtk-2.0/gtkrc".text = ''
gtk-theme-name="Arc"
gtk-icon-theme-name="Arc"
gtk-font-name="Sans 10"
gtk-cursor-theme-name="Adwaita"
'';
})
2020-08-16 08:33:44 +00:00
];
2020-10-20 15:56:10 +00:00
# Set the cursor theme.
xdg.dataFile = {
"icons/default/index.theme".text = ''
[icon theme]
Inherits=Adwaita
'';
};
2020-08-16 08:33:44 +00:00
};
my.packages = with pkgs; [
2020-10-25 15:49:14 +00:00
alacritty # Muh GPU-accelerated terminal emulator.
dunst # Add more annoying pop-ups on your screen!
feh # Meh, it's a image viewer that can set desktop background, what gives?
2020-08-16 08:33:44 +00:00
gnome3.adwaita-icon-theme
2020-10-25 15:49:14 +00:00
libnotify # Library for yer notifications.
2020-08-16 08:33:44 +00:00
(polybar.override {
pulseSupport = true;
nlSupport = true;
2020-10-25 15:49:14 +00:00
}) # Add some bars to your magnum opus.
rofi # A ricer's best friend (one of them at least).
2020-08-16 08:33:44 +00:00
# The Arc theme
arc-icon-theme
arc-theme
];
2020-10-25 15:49:14 +00:00
fonts.fonts = with pkgs; [ iosevka font-awesome-ttf ];
2020-08-16 08:33:44 +00:00
};
}