Merge branch 'main' of antimatterForge:Egg/voidconf

yes yes... I don't pay enough attention
This commit is contained in:
Nox Sluijtman 2024-05-13 11:51:40 +02:00
commit 10258a52b3
12 changed files with 69 additions and 64 deletions

View file

@ -9,7 +9,7 @@
./modules/audio.nix ./modules/audio.nix
./modules/font.nix ./modules/font.nix
./modules/nix-settings.nix ./modules/nix-settings.nix
./modules/nvidia.nix ./modules/graphics.nix
./modules/services.nix ./modules/services.nix
./modules/vim.nix ./modules/vim.nix
./modules/xconfig.nix ./modules/xconfig.nix

View file

@ -1,8 +1,8 @@
{ lib, config, ... }: { lib, config, ... }:
with lib; with lib;
let cfg = config.voidcruiser.audio; let cfg = config.voidconf.audio;
in { in {
options.voidcruiser.audio = { options.voidconf.audio = {
enable = mkEnableOption "Enable all the audio daemons"; enable = mkEnableOption "Enable all the audio daemons";
}; };
config = mkIf cfg.enable { config = mkIf cfg.enable {

View file

@ -1,8 +1,8 @@
{ pkgs, config, lib, ... }: { pkgs, config, lib, ... }:
with lib; with lib;
let cfg = config.voidcruiser.fontConfig; let cfg = config.voidconf.fontConfig;
in { in {
options.voidcruiser.fontConfig = { options.voidconf.fontConfig = {
enable = mkEnableOption "Enable opinionated font configuration"; enable = mkEnableOption "Enable opinionated font configuration";
joyPixels = mkEnableOption "Enables the JoyPixels font"; joyPixels = mkEnableOption "Enables the JoyPixels font";
}; };
@ -11,24 +11,25 @@ in {
fontDir.enable = true; fontDir.enable = true;
packages = with pkgs; [ packages = with pkgs; [
(nerdfonts.override { fonts = [ "FiraCode" "Iosevka" ]; }) (nerdfonts.override { fonts = [ "FiraCode" "Iosevka" ]; })
jetbrains-mono ubuntu_font_family
iosevka jetbrains-mono
fira-code iosevka
fira fira-code
font-awesome fira
liberation_ttf font-awesome
libertine liberation_ttf
libertinus libertine
vollkorn libertinus
noto-fonts-emoji vollkorn
noto-fonts noto-fonts-emoji
ipafont noto-fonts
bqn386 ipafont
blackout bqn386
prociono blackout
mplus-outline-fonts.githubRelease prociono
mononoki mplus-outline-fonts.githubRelease
uiua386 mononoki
uiua386
]; ];
fontconfig = { fontconfig = {
enable = true; enable = true;

31
modules/graphics.nix Normal file
View file

@ -0,0 +1,31 @@
{ lib, config, ... }:
with lib;
let cfg = config.voidconf.graphics;
in {
options.voidconf.graphics ={
defaultSettings.enable = mkEnableOption "Enables some basic graphical settings";
nvidia = {
enable = mkEnableOption "Enables Nvidia settings";
proprietaryDrivers = mkEnableOption "Enables proprietary drivers";
};
};
config = {
hardware = {
opengl = {
enable = true;
driSupport = true;
driSupport32Bit = true;
};
nvidia = mkIf cfg.nvidia.enable {
package = config.boot.kernelPackages.nvidiaPackages.stable;
powerManagement = {
enable = false;
finegrained = false;
};
open = !cfg.nvidia.proprietaryDrivers;
nvidiaSettings = cfg.nvidia.proprietaryDrivers;
};
};
services.xserver.videoDrivers = mkIf cfg.nvidia.proprietaryDrivers ["nvidia"];
};
}

View file

@ -1,8 +1,8 @@
{ lib, config, ... }: { lib, config, ... }:
with lib; with lib;
let cfg = config.voidcruiser.kernelTweaks; let cfg = config.voidconf.kernelTweaks;
in { in {
options.voidcruiser.kernelTweaks = { options.voidconf.kernelTweaks = {
enable = mkEnableOption "Enables kernel tweaks"; enable = mkEnableOption "Enables kernel tweaks";
}; };
config = mkIf cfg.enable { config = mkIf cfg.enable {

View file

@ -1,8 +1,8 @@
{ lib, config, ... }: { lib, config, ... }:
with lib; with lib;
let cfg = config.voidcruiser.nixSettings; let cfg = config.voidconf.nixSettings;
in { in {
options.voidcruiser.nixSettings = { options.voidconf.nixSettings = {
gc = { gc = {
automatic = mkOption { automatic = mkOption {
type = types.bool; type = types.bool;

View file

@ -1,27 +0,0 @@
{ lib, config, ... }:
with lib;
let cfg = config.voidcruiser.nvidia;
in {
options.voidcruiser.nvidia = {
enable = mkEnableOption "Enables proprietary Nvidia drivers and related config";
};
config = mkIf cfg.enable {
hardware = {
opengl = {
enable = true;
driSupport = true;
driSupport32Bit = true;
};
nvidia = {
package = config.boot.kernelPackages.nvidiaPackages.stable;
powerManagement = {
enable = false;
finegrained = false;
};
open = false;
nvidiaSettings = true;
};
};
services.xserver.videoDrivers = ["nvidia"];
};
}

View file

@ -1,8 +1,8 @@
{ lib, config, ... }: { lib, config, ... }:
with lib; with lib;
let cfg = config.voidcruiser.prometheus; let cfg = config.voidconf.prometheus;
in { in {
options.voidcruiser.prometheus = { options.voidconf.prometheus = {
enable = mkEnableOption "Enable prometheus node"; enable = mkEnableOption "Enable prometheus node";
}; };
config = mkIf cfg.enable { config = mkIf cfg.enable {

View file

@ -1,8 +1,8 @@
{ config, lib, pkgs, ... }: { config, lib, pkgs, ... }:
with lib; with lib;
let cfg = config.voidcruiser.services; let cfg = config.voidconf.services;
in { in {
options.voidcruiser.services = { options.voidconf.services = {
flatpak = { flatpak = {
enable = mkEnableOption "Enables basic flatpak configuration"; enable = mkEnableOption "Enables basic flatpak configuration";

View file

@ -1,8 +1,8 @@
{ config, lib, pkgs, ... }: { config, lib, pkgs, ... }:
with lib; with lib;
let cfg = config.voidcruiser.vim; let cfg = config.voidconf.vim;
in { in {
options.voidcruiser.vim = { options.voidconf.vim = {
enable = mkEnableOption "Enables opinionated vim configuration"; enable = mkEnableOption "Enables opinionated vim configuration";
enableNvim = mkEnableOption "Enables neovim and alias"; enableNvim = mkEnableOption "Enables neovim and alias";
setEnvVar = mkOption { setEnvVar = mkOption {

View file

@ -1,8 +1,8 @@
{ config, lib, ... }: { config, lib, ... }:
with lib; with lib;
let cfg = config.voidcruiser.xconfig; let cfg = config.voidconf.xconfig;
in { in {
options.voidcruiser.xconfig = { options.voidconf.xconfig = {
enable = mkEnableOption "Enables opinionated xorg config"; enable = mkEnableOption "Enables opinionated xorg config";

View file

@ -1,8 +1,8 @@
{ config, lib, ... }: { config, lib, ... }:
with lib; with lib;
let cfg = config.voidcruiser.zsh; let cfg = config.voidconf.zsh;
in { in {
options.voidcruiser.zsh = { options.voidconf.zsh = {
enable = mkEnableOption "Enables opinionated zsh configuration"; enable = mkEnableOption "Enables opinionated zsh configuration";
skim.enable = mkEnableOption "Enables skim support for shell history"; skim.enable = mkEnableOption "Enables skim support for shell history";
highlightStyle = mkOption { highlightStyle = mkOption {