installed and ran alejandra as formatter

This commit is contained in:
Schrottkatze 2023-11-26 21:26:49 +01:00
parent 49452e89db
commit 8a1314b58f
47 changed files with 1362 additions and 1113 deletions

View file

@ -1,12 +1,14 @@
# Edit this configuration file to define what should be installed on # Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page # your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help). # and in the NixOS manual (accessible by running nixos-help).
{ config, pkgs, lib, ... }:
with lib;
with builtins;
{ {
config,
pkgs,
lib,
...
}:
with lib;
with builtins; {
nix = { nix = {
package = pkgs.nixVersions.stable; package = pkgs.nixVersions.stable;
extraOptions = '' extraOptions = ''
@ -29,11 +31,45 @@ with builtins;
systemPackages = with pkgs; [ systemPackages = with pkgs; [
htmlq htmlq
wget git neofetch pciutils zip unzip gnutar iw btop nodejs jdk8 jdk11 wget
jdk libsecret gh nix-prefetch-scripts fzf glab ripgrep git
sl lolcat appimage-run git-crypt file whois p7zip file nmap cmatrix tree neofetch
socat smartmontools mprocs pciutils
dig aria2 usbutils numbat zip
unzip
gnutar
iw
btop
nodejs
jdk8
jdk11
jdk
libsecret
gh
nix-prefetch-scripts
fzf
glab
ripgrep
sl
lolcat
appimage-run
git-crypt
file
whois
p7zip
file
nmap
cmatrix
tree
socat
smartmontools
mprocs
dig
aria2
usbutils
numbat
alejandra
]; ];
}; };
@ -82,7 +118,11 @@ with builtins;
time.timeZone = "Europe/Berlin"; time.timeZone = "Europe/Berlin";
home-manager.users.jade = { nixosConfig, pkgs, ... }: { home-manager.users.jade = {
nixosConfig,
pkgs,
...
}: {
home.sessionVariables.TZ = nixosConfig.time.timeZone; home.sessionVariables.TZ = nixosConfig.time.timeZone;
}; };
@ -117,4 +157,3 @@ with builtins;
users.defaultUserShell = pkgs.nushellFull; users.defaultUserShell = pkgs.nushellFull;
} }

View file

@ -24,7 +24,15 @@
gumseite.url = "git+https://gitlab.com/schrottkatze/gum-schulsachen.git"; gumseite.url = "git+https://gitlab.com/schrottkatze/gum-schulsachen.git";
}; };
outputs = { self, nixpkgs, nixpkgs-stable, home-manager, nixos-hardware, mac-brcm-fw, ... }@inputs: { outputs = {
self,
nixpkgs,
nixpkgs-stable,
home-manager,
nixos-hardware,
mac-brcm-fw,
...
} @ inputs: {
nixosConfigurations = { nixosConfigurations = {
monosodium-glutamate-g = nixpkgs.lib.nixosSystem { monosodium-glutamate-g = nixpkgs.lib.nixosSystem {
specialArgs = { specialArgs = {
@ -33,10 +41,15 @@
system = "x86_64-linux"; system = "x86_64-linux";
modules = [ modules = [
./hosts/monosodium-glutamate-g/configuration.nix ./hosts/monosodium-glutamate-g/configuration.nix
home-manager.nixosModules.home-manager { home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true; home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true; home-manager.useUserPackages = true;
home-manager.users.jade = { nixosConfig, pkgs, ... }: { home-manager.users.jade = {
nixosConfig,
pkgs,
...
}: {
home.sessionVariables.TZ = nixosConfig.time.timeZone; home.sessionVariables.TZ = nixosConfig.time.timeZone;
home.stateVersion = "${nixosConfig.system.stateVersion}"; home.stateVersion = "${nixosConfig.system.stateVersion}";
}; };
@ -50,10 +63,15 @@
system = "x86_64-linux"; system = "x86_64-linux";
modules = [ modules = [
./hosts/catbook-j/configuration.nix ./hosts/catbook-j/configuration.nix
home-manager.nixosModules.home-manager { home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true; home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true; home-manager.useUserPackages = true;
home-manager.users.jade = { nixosConfig, pkgs, ... }: { home-manager.users.jade = {
nixosConfig,
pkgs,
...
}: {
home.sessionVariables.TZ = nixosConfig.time.timeZone; home.sessionVariables.TZ = nixosConfig.time.timeZone;
home.stateVersion = "22.11"; home.stateVersion = "22.11";
}; };
@ -68,10 +86,15 @@
modules = [ modules = [
"${mac-brcm-fw}" "${mac-brcm-fw}"
./hosts/potatobook-g/configuration.nix ./hosts/potatobook-g/configuration.nix
home-manager.nixosModules.home-manager { home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true; home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true; home-manager.useUserPackages = true;
home-manager.users.jade = { nixosConfig, pkgs, ... }: { home-manager.users.jade = {
nixosConfig,
pkgs,
...
}: {
home.sessionVariables.TZ = nixosConfig.time.timeZone; home.sessionVariables.TZ = nixosConfig.time.timeZone;
home.stateVersion = "${nixosConfig.system.stateVersion}"; home.stateVersion = "${nixosConfig.system.stateVersion}";
}; };

View file

@ -1,10 +1,14 @@
# Edit this configuration file to define what should be installed on # Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page # your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help). # and in the NixOS manual (accessible by running nixos-help).
{
{ config, pkgs, lib, ... }: { config,
imports = pkgs,
[ # Include the results of the hardware scan. lib,
...
}: {
imports = [
# Include the results of the hardware scan.
./hardware-configuration.nix ./hardware-configuration.nix
../../common.nix ../../common.nix
../../modules ../../modules
@ -119,5 +123,4 @@
# Before changing this value read the documentation for this option # Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "23.05"; # Did you read the comment? system.stateVersion = "23.05"; # Did you read the comment?
} }

View file

@ -1,11 +1,15 @@
# Do not modify this file! It was generated by nixos-generate-config # Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes # and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead. # to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{ {
imports = config,
[ (modulesPath + "/installer/scan/not-detected.nix") lib,
pkgs,
modulesPath,
...
}: {
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
]; ];
boot.initrd.availableKernelModules = ["xhci_pci" "nvme" "usb_storage" "sd_mod" "rtsx_pci_sdmmc"]; boot.initrd.availableKernelModules = ["xhci_pci" "nvme" "usb_storage" "sd_mod" "rtsx_pci_sdmmc"];
@ -13,35 +17,37 @@
boot.kernelModules = ["kvm-intel"]; boot.kernelModules = ["kvm-intel"];
boot.extraModulePackages = []; boot.extraModulePackages = [];
fileSystems."/" = fileSystems."/" = {
{ device = "/dev/disk/by-uuid/4f9e8afa-f8d7-40bf-b3ea-17e8e8fbb694"; device = "/dev/disk/by-uuid/4f9e8afa-f8d7-40bf-b3ea-17e8e8fbb694";
fsType = "btrfs"; fsType = "btrfs";
options = ["subvol=@" "compress=zstd:3" "noatime"]; options = ["subvol=@" "compress=zstd:3" "noatime"];
}; };
fileSystems."/home" = fileSystems."/home" = {
{ device = "/dev/disk/by-uuid/4f9e8afa-f8d7-40bf-b3ea-17e8e8fbb694"; device = "/dev/disk/by-uuid/4f9e8afa-f8d7-40bf-b3ea-17e8e8fbb694";
fsType = "btrfs"; fsType = "btrfs";
options = ["subvol=@home" "compress=zstd:3"]; options = ["subvol=@home" "compress=zstd:3"];
}; };
fileSystems."/swap" = fileSystems."/swap" = {
{ device = "/dev/disk/by-uuid/4f9e8afa-f8d7-40bf-b3ea-17e8e8fbb694"; device = "/dev/disk/by-uuid/4f9e8afa-f8d7-40bf-b3ea-17e8e8fbb694";
fsType = "btrfs"; fsType = "btrfs";
options = ["subvol=@/@swap" "noatime"]; options = ["subvol=@/@swap" "noatime"];
}; };
boot.initrd.luks.devices."luks-9cd75cce-6829-4db8-8c5c-a9fb9ec3e122".device = "/dev/disk/by-uuid/9cd75cce-6829-4db8-8c5c-a9fb9ec3e122"; boot.initrd.luks.devices."luks-9cd75cce-6829-4db8-8c5c-a9fb9ec3e122".device = "/dev/disk/by-uuid/9cd75cce-6829-4db8-8c5c-a9fb9ec3e122";
fileSystems."/boot" = fileSystems."/boot" = {
{ device = "/dev/disk/by-uuid/C6CA-5DE8"; device = "/dev/disk/by-uuid/C6CA-5DE8";
fsType = "vfat"; fsType = "vfat";
}; };
swapDevices = [{ swapDevices = [
{
device = "/swap/swapfile"; device = "/swap/swapfile";
size = (1024 * 24); size = 1024 * 24;
}]; }
];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking # Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's # (the default) this is the recommended approach. When using systemd-networkd it's

View file

@ -1,9 +1,7 @@
# Edit this configuration file to define what should be installed on # Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page # your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help). # and in the NixOS manual (accessible by running nixos-help).
{pkgs, ...}: {
{ pkgs, ... }:
{
imports = [ imports = [
./hardware-configuration.nix ./hardware-configuration.nix
../../common.nix ../../common.nix
@ -44,7 +42,6 @@
}; };
boot = { boot = {
loader = { loader = {
# Use the systemd-boot EFI boot loader. # Use the systemd-boot EFI boot loader.
systemd-boot.enable = true; systemd-boot.enable = true;
efi.canTouchEfiVariables = true; efi.canTouchEfiVariables = true;
@ -65,11 +62,9 @@
networking.hostName = "monosodium-glutamate-g"; networking.hostName = "monosodium-glutamate-g";
services = { services = {
# monitor control # monitor control
ddccontrol.enable = true; ddccontrol.enable = true;
xserver = { xserver = {
layout = "us"; layout = "us";
xkbVariant = "altgr-intl"; xkbVariant = "altgr-intl";
enable = true; enable = true;
@ -82,7 +77,6 @@
gnome.gnome-keyring.enable = true; gnome.gnome-keyring.enable = true;
}; };
hardware = { hardware = {
bluetooth.enable = true; bluetooth.enable = true;
keyboard.uhk.enable = true; keyboard.uhk.enable = true;
enableRedistributableFirmware = true; enableRedistributableFirmware = true;
@ -96,7 +90,8 @@
wireshark wireshark
awesomebump awesomebump
zenstates zenmonitor zenstates
zenmonitor
nvtop-amd nvtop-amd
radeontop radeontop
rgp rgp
@ -142,6 +137,3 @@
# release channel # release channel
system.stateVersion = "22.05"; # Did you read the comment? system.stateVersion = "22.05"; # Did you read the comment?
} }

View file

@ -1,11 +1,15 @@
# Do not modify this file! It was generated by nixos-generate-config # Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes # and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead. # to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{ {
imports = config,
[ (modulesPath + "/installer/scan/not-detected.nix") lib,
pkgs,
modulesPath,
...
}: {
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
]; ];
boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod"]; boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod"];
@ -13,27 +17,29 @@
boot.kernelModules = ["kvm-amd"]; boot.kernelModules = ["kvm-amd"];
boot.extraModulePackages = []; boot.extraModulePackages = [];
fileSystems."/" = fileSystems."/" = {
{ device = "/dev/disk/by-uuid/72ffbc9d-a319-42d7-8d26-13c921a679db"; device = "/dev/disk/by-uuid/72ffbc9d-a319-42d7-8d26-13c921a679db";
fsType = "btrfs"; fsType = "btrfs";
options = ["subvol=@root" "compress=zstd:3"]; options = ["subvol=@root" "compress=zstd:3"];
}; };
fileSystems."/home" = fileSystems."/home" = {
{ device = "/dev/disk/by-uuid/72ffbc9d-a319-42d7-8d26-13c921a679db"; device = "/dev/disk/by-uuid/72ffbc9d-a319-42d7-8d26-13c921a679db";
fsType = "btrfs"; fsType = "btrfs";
options = ["subvol=@home" "compress=zstd:3"]; options = ["subvol=@home" "compress=zstd:3"];
}; };
fileSystems."/boot" = fileSystems."/boot" = {
{ device = "/dev/disk/by-uuid/D63E-18C9"; device = "/dev/disk/by-uuid/D63E-18C9";
fsType = "vfat"; fsType = "vfat";
}; };
swapDevices = [{ swapDevices = [
{
device = "/swap/swapfile"; device = "/swap/swapfile";
size = (1024 * 64) + (1024 * 8); # 72G size = (1024 * 64) + (1024 * 8); # 72G
} ]; }
];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking # Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's # (the default) this is the recommended approach. When using systemd-networkd it's

View file

@ -70,9 +70,13 @@
networking.hostName = "potatobook-g"; networking.hostName = "potatobook-g";
services.xserver = { services.xserver = {
resolutions = [ { x = 1920; y = 1200; } ]; resolutions = [
{
x = 1920;
y = 1200;
}
];
# dpi = 180; # dpi = 180;
layout = "us"; layout = "us";
xkbVariant = "altgr-intl"; xkbVariant = "altgr-intl";
@ -95,9 +99,9 @@
hardware.keyboard.uhk.enable = true; hardware.keyboard.uhk.enable = true;
hardware.enableRedistributableFirmware = true; hardware.enableRedistributableFirmware = true;
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
android-tools evremap android-tools
evremap
]; ];
environment.pathsToLink = [ environment.pathsToLink = [
@ -175,5 +179,3 @@
# i rly should put that important big comment back here # i rly should put that important big comment back here
system.stateVersion = "22.11"; # Did you read the comment? system.stateVersion = "22.11"; # Did you read the comment?
} }

View file

@ -1,11 +1,15 @@
# Do not modify this file! It was generated by nixos-generate-config # Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes # and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead. # to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{ {
imports = config,
[ (modulesPath + "/installer/scan/not-detected.nix") lib,
pkgs,
modulesPath,
...
}: {
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
]; ];
boot.initrd.availableKernelModules = ["xhci_pci" "nvme" "usbhid" "uas" "sd_mod"]; boot.initrd.availableKernelModules = ["xhci_pci" "nvme" "usbhid" "uas" "sd_mod"];
@ -13,33 +17,35 @@
boot.kernelModules = ["kvm-intel"]; boot.kernelModules = ["kvm-intel"];
boot.extraModulePackages = []; boot.extraModulePackages = [];
fileSystems."/" = fileSystems."/" = {
{ device = "/dev/disk/by-uuid/f6d243ec-6be9-4551-8cbb-aefb7b691a62"; device = "/dev/disk/by-uuid/f6d243ec-6be9-4551-8cbb-aefb7b691a62";
fsType = "btrfs"; fsType = "btrfs";
options = ["subvol=root"]; options = ["subvol=root"];
}; };
fileSystems."/home" = fileSystems."/home" = {
{ device = "/dev/disk/by-uuid/f6d243ec-6be9-4551-8cbb-aefb7b691a62"; device = "/dev/disk/by-uuid/f6d243ec-6be9-4551-8cbb-aefb7b691a62";
fsType = "btrfs"; fsType = "btrfs";
options = ["subvol=home"]; options = ["subvol=home"];
}; };
fileSystems."/nix" = fileSystems."/nix" = {
{ device = "/dev/disk/by-uuid/f6d243ec-6be9-4551-8cbb-aefb7b691a62"; device = "/dev/disk/by-uuid/f6d243ec-6be9-4551-8cbb-aefb7b691a62";
fsType = "btrfs"; fsType = "btrfs";
options = ["subvol=nix"]; options = ["subvol=nix"];
}; };
fileSystems."/boot" = fileSystems."/boot" = {
{ device = "/dev/disk/by-uuid/5F66-17ED"; device = "/dev/disk/by-uuid/5F66-17ED";
fsType = "vfat"; fsType = "vfat";
}; };
swapDevices = [{ swapDevices = [
{
device = "/swap/swapfile"; device = "/swap/swapfile";
size = (1024 * 12); # 12GB size = 1024 * 12; # 12GB
}]; }
];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking # Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's # (the default) this is the recommended approach. When using systemd-networkd it's

View file

@ -1,9 +1,11 @@
{config, pkgs, ...}:
{ {
config,
pkgs,
...
}: {
imports = [ imports = [
<nixpkgs/nixos/modules/installer/cd-dvd/installation-cd-minimal.nix> <nixpkgs/nixos/modules/installer/cd-dvd/installation-cd-minimal.nix>
<nixpkgs/nixos/modules/installer/cd-dvd/channel.nix> <nixpkgs/nixos/modules/installer/cd-dvd/channel.nix>
./configuration.nix ./configuration.nix
]; ];
} }

View file

@ -1,3 +1,3 @@
{...}: {} {...}: {}
# dummy # dummy

View file

@ -1,5 +1,4 @@
{ ... }: {...}: {
{
imports = [ imports = [
./shell ./shell
./desktop ./desktop

View file

@ -1,6 +1,9 @@
{ config, lib, pkgs, ... }:
{ {
config,
lib,
pkgs,
...
}: {
config = { config = {
programs = { programs = {
noisetorch.enable = true; noisetorch.enable = true;

View file

@ -1,7 +1,12 @@
{ config, lib, pkgs, ... }: {
config,
let cfg = config.jade.desktop.cloud; lib,
in with lib; { pkgs,
...
}: let
cfg = config.jade.desktop.cloud;
in
with lib; {
options.jade.desktop.cloud = { options.jade.desktop.cloud = {
enable = mkEnableOption "Enable cloud things"; enable = mkEnableOption "Enable cloud things";
}; };

View file

@ -1,8 +1,12 @@
{ config, lib, pkgs, ... }: {
config,
let lib,
pkgs,
...
}: let
cfg = config.jade.desktop.compositing; cfg = config.jade.desktop.compositing;
in with lib; { in
with lib; {
options.jade.desktop.compositing = { options.jade.desktop.compositing = {
enable = mkEnableOption "Enable compositing with picom"; enable = mkEnableOption "Enable compositing with picom";
}; };

View file

@ -1,6 +1,9 @@
{ config, lib, pkgs, ... }: {
config,
let lib,
pkgs,
...
}: let
# window-screenshot = pkgs.writeTextFile "window-screenshot.nu" (builtins.readFile ../../other/scripts/desktop/window-screenshot.nu); # window-screenshot = pkgs.writeTextFile "window-screenshot.nu" (builtins.readFile ../../other/scripts/desktop/window-screenshot.nu);
window-screenshot = pkgs.writeShellScriptBin "window-screenshot.sh" (builtins.readFile ../../other/scripts/desktop/window-screenshot.sh); window-screenshot = pkgs.writeShellScriptBin "window-screenshot.sh" (builtins.readFile ../../other/scripts/desktop/window-screenshot.sh);
# desktop-ctl = pkgs.writeShellScriptBin "desktop-ctl.sh" (builtins.readFile ../scripts/desktop/desktop-ctl.sh); # desktop-ctl = pkgs.writeShellScriptBin "desktop-ctl.sh" (builtins.readFile ../scripts/desktop/desktop-ctl.sh);
@ -9,7 +12,8 @@ let
ocr-screenshot = pkgs.writeShellScriptBin "ocr-screenshot.sh" (builtins.readFile ../../other/scripts/desktop/ocr-screenshot.sh); ocr-screenshot = pkgs.writeShellScriptBin "ocr-screenshot.sh" (builtins.readFile ../../other/scripts/desktop/ocr-screenshot.sh);
# rofi calculator copied from https://github.com/barbuk/menu-qalc # rofi calculator copied from https://github.com/barbuk/menu-qalc
menu-qalc = pkgs.writeShellScriptBin "menu-qalc" (builtins.readFile ../../other/scripts/desktop/menu-qalc.sh); menu-qalc = pkgs.writeShellScriptBin "menu-qalc" (builtins.readFile ../../other/scripts/desktop/menu-qalc.sh);
in with lib; { in
with lib; {
imports = [ imports = [
./audio.nix ./audio.nix
./gaming.nix ./gaming.nix
@ -71,8 +75,6 @@ in with lib; {
enable = true; enable = true;
}; };
}; };
}; };
programs.xss-lock = { programs.xss-lock = {
@ -99,35 +101,79 @@ in with lib; {
theme = ../../other/rofi-themes/applauncher.rasi; theme = ../../other/rofi-themes/applauncher.rasi;
}; };
home.packages = with pkgs; [ home.packages = with pkgs; [
just bacon just
bacon
magic-wormhole-rs magic-wormhole-rs
yt-dlp yt-dlp
i3lock rofimoji feh xorg.xinput arandr flameshot i3lock
tesseract5 imagemagick xclip xmacro xorg.xev rofimoji
feh
xorg.xinput
arandr
flameshot
tesseract5
imagemagick
xclip
xmacro
xorg.xev
syncplay syncplay
# filemanager # filemanager
xfce.thunar xfce.tumbler xfce.thunar-archive-plugin gnome.file-roller xfce.thunar
xfce.tumbler
xfce.thunar-archive-plugin
gnome.file-roller
# media/file viewers # media/file viewers
vlc mpv evince nomacs vlc
mpv
evince
nomacs
# from environment.systemPackages cleanup # from environment.systemPackages cleanup
font-manager xdotool xorg.xwininfo gparted uhk-agent font-manager
cool-retro-term xdg-desktop-portal-gtk obsidian zettlr virt-manager xdotool
ddccontrol-db firebird-emu gitg gpick qdirstat ffmpeg_5 xorg.xwininfo
gparted
uhk-agent
cool-retro-term
xdg-desktop-portal-gtk
obsidian
zettlr
virt-manager
ddccontrol-db
firebird-emu
gitg
gpick
qdirstat
ffmpeg_5
# external # external
libnotify i3lock rofi rofimoji feh xorg.xinput arandr libnotify
flameshot tesseract5 imagemagick xclip kitty xmacro i3lock
brightnessctl drawing libqalculate rofi
rofimoji
feh
xorg.xinput
arandr
flameshot
tesseract5
imagemagick
xclip
kitty
xmacro
brightnessctl
drawing
libqalculate
# custom scripts # custom scripts
window-screenshot desktop-ctl window-screenshot
ocr-screenshot menu-qalc desktop-ctl
ocr-screenshot
menu-qalc
# meow # meow
oneko oneko

View file

@ -1,5 +1,9 @@
{ pkgs, config, lib, ... }: {
let pkgs,
config,
lib,
...
}: let
cfg = config.jade.desktop.evremap; cfg = config.jade.desktop.evremap;
evremap = pkgs.rustPlatform.buildRustPackage { evremap = pkgs.rustPlatform.buildRustPackage {
pname = "evremap"; pname = "evremap";
@ -18,7 +22,8 @@ let
nativeBuildInputs = [pkgs.pkg-config]; nativeBuildInputs = [pkgs.pkg-config];
buildInputs = [pkgs.libevdev]; buildInputs = [pkgs.libevdev];
}; };
in with lib; { in
with lib; {
options.jade.desktop.evremap = { options.jade.desktop.evremap = {
enable = mkEnableOption "Enable evremap"; enable = mkEnableOption "Enable evremap";
}; };

View file

@ -133,69 +133,101 @@
default = "DuckDuckGo"; default = "DuckDuckGo";
engines = { engines = {
"Nix Packages" = { "Nix Packages" = {
urls = [{ urls = [
{
template = "https://search.nixos.org/packages"; template = "https://search.nixos.org/packages";
params = [ params = [
{ name = "query"; value = "{searchTerms}"; } {
name = "query";
value = "{searchTerms}";
}
];
}
]; ];
}];
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg"; icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
definedAliases = ["pkgs"]; definedAliases = ["pkgs"];
}; };
"Nix Options" = { "Nix Options" = {
urls = [{ urls = [
{
template = "https://search.nixos.org/options"; template = "https://search.nixos.org/options";
params = [ params = [
{ name = "query"; value = "{searchTerms}"; } {
name = "query";
value = "{searchTerms}";
}
];
}
]; ];
}];
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg"; icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
definedAliases = ["opts"]; definedAliases = ["opts"];
}; };
"Home manager Options" = { "Home manager Options" = {
urls = [{ urls = [
{
template = "https://mipmip.github.io/home-manager-option-search/"; template = "https://mipmip.github.io/home-manager-option-search/";
params = [ params = [
{ name = "query"; value = "{searchTerms}"; } {
name = "query";
value = "{searchTerms}";
}
];
}
]; ];
}];
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg"; icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
definedAliases = ["hm"]; definedAliases = ["hm"];
}; };
"NixOS Wiki" = { "NixOS Wiki" = {
urls = [{ urls = [
{
template = "https://nixos.wiki/index.php?title=Special:Search&amp;search={searchTerms}&amp;namespace=0"; template = "https://nixos.wiki/index.php?title=Special:Search&amp;search={searchTerms}&amp;namespace=0";
}]; }
];
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg"; icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
definedAliases = ["nxwk"]; definedAliases = ["nxwk"];
}; };
"lib.rs" = { "lib.rs" = {
urls = [{ urls = [
{
template = "https://lib.rs/search"; template = "https://lib.rs/search";
params = [ params = [
{ name = "q"; value = "{searchTerms}"; } {
name = "q";
value = "{searchTerms}";
}
];
}
]; ];
}];
icon = "https://lib.rs/favicon.png"; icon = "https://lib.rs/favicon.png";
definedAliases = ["libs"]; definedAliases = ["libs"];
}; };
"rust docs" = { "rust docs" = {
urls = [{ urls = [
{
template = "https://docs.rs/releases/search"; template = "https://docs.rs/releases/search";
params = [ params = [
{ name = "query"; value = "{searchTerms}"; } {
name = "query";
value = "{searchTerms}";
}
];
}
]; ];
}];
icon = "https://docs.rs/-/static/favicon.ico"; icon = "https://docs.rs/-/static/favicon.ico";
definedAliases = ["docs"]; definedAliases = ["docs"];
}; };
"rust std docs" = { "rust std docs" = {
urls = [{ urls = [
{
template = "https://docs.rust-lang.org/std/index.html"; template = "https://docs.rust-lang.org/std/index.html";
params = [ params = [
{ name = "search"; value = "{searchTerms}"; } {
name = "search";
value = "{searchTerms}";
}
];
}
]; ];
}];
icon = "https://doc.rust-lang.org/favicon.ico"; icon = "https://doc.rust-lang.org/favicon.ico";
definedAliases = ["std"]; definedAliases = ["std"];
}; };

View file

@ -1,8 +1,12 @@
{ config, lib, pkgs, ... }: {
config,
let lib,
pkgs,
...
}: let
cfg = config.jade.desktop.gaming; cfg = config.jade.desktop.gaming;
in with lib; { in
with lib; {
options.jade.desktop.gaming = { options.jade.desktop.gaming = {
enable = mkEnableOption "Enable gaming stuff"; enable = mkEnableOption "Enable gaming stuff";
}; };

View file

@ -1,7 +1,12 @@
{ config, lib, pkgs, ... }: {
config,
let cfg = config.jade.desktop.ios-compat; lib,
in with lib; { pkgs,
...
}: let
cfg = config.jade.desktop.ios-compat;
in
with lib; {
options.jade.desktop.ios-compat = { options.jade.desktop.ios-compat = {
enable = mkEnableOption "Enable the ios compatability programs"; enable = mkEnableOption "Enable the ios compatability programs";
}; };

View file

@ -1,7 +1,12 @@
{ config, lib, pkgs, ... }: {
config,
let cfg = config.jade.desktop.kdeconnect; lib,
in with lib; { pkgs,
...
}: let
cfg = config.jade.desktop.kdeconnect;
in
with lib; {
options.jade.desktop.kdeconnect = { options.jade.desktop.kdeconnect = {
enable = mkEnableOption "Enable KDE connect"; enable = mkEnableOption "Enable KDE connect";
}; };

View file

@ -1,6 +1,9 @@
{ config, lib, pkgs, ... }: {
config,
let lib,
pkgs,
...
}: let
cfg = config.jade.desktop.mail; cfg = config.jade.desktop.mail;
imap = { imap = {
host = "imap.migadu.com"; host = "imap.migadu.com";
@ -11,7 +14,8 @@ let
port = 465; port = 465;
tls.enable = true; tls.enable = true;
}; };
in with lib; { in
with lib; {
options.jade.desktop.mail = { options.jade.desktop.mail = {
enable = mkEnableOption "Enable thunderbird mail stuff"; enable = mkEnableOption "Enable thunderbird mail stuff";
}; };

View file

@ -1,7 +1,11 @@
{ config, lib, pkgs, ... }: {
config,
let lib,
addNuShebang = path: builtins.concatStringsSep "\n\n" [ pkgs,
...
}: let
addNuShebang = path:
builtins.concatStringsSep "\n\n" [
"#!${pkgs.nushellFull}/bin/nu" "#!${pkgs.nushellFull}/bin/nu"
(builtins.readFile path) (builtins.readFile path)
]; ];
@ -40,7 +44,7 @@ in {
]; ];
}; };
}; };
environment.etc = (with builtins; ( environment.etc = with builtins; (
listToAttrs ( listToAttrs (
map (v: { map (v: {
name = "networkhooks/${v}"; name = "networkhooks/${v}";
@ -51,7 +55,7 @@ in {
}) })
(attrNames (readDir ../../other/scripts/networkhooks)) (attrNames (readDir ../../other/scripts/networkhooks))
) )
)); );
systemd.services."NetworkManager-wait-online".enable = false; systemd.services."NetworkManager-wait-online".enable = false;
services.mullvad-vpn.enable = true; services.mullvad-vpn.enable = true;
home-manager.users.jade = {pkgs, ...}: { home-manager.users.jade = {pkgs, ...}: {

View file

@ -1,6 +1,9 @@
{ config, lib, pkgs, ... }:
{ {
config,
lib,
pkgs,
...
}: {
config = { config = {
home-manager.users.jade = {pkgs, ...}: { home-manager.users.jade = {pkgs, ...}: {
#xsession.windowManager.i3.config.startup = [ #xsession.windowManager.i3.config.startup = [

View file

@ -1,7 +1,12 @@
{ config, lib, pkgs, ... }: {
config,
let cfg = config.jade.desktop.social; lib,
in with lib; { pkgs,
...
}: let
cfg = config.jade.desktop.social;
in
with lib; {
options.jade.desktop.social = { options.jade.desktop.social = {
enable = mkEnableOption "Enable social apps"; enable = mkEnableOption "Enable social apps";
}; };

View file

@ -1,5 +1,9 @@
{ config, lib, pkgs, ... }:
{ {
config,
lib,
pkgs,
...
}: {
imports = [ imports = [
./spacenav.nix ./spacenav.nix
./wacom.nix ./wacom.nix

View file

@ -1,5 +1,4 @@
{ pkgs, ... }: {pkgs, ...}: {
{
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
spacenavd spacenavd
libspnav libspnav

View file

@ -1,7 +1,12 @@
{ config, lib, pkgs, ... }: {
config,
let cfg = config.jade.desktop.syncthing; lib,
in with lib; { pkgs,
...
}: let
cfg = config.jade.desktop.syncthing;
in
with lib; {
options.jade.desktop.syncthing = { options.jade.desktop.syncthing = {
enable = mkEnableOption "Enable syncing via syncthing"; enable = mkEnableOption "Enable syncing via syncthing";
}; };

View file

@ -1,6 +1,9 @@
{ config, lib, pkgs, ... }:
{ {
config,
lib,
pkgs,
...
}: {
config = { config = {
fonts.packages = with pkgs; [ fonts.packages = with pkgs; [
atkinson-hyperlegible atkinson-hyperlegible

View file

@ -1,4 +1,9 @@
{ config, lib, pkgs, ... }: {
config,
lib,
pkgs,
...
}:
with lib; { with lib; {
home-manager.users.jade = {pkgs, ...}: { home-manager.users.jade = {pkgs, ...}: {
xsession.windowManager.xmonad = { xsession.windowManager.xmonad = {

View file

@ -1,5 +1,9 @@
{ config, lib, pkgs, ... }:
{ {
config,
lib,
pkgs,
...
}: {
config = { config = {
networking = { networking = {
firewall = { firewall = {
@ -9,7 +13,8 @@
22 22
# http, https # http, https
80 443 80
443
# syncthing web ui # syncthing web ui
8384 8384

View file

@ -1,7 +1,12 @@
{ config, lib, pkgs, ... }: {
config,
let cfg = config.jade.flatpak; lib,
in with lib; { pkgs,
...
}: let
cfg = config.jade.flatpak;
in
with lib; {
options.jade.flatpak = { options.jade.flatpak = {
enable = mkEnableOption "Enable flatpak"; enable = mkEnableOption "Enable flatpak";
}; };

View file

@ -1,5 +1,4 @@
{ config, ... }: {config, ...}: {
{
home-manager.users.jade = {pkgs, ...}: { home-manager.users.jade = {pkgs, ...}: {
home = { home = {
sessionVariables.EDITOR = "hx"; sessionVariables.EDITOR = "hx";

View file

@ -1,5 +1,8 @@
{ config, lib, ... }:
{ {
config,
lib,
...
}: {
home-manager.users.jade = {pkgs, ...}: { home-manager.users.jade = {pkgs, ...}: {
home.file = { home.file = {
zellij-forgot = { zellij-forgot = {

View file

@ -1,10 +1,16 @@
{ config, lib, pkgs, ... }: {
config,
let cfg = config.jade.NAME; lib,
in with lib; { pkgs,
...
}: let
cfg = config.jade.NAME;
in
with lib; {
options.jade.NAME = { options.jade.NAME = {
enable = mkEnableOption "Enable the module"; enable = mkEnableOption "Enable the module";
}; };
config = mkIf cfg.enable { config =
mkIf cfg.enable {
}; };
} }

View file

@ -1,7 +1,12 @@
{ config, lib, pkgs, ... }: {
config,
let cfg = config.jade.terminal; lib,
in with lib; { pkgs,
...
}: let
cfg = config.jade.terminal;
in
with lib; {
options.jade.terminal = { options.jade.terminal = {
enable = mkEnableOption "Enable Kitty"; enable = mkEnableOption "Enable Kitty";
}; };

View file

@ -1,11 +1,14 @@
{ pkgs, lib }: rec { {
pkgs,
lib,
}: rec {
# taken from https://github.com/NixOS/nixpkgs/blob/3650808d85dccbfa3be3d785dfd3ce33a757bd2c/pkgs/build-support/trivial-builders/default.nix#L335 # taken from https://github.com/NixOS/nixpkgs/blob/3650808d85dccbfa3be3d785dfd3ce33a757bd2c/pkgs/build-support/trivial-builders/default.nix#L335
writeNuShellApplication = writeNuShellApplication = {
{ name name,
, text text,
, runtimeInputs ? [ ] runtimeInputs ? [],
, meta ? { } meta ? {},
, checkPhase ? null checkPhase ? null,
}: }:
writeTextFile { writeTextFile {
inherit name meta; inherit name meta;
@ -13,12 +16,15 @@
destination = "/bin/${name}"; destination = "/bin/${name}";
allowSubstitutes = true; allowSubstitutes = true;
preferLocalBuild = false; preferLocalBuild = false;
text = '' text =
''
#!${pkgs.nushell} #!${pkgs.nushell}
'' + lib.optionalString (runtimeInputs != [ ]) '' ''
+ lib.optionalString (runtimeInputs != []) ''
$env.PATH = ($env.PATH | split row (char esep) | prepend '${lib.makeBinPath runtimeInputs}'); $env.PATH = ($env.PATH | split row (char esep) | prepend '${lib.makeBinPath runtimeInputs}');
'' + '' ''
+ ''
${text} ${text}
''; '';
@ -26,7 +32,8 @@
checkPhase = checkPhase =
# GHC (=> shellcheck) isn't supported on some platforms (such as risc-v) # GHC (=> shellcheck) isn't supported on some platforms (such as risc-v)
# but we still want to use writeShellApplication on those platforms # but we still want to use writeShellApplication on those platforms
if checkPhase == null then '' if checkPhase == null
then ''
runHook preCheck runHook preCheck
nu -c "nu-check -d $target" nu -c "nu-check -d $target"
@ -35,12 +42,12 @@
'' ''
else checkPhase; else checkPhase;
}; };
packageNushellApplication = packageNushellApplication = {
{ name name,
, path path,
, runtimeInputs ? [ ] runtimeInputs ? [],
, meta ? { } meta ? {},
, checkPhase ? null checkPhase ? null,
}: }:
writeNuShellApplication { writeNuShellApplication {
inherit name runtimeInputs meta checkPhase; inherit name runtimeInputs meta checkPhase;