formated whole config with alejandra

This commit is contained in:
Tomas Rivera
2026-03-08 19:02:23 +01:00
parent 0564b1d418
commit 5be7198efe
52 changed files with 3724 additions and 3623 deletions
+9 -4
View File
@@ -16,16 +16,21 @@
# url = "github:nix-community/nixvim/nixos-25.11";
# };
outputs = { self, nixpkgs, nixpkgs-unstable, home-manager, nixos-grub-themes, ... }@inputs:
let
outputs = {
self,
nixpkgs,
nixpkgs-unstable,
home-manager,
nixos-grub-themes,
...
} @ inputs: let
system = "x86_64-linux";
pkgs = nixpkgs.legacyPackages.${system};
pkgs-unstable = import nixpkgs-unstable {
inherit system;
config.allowUnfree = false;
};
in
{
in {
nixosConfigurations = {
laptop = nixpkgs.lib.nixosSystem {
specialArgs = {inherit inputs pkgs-unstable;};
+10 -15
View File
@@ -1,11 +1,16 @@
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help).
{ config, pkgs, pkgs-unstable, libs, inputs, ... }:
{
imports =
[ # Include the results of the hardware scan.
config,
pkgs,
pkgs-unstable,
libs,
inputs,
...
}: {
imports = [
# Include the results of the hardware scan.
./hardware-configuration.nix
inputs.home-manager.nixosModules.default
../../modules/nixos/battery.nix
@@ -15,7 +20,6 @@
../../modules/nixos/udevsimple.nix
];
documentation.man.generateCaches = true; # used for the man script
# grub theme
@@ -23,14 +27,11 @@ boot.loader.grub = {
theme = inputs.nixos-grub-themes.packages.${pkgs.system}.nixos; # if you want to use nixos grub theme
};
nix.nixPath = [
"nixpkgs=${inputs.nixpkgs.outPath}"
"home-manager=${inputs.home-manager.outPath}"
]; #manix is unhappy without this
home-manager = {
useGlobalPkgs = true;
useUserPackages = true;
@@ -40,7 +41,6 @@ home-manager = {
extraSpecialArgs = {inherit pkgs-unstable;};
};
environment.pathsToLink = [
"/share/applications"
"/share/xdg-desktop-portal"
@@ -84,7 +84,6 @@ services.xserver.excludePackages = [ pkgs.xterm ];
#};
# we use ly as the displayManager. see ../../modules/nixos/ly.nix
# enable hyprland WM
programs.hyprland = {
enable = true;
@@ -93,8 +92,6 @@ programs.hyprland = {
xwayland.enable = true;
};
services.upower.enable = true;
# Configure keymap in X11
@@ -139,7 +136,6 @@ services.upower.enable = true;
#adds nixos experimental features:
nix.settings.experimental-features = ["nix-command" "flakes"];
# Garbage collector of generations
nix.gc = {
automatic = true;
@@ -153,7 +149,6 @@ services.upower.enable = true;
# Allow unfree packages
nixpkgs.config.allowUnfree = false;
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
@@ -212,6 +207,7 @@ framework-tool-tui
#some nix tools
manix
deadnix
alejandra
];
# fonts
@@ -245,5 +241,4 @@ nerd-fonts._0xproto
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "25.11"; # Did you read the comment?
}
+12 -8
View File
@@ -1,11 +1,15 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{
imports =
[ (modulesPath + "/installer/scan/not-detected.nix")
config,
lib,
pkgs,
modulesPath,
...
}: {
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "thunderbolt" "usb_storage" "usbhid" "sd_mod"];
@@ -13,13 +17,13 @@
boot.kernelModules = ["kvm-amd"];
boot.extraModulePackages = [];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/6aa664c2-8b23-4e20-b6e9-1806bf0f8df2";
fileSystems."/" = {
device = "/dev/disk/by-uuid/6aa664c2-8b23-4e20-b6e9-1806bf0f8df2";
fsType = "ext4";
};
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/A59A-7AFA";
fileSystems."/boot" = {
device = "/dev/disk/by-uuid/A59A-7AFA";
fsType = "vfat";
options = ["fmask=0077" "dmask=0077"];
};
+5 -9
View File
@@ -1,6 +1,9 @@
{ config, pkgs, inputs, ... }:
{
config,
pkgs,
inputs,
...
}: {
# every import imports a specific module for an app. This module contains the enabling of this app and its settings.
# So if you want to add an home-manager app create a module which enables it and configures it and import it.
imports = [
@@ -29,9 +32,6 @@ imports = [
../../modules/home-manager/ripgrep.nix # better grep
];
#programs.nixvim = {
# enable = true;
# imports = [ ../../modules/nixvim/neovim.nix ];
@@ -116,8 +116,6 @@ Host *
IdentityFile ~/.ssh/id_ed25519
'';
# Home Manager is pretty good at managing dotfiles. The primary way to manage
# plain files is through 'home.file'.
home.file = {
@@ -133,7 +131,6 @@ home.file = {
# '';
};
# Home Manager can also manage your environment variables through
# 'home.sessionVariables'. These will be explicitly sourced when using a
# shell provided by Home Manager. If you don't want to manage your shell
@@ -157,7 +154,6 @@ home.sessionVariables = {
TERMINAL = "kitty";
};
# Let Home Manager install and manage itself.
programs.home-manager.enable = true;
}
+4 -1
View File
@@ -1,5 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
programs.anki = {
# we enable system wide with nixpkgs because it offers some addon configuration. We just use this for some config
#enable = true;
+4 -2
View File
@@ -1,6 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
services.batsignal = {
enable = true;
};
+4 -1
View File
@@ -1,5 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
home.pointerCursor = {
hyprcursor.enable = true;
enable = true;
+4 -3
View File
@@ -1,6 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
# Adapted from https://github.com/dacrab/fastfetch-config/blob/main/config.jsonc
programs.fastfetch = {
enable = true;
@@ -12,7 +14,6 @@
};
modules = [
# ───────────── Hardware ─────────────
{
+4 -2
View File
@@ -1,6 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
programs.git = {
enable = true;
settings = {
+4 -3
View File
@@ -1,7 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
services.hypridle = {
enable = true;
settings = {
+7 -15
View File
@@ -1,11 +1,11 @@
{ config, pkgs, pkgs-unstable, ... }:
let
wallpaper = ../../assets/wallpaper1.jpg;
in
{
config,
pkgs,
pkgs-unstable,
...
}: let
wallpaper = ../../assets/wallpaper1.jpg;
in {
#refer to https://wiki.hypr.land/Nix/Hyprland-on-Home-Manager/
wayland.windowManager.hyprland.enable = true;
wayland.windowManager.hyprland.package = pkgs-unstable.hyprland;
@@ -156,7 +156,6 @@ in
#plugins keybindings
#"$mod, SPACE, overview:toggle, "
];
binde = [
"$mod+Shift, Right, resizeactive, 30 0"
@@ -222,7 +221,6 @@ in
"3, left, move, -col"
];
# █░░ ▄▀█ █▄█ █▀█ █░█ ▀█▀ █▀
# █▄▄ █▀█ ░█░ █▄█ █▄█ ░█░ ▄█
@@ -323,8 +321,6 @@ in
"col.inactive_border" = "rgba(f1dca7d9) rgba(ffe1a8d9) 45deg";
layout = "dwindle";
resize_on_border = true;
};
group = {
"col.border_active" = "rgba(ca6702ff) rgba(ecd3a0ff) 45deg";
@@ -356,8 +352,6 @@ in
"f[1], gapsout:0, gapsin:0"
];
# █░█░█ █ █▄░█ █▀▄ █▀█ █░█░█   █▀█ █░█ █░░ █▀▀ █▀
# ▀▄▀▄▀ █ █░▀█ █▄▀ █▄█ ▀▄▀▄▀   █▀▄ █▄█ █▄▄ ██▄ ▄█
windowrule = [
@@ -432,5 +426,3 @@ layerrule = [
];
};
}
+4 -2
View File
@@ -1,6 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
programs.kitty = {
enable = true;
#font.name = nerd-fonts._0xproto;
+4 -4
View File
@@ -1,6 +1,9 @@
# adapted from https://github.com/contre95/dotfiles/blob/main/dotfiles/nixos/programs/librewolf.nix
{ pkgs, config, ... }:
{
pkgs,
config,
...
}: {
home.sessionVariables = {
MOZ_ENABLE_WAYLAND = 1;
MOZ_USE_XINPUT2 = 1;
@@ -114,7 +117,6 @@
# "browser.fixup.domainwhitelist.internal.contre.io" = true;
"extensions.activeThemeID" = "firefox-compact-dark@mozilla.org";
# "keyword.enable" = false; # Disable search when typing unexistent TLD
};
policies = {
ExtensionSettings = {
@@ -595,8 +597,6 @@
};
};
};
};
};
}
+4 -2
View File
@@ -1,6 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
programs.neovim = {
enable = true;
vimAlias = true;
+5 -2
View File
@@ -1,8 +1,11 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}:
# same as ./neovim.nix but you vim plug.
# i tried importing my nvim config from fedora to a more nixy way but a lot of settings and plugins didnt work. Maybe i'll fix it latter
# the only difference is the we use :PlugInstall or a similar command before doing anything
{
programs.neovim = {
enable = true;
+4 -2
View File
@@ -1,6 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
programs.oh-my-posh = {
enable = true;
enableZshIntegration = true;
+4 -2
View File
@@ -1,6 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
programs.zsh.oh-my-zsh = {
enable = true;
theme = "jonathan";
+5 -2
View File
@@ -1,6 +1,9 @@
{ config, pkgs, agenix, ... }:
{
config,
pkgs,
agenix,
...
}: {
programs.rclone = {
enable = true;
};
+4 -3
View File
@@ -1,6 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
programs.ripgrep = {
enable = true;
arguments = [
@@ -13,5 +15,4 @@
programs.ripgrep-all = {
enable = true;
};
}
+4 -2
View File
@@ -1,6 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
programs.rofi = {
enable = true;
theme = "gruvbox-dark-hard";
+17 -7
View File
@@ -1,13 +1,23 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
programs.ssh = {
enable = true;
#agentKeys = [
# "/home/tomasr/.ssh/id_ed25519"
#];
matchBlocks."*" = {
# equivalent to the default config
forwardAgent = false;
addKeysToAgent = "no";
compression = false;
serverAliveInterval = 0;
serverAliveCountMax = 3;
hashKnownHosts = false;
userKnownHostsFile = "~/.ssh/known_hosts";
controlMaster = "no";
controlPath = "~/.ssh/master-%r@%n:%p";
controlPersist = "no";
};
};
services.ssh-agent.enable = true;
}
+4 -2
View File
@@ -1,6 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
programs.swaylock = {
enable = true;
settings = {
+4 -2
View File
@@ -1,6 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
services.swaync = {
enable = true;
};
+4 -3
View File
@@ -1,7 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
programs.waybar = {
enable = true;
settings = [
+6 -4
View File
@@ -1,5 +1,8 @@
{ config, pkgs, ... }:
let
{
config,
pkgs,
...
}: let
wallpaper = ../../assets/wallpaper1.jpg;
lock = ../../assets/lock.png;
lock-hover = ../../assets/lock-hover.png;
@@ -9,8 +12,7 @@ let
logout-hover = ../../assets/logout-hover.png;
reboot = ../../assets/restart.png;
reboot-hover = ../../assets/restart-hover.png;
in
{
in {
programs.wlogout = {
enable = true;
layout = [
+4 -2
View File
@@ -1,6 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
programs.zoxide = {
enable = true;
enableZshIntegration = true;
+5 -4
View File
@@ -1,6 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
programs.zsh = {
enable = true;
autosuggestion.enable = true;
@@ -14,8 +16,7 @@ custom-cat() {
fi
}
fastfetch''\n''
;
fastfetch''\n'';
shellAliases = {
".." = "z ..";
grep = "rg";
+4 -3
View File
@@ -1,6 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
environment.systemPackages = with pkgs; [
(pkgs.anki.withAddons [
(pkgs.ankiAddons.recolor.withConfig {
@@ -52,5 +54,4 @@
})
])
];
}
+1 -6
View File
@@ -1,13 +1,8 @@
# https://discourse.nixos.org/t/what-is-the-best-option-for-power-management/63406/2
{
...
}:
{...}:
# we just activate tlp unconditonally
#let
# cfg = config.custom;
#hasBattery =
# lib.any (x: lib.strings.hasPrefix "BAT" x)
# (builtins.attrNames (builtins.readDir "/sys/class/power_supply"));
+1 -3
View File
@@ -1,6 +1,4 @@
{ ...}:
{
{...}: {
services.displayManager.ly = {
enable = true;
settings = {
+1 -2
View File
@@ -1,5 +1,4 @@
{... }:
{
{...}: {
# a minimal ly config as the big config (ly.nix) didnt worked
services.displayManager.ly = {
enable = true;
+4 -2
View File
@@ -1,6 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
# udev are setup for controlling the framework 16 laptop's keyboard
services.udev.extraRules = ''
## https://github.com/qmk/qmk_firmware/blob/master/util/udev/50-qmk.extraRules
+4 -2
View File
@@ -1,6 +1,8 @@
{ config, pkgs, ... }:
{
config,
pkgs,
...
}: {
# udev with only the necessary rules. See udev.nix to get all the rules
services.udev.extraRules = ''
# adapted from here https://wiki.nixos.org/wiki/Keychron_M6
@@ -1,8 +1,8 @@
{ writeShellApplication
, libnotify
, systemd
{
writeShellApplication,
libnotify,
systemd,
}:
writeShellApplication {
name = "custom-olddeprecatedbatterynotify";
+6 -2
View File
@@ -1,6 +1,10 @@
# taken and adapted https://github.com/miniMinn24/Battery_Notify with MIT License
{ writeShellApplication, mplayer, brightnessctl, ... }:
let
{
writeShellApplication,
mplayer,
brightnessctl,
...
}: let
NotifySound = ../../assets/battery_notify.mp3;
in
writeShellApplication {
+6 -2
View File
@@ -1,6 +1,10 @@
# taken and adapted https://github.com/miniMinn24/Battery_Notify with MIT License
{ writeShellApplication, mplayer, brightnessctl, ... }:
let
{
writeShellApplication,
mplayer,
brightnessctl,
...
}: let
NotifySound = ../../assets/battery_notify.mp3;
in
writeShellApplication {
+6 -2
View File
@@ -1,5 +1,9 @@
{ writeShellApplication, kitty, bottom,... }:
{
writeShellApplication,
kitty,
bottom,
...
}:
writeShellApplication {
name = "custom-bottom";
runtimeInputs = [
+8 -5
View File
@@ -1,13 +1,16 @@
# useless
# used to come from my old dotfiles which were copied from fedora-hyprdots
# just use hyprpicker | tee >(wl-copy) | cliphist store
# because hyprpicker and cliphist are inside my configuration.nix
# no need to verify their existence
{ writeShellApplication, hyprpicker, libnotify, toybox, wl-clipboard, ... }:
{
writeShellApplication,
hyprpicker,
libnotify,
toybox,
wl-clipboard,
...
}:
writeShellApplication {
name = "custom-colorpicker-useless";
runtimeInputs = [
+5 -2
View File
@@ -1,5 +1,8 @@
{ writeShellApplication, cowsay, ... }:
{
writeShellApplication,
cowsay,
...
}:
writeShellApplication {
name = "custom-cowsay";
runtimeInputs = [cowsay];
+6 -2
View File
@@ -1,5 +1,9 @@
{ writeShellApplication, hyprland, jq, ...}:
{
writeShellApplication,
hyprland,
jq,
...
}:
writeShellApplication {
name = "custom-dontkillsteam";
runtimeInputs = [
+6 -2
View File
@@ -1,5 +1,9 @@
{ writeShellApplication, git, libnotify, ... }:
{
writeShellApplication,
git,
libnotify,
...
}:
writeShellApplication {
name = "custom-gitnotify";
runtimeInputs = [
+6 -2
View File
@@ -1,5 +1,9 @@
{ writeShellApplication, hyprland, jq, ... }:
{
writeShellApplication,
hyprland,
jq,
...
}:
writeShellApplication {
name = "custom-killall";
runtimeInputs = [
+5 -3
View File
@@ -1,7 +1,9 @@
# used for the terminal autostart. Needs to get cleared and recall fastfetch so that the bar from oh-my-zsh get resized
{ writeShellApplication, zsh, ... }:
{
writeShellApplication,
zsh,
...
}:
writeShellApplication {
name = "custom-launch";
runtimeInputs = [
+7 -2
View File
@@ -1,5 +1,10 @@
{ writeShellApplication, zsh, kitty, fzf,... }:
{
writeShellApplication,
zsh,
kitty,
fzf,
...
}:
writeShellApplication {
name = "custom-librewolfprofiles";
runtimeInputs = [
+7 -4
View File
@@ -1,9 +1,12 @@
{ writeShellApplication, man, ripgrep, fzf, ... }:
let
{
writeShellApplication,
man,
ripgrep,
fzf,
...
}: let
cacheTime = "10";
in
writeShellApplication {
name = "custom-man";
runtimeInputs = [
+7 -4
View File
@@ -1,9 +1,12 @@
{ writeShellApplication, manix, ripgrep, fzf, ... }:
let
{
writeShellApplication,
manix,
ripgrep,
fzf,
...
}: let
cacheTime = "10";
in
writeShellApplication {
name = "custom-manix";
runtimeInputs = [
+6 -2
View File
@@ -1,5 +1,9 @@
{ writeShellApplication, rclone, libnotify, ... }:
{
writeShellApplication,
rclone,
libnotify,
...
}:
writeShellApplication {
name = "custom-mountkdrive";
runtimeInputs = [
+7 -3
View File
@@ -1,7 +1,11 @@
# used for the terminal autostart. Needs to get cleared and recall fastfetch so that the bar from oh-my-zsh get resized
{ writeShellApplication, hyprland, gawk, libnotify, ... }:
{
writeShellApplication,
hyprland,
gawk,
libnotify,
...
}:
writeShellApplication {
name = "custom-performance";
runtimeInputs = [
+6 -2
View File
@@ -1,5 +1,9 @@
{ writeShellApplication, kitty, tomato-c,... }:
{
writeShellApplication,
kitty,
tomato-c,
...
}:
writeShellApplication {
name = "custom-tomato";
runtimeInputs = [
+6 -4
View File
@@ -1,13 +1,15 @@
{ writeShellApplication, socat, swww, ... }:
let
{
writeShellApplication,
socat,
swww,
...
}: let
wallpaper1 = ../../assets/wallpaper1.jpg;
wallpaper2 = ../../assets/wallpaper2.jpg;
wallpaper3 = ../../assets/wallpaper3.jpg;
wallpaper4 = ../../assets/wallpaper4.jpg;
wallpaper5 = ../../assets/wallpaper5.jpg;
in
writeShellApplication {
name = "custom-wallpaper";
runtimeInputs = [
+5 -2
View File
@@ -1,5 +1,8 @@
{ writeShellApplication, curl, ... }:
{
writeShellApplication,
curl,
...
}:
writeShellApplication {
name = "custom-weather";
runtimeInputs = [
+5 -2
View File
@@ -1,5 +1,8 @@
{ writeShellApplication, curl, ... }:
{
writeShellApplication,
curl,
...
}:
writeShellApplication {
name = "custom-weatherwaybar";
runtimeInputs = [