mirror of
https://codeberg.org/leana8959/.files.git
synced 2025-12-06 06:39:14 +00:00
tree-wide: format with nixfmt
Another saturday another useless formatter change. It's my dotfiles, after all alejandra doesn't handle c-style inline comments well.
This commit is contained in:
parent
ec704b5272
commit
ebf8468807
116 changed files with 1895 additions and 1689 deletions
|
|
@ -4,133 +4,135 @@ let
|
|||
hostname = "hydrogen";
|
||||
username = "leana";
|
||||
in
|
||||
{
|
||||
modulesPath,
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
inherit (lib.modules) mkAliasOptionModule;
|
||||
in {
|
||||
imports = [
|
||||
# The generator and hardware configuration
|
||||
(modulesPath + "/installer/sd-card/sd-image-aarch64.nix")
|
||||
{
|
||||
modulesPath,
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
let
|
||||
inherit (lib.modules) mkAliasOptionModule;
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
# The generator and hardware configuration
|
||||
(modulesPath + "/installer/sd-card/sd-image-aarch64.nix")
|
||||
|
||||
#
|
||||
# Shorthands
|
||||
#
|
||||
(mkAliasOptionModule ["me"] ["users" "users" username])
|
||||
(mkAliasOptionModule ["hm"] ["home-manager" "users" username])
|
||||
#
|
||||
# Shorthands
|
||||
#
|
||||
(mkAliasOptionModule [ "me" ] [ "users" "users" username ])
|
||||
(mkAliasOptionModule [ "hm" ] [ "home-manager" "users" username ])
|
||||
|
||||
#
|
||||
# hostname
|
||||
#
|
||||
{_module.args = {inherit hostname;};}
|
||||
#
|
||||
# hostname
|
||||
#
|
||||
{ _module.args = { inherit hostname; }; }
|
||||
|
||||
#
|
||||
# nixpkgs
|
||||
#
|
||||
{
|
||||
nixpkgs = {
|
||||
overlays = map import [
|
||||
../overlays/agenix.nix
|
||||
../overlays/nur.nix
|
||||
../overlays/nix-tree.nix
|
||||
../packages/overlay.nix
|
||||
#
|
||||
# nixpkgs
|
||||
#
|
||||
{
|
||||
nixpkgs = {
|
||||
overlays = map import [
|
||||
../overlays/agenix.nix
|
||||
../overlays/nur.nix
|
||||
../overlays/nix-tree.nix
|
||||
../packages/overlay.nix
|
||||
|
||||
# use lix everywhere and wrap it with nom
|
||||
../overlays/lix.nix
|
||||
../overlays/nix-monitored.nix
|
||||
];
|
||||
|
||||
# Set NIX_PATH and flake registry at the same time
|
||||
# https://github.com/NixOS/nixpkgs/pull/254405
|
||||
flake.source = sources.nixpkgs;
|
||||
};
|
||||
|
||||
nix.package = pkgs.nix-monitored;
|
||||
|
||||
system.nixos.version = lib.substring 0 8 sources.nixpkgs.revision;
|
||||
}
|
||||
|
||||
./hydrogen/nixos/misc.nix
|
||||
./hydrogen/nixos/programs.nix
|
||||
./hydrogen/nixos/connectivity.nix
|
||||
|
||||
../nixosModules/common/fish.nix
|
||||
../nixosModules/common/disable-command-not-found.nix
|
||||
../nixosModules/common/network.nix
|
||||
../nixosModules/common/sudo-conf.nix
|
||||
../nixosModules/common/system-nixconf.nix
|
||||
|
||||
# QUIRK:
|
||||
# Had issue when building the installer as it fails to bootstrap itself
|
||||
# Might be useful to disable for the first build.
|
||||
# ../nixosModules/extra/secure_dns.nix
|
||||
../nixosModules/extra/leana.nix
|
||||
|
||||
#
|
||||
# Extern modules
|
||||
#
|
||||
(sources.agenix + "/modules/age.nix")
|
||||
|
||||
(sources.nixos-hardware + "/raspberry-pi/4")
|
||||
|
||||
#
|
||||
# home-manager
|
||||
#
|
||||
(sources.home-manager + "/nixos")
|
||||
{
|
||||
home-manager = {
|
||||
useGlobalPkgs = true;
|
||||
useUserPackages = true;
|
||||
sharedModules = [{home.stateVersion = lib.mkDefault config.system.stateVersion;}];
|
||||
};
|
||||
|
||||
hm.imports = [
|
||||
#
|
||||
# hostname
|
||||
#
|
||||
{_module.args = {inherit hostname;};}
|
||||
|
||||
#
|
||||
# home modules
|
||||
#
|
||||
./hydrogen/home/programs.nix
|
||||
./hydrogen/home/dev.nix
|
||||
|
||||
../homeModules/common/btop
|
||||
../homeModules/common/fish
|
||||
../homeModules/common/starship
|
||||
../homeModules/common/fzf.nix
|
||||
../homeModules/common/tmux
|
||||
../homeModules/common/vim
|
||||
../homeModules/common/direnv.nix
|
||||
../homeModules/common/git.nix
|
||||
../homeModules/common/gpg.nix
|
||||
../homeModules/common/leana.nix
|
||||
../homeModules/common/locale.nix
|
||||
../homeModules/common/packages.nix
|
||||
../homeModules/common/tealdeer.nix
|
||||
|
||||
../homeModules/extra/tmux-fish-integration.nix
|
||||
|
||||
#
|
||||
# Extern modules
|
||||
#
|
||||
(sources.agenix + "/modules/age-home.nix")
|
||||
(import sources.wired-notify).homeManagerModules.default
|
||||
# use lix everywhere and wrap it with nom
|
||||
../overlays/lix.nix
|
||||
../overlays/nix-monitored.nix
|
||||
];
|
||||
}
|
||||
|
||||
#
|
||||
# Secrets
|
||||
#
|
||||
{
|
||||
age.secrets = {
|
||||
wpa_password.file = "${../secrets/wpa_password.age}";
|
||||
};
|
||||
}
|
||||
];
|
||||
}
|
||||
# Set NIX_PATH and flake registry at the same time
|
||||
# https://github.com/NixOS/nixpkgs/pull/254405
|
||||
flake.source = sources.nixpkgs;
|
||||
};
|
||||
|
||||
nix.package = pkgs.nix-monitored;
|
||||
|
||||
system.nixos.version = lib.substring 0 8 sources.nixpkgs.revision;
|
||||
}
|
||||
|
||||
./hydrogen/nixos/misc.nix
|
||||
./hydrogen/nixos/programs.nix
|
||||
./hydrogen/nixos/connectivity.nix
|
||||
|
||||
../nixosModules/common/fish.nix
|
||||
../nixosModules/common/disable-command-not-found.nix
|
||||
../nixosModules/common/network.nix
|
||||
../nixosModules/common/sudo-conf.nix
|
||||
../nixosModules/common/system-nixconf.nix
|
||||
|
||||
# QUIRK:
|
||||
# Had issue when building the installer as it fails to bootstrap itself
|
||||
# Might be useful to disable for the first build.
|
||||
# ../nixosModules/extra/secure_dns.nix
|
||||
../nixosModules/extra/leana.nix
|
||||
|
||||
#
|
||||
# Extern modules
|
||||
#
|
||||
(sources.agenix + "/modules/age.nix")
|
||||
|
||||
(sources.nixos-hardware + "/raspberry-pi/4")
|
||||
|
||||
#
|
||||
# home-manager
|
||||
#
|
||||
(sources.home-manager + "/nixos")
|
||||
{
|
||||
home-manager = {
|
||||
useGlobalPkgs = true;
|
||||
useUserPackages = true;
|
||||
sharedModules = [ { home.stateVersion = lib.mkDefault config.system.stateVersion; } ];
|
||||
};
|
||||
|
||||
hm.imports = [
|
||||
#
|
||||
# hostname
|
||||
#
|
||||
{ _module.args = { inherit hostname; }; }
|
||||
|
||||
#
|
||||
# home modules
|
||||
#
|
||||
./hydrogen/home/programs.nix
|
||||
./hydrogen/home/dev.nix
|
||||
|
||||
../homeModules/common/btop
|
||||
../homeModules/common/fish
|
||||
../homeModules/common/starship
|
||||
../homeModules/common/fzf.nix
|
||||
../homeModules/common/tmux
|
||||
../homeModules/common/vim
|
||||
../homeModules/common/direnv.nix
|
||||
../homeModules/common/git.nix
|
||||
../homeModules/common/gpg.nix
|
||||
../homeModules/common/leana.nix
|
||||
../homeModules/common/locale.nix
|
||||
../homeModules/common/packages.nix
|
||||
../homeModules/common/tealdeer.nix
|
||||
|
||||
../homeModules/extra/tmux-fish-integration.nix
|
||||
|
||||
#
|
||||
# Extern modules
|
||||
#
|
||||
(sources.agenix + "/modules/age-home.nix")
|
||||
(import sources.wired-notify).homeManagerModules.default
|
||||
];
|
||||
}
|
||||
|
||||
#
|
||||
# Secrets
|
||||
#
|
||||
{
|
||||
age.secrets = {
|
||||
wpa_password.file = "${../secrets/wpa_password.age}";
|
||||
};
|
||||
}
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
{pkgs, ...}: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
home.packages = [
|
||||
pkgs.nil # nix
|
||||
pkgs.pyright # python
|
||||
|
|
|
|||
|
|
@ -3,12 +3,15 @@
|
|||
lib,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
home.sessionVariables = let
|
||||
fishCfg = config.programs.fish;
|
||||
in {
|
||||
"SHELL" = lib.mkIf fishCfg.enable (lib.getExe fishCfg.package);
|
||||
};
|
||||
}:
|
||||
{
|
||||
home.sessionVariables =
|
||||
let
|
||||
fishCfg = config.programs.fish;
|
||||
in
|
||||
{
|
||||
"SHELL" = lib.mkIf fishCfg.enable (lib.getExe fishCfg.package);
|
||||
};
|
||||
|
||||
home.packages = [
|
||||
pkgs.nmap
|
||||
|
|
|
|||
|
|
@ -2,7 +2,8 @@
|
|||
config,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
{
|
||||
users.users.root.openssh.authorizedKeys.keys = import ../../../identities.nix;
|
||||
|
||||
networking = {
|
||||
|
|
@ -22,13 +23,12 @@
|
|||
userControlled.enable = true;
|
||||
secretsFile = config.age.secrets.wpa_password.path;
|
||||
scanOnLowSignal = false;
|
||||
networks = let
|
||||
fromList = import ../../../networks/wpa_supplicant-compat.nix;
|
||||
networks = import ../../../networks/list.nix;
|
||||
in
|
||||
fromList (
|
||||
builtins.filter (x: x.ssid == "~") networks
|
||||
);
|
||||
networks =
|
||||
let
|
||||
fromList = import ../../../networks/wpa_supplicant-compat.nix;
|
||||
networks = import ../../../networks/list.nix;
|
||||
in
|
||||
fromList (builtins.filter (x: x.ssid == "~") networks);
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -13,8 +13,7 @@
|
|||
# modprobe: FATAL: Module sun4i-drm not found in directory /nix/store/gvvwpdckzcr4iamp1iyrqw3nzb7bg6c4-linux-rpi-6.6.51-stable_20241008-modules/lib/modules/6.6.51
|
||||
nixpkgs.overlays = [
|
||||
(final: prev: {
|
||||
makeModulesClosure = x:
|
||||
prev.makeModulesClosure (x // {allowMissing = true;});
|
||||
makeModulesClosure = x: prev.makeModulesClosure (x // { allowMissing = true; });
|
||||
})
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
{pkgs, ...}: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
environment.systemPackages = [
|
||||
pkgs.man-pages
|
||||
pkgs.man-pages-posix
|
||||
|
|
|
|||
|
|
@ -9,7 +9,8 @@
|
|||
lib,
|
||||
modulesPath,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
../nixosModules/common/system-nixconf.nix
|
||||
../nixosModules/common/sudo-conf.nix
|
||||
|
|
@ -18,10 +19,15 @@
|
|||
];
|
||||
|
||||
nix.settings = {
|
||||
extra-substituters = ["https://leana8959.cachix.org"];
|
||||
extra-trusted-substituters = ["https://leana8959.cachix.org"];
|
||||
extra-trusted-public-keys = ["leana8959.cachix.org-1:CxQSAp8lcgMv8Me459of0jdXRW2tcyeYRKTiiUq8z0M="];
|
||||
experimental-features = ["nix-command" "flakes"];
|
||||
extra-substituters = [ "https://leana8959.cachix.org" ];
|
||||
extra-trusted-substituters = [ "https://leana8959.cachix.org" ];
|
||||
extra-trusted-public-keys = [
|
||||
"leana8959.cachix.org-1:CxQSAp8lcgMv8Me459of0jdXRW2tcyeYRKTiiUq8z0M="
|
||||
];
|
||||
experimental-features = [
|
||||
"nix-command"
|
||||
"flakes"
|
||||
];
|
||||
};
|
||||
|
||||
nixpkgs = {
|
||||
|
|
@ -45,7 +51,7 @@
|
|||
pkgs.btop
|
||||
];
|
||||
|
||||
networking.firewall.allowedTCPPorts = [8080]; # in case you wanna nc
|
||||
networking.firewall.allowedTCPPorts = [ 8080 ]; # in case you wanna nc
|
||||
|
||||
programs.tmux.enable = true;
|
||||
users.users.nixos.shell = pkgs.fish;
|
||||
|
|
|
|||
|
|
@ -5,225 +5,227 @@ let
|
|||
hostname = "vanadium";
|
||||
username = "leana";
|
||||
in
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
inherit (lib.modules) mkAliasOptionModule;
|
||||
in {
|
||||
imports = [
|
||||
#
|
||||
# Shorthands
|
||||
#
|
||||
(mkAliasOptionModule ["me"] ["users" "users" username])
|
||||
(mkAliasOptionModule ["hm"] ["home-manager" "users" username])
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
inherit (lib.modules) mkAliasOptionModule;
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
#
|
||||
# Shorthands
|
||||
#
|
||||
(mkAliasOptionModule [ "me" ] [ "users" "users" username ])
|
||||
(mkAliasOptionModule [ "hm" ] [ "home-manager" "users" username ])
|
||||
|
||||
#
|
||||
# hostname
|
||||
#
|
||||
{_module.args = {inherit hostname;};}
|
||||
#
|
||||
# hostname
|
||||
#
|
||||
{ _module.args = { inherit hostname; }; }
|
||||
|
||||
#
|
||||
# nixpkgs
|
||||
#
|
||||
{
|
||||
# affect the generated nix.conf, doesn't need to be turned off during nixos-install
|
||||
nix = {
|
||||
distributedBuilds = true;
|
||||
settings.builders-use-substitutes = true;
|
||||
#
|
||||
# nixpkgs
|
||||
#
|
||||
{
|
||||
# affect the generated nix.conf, doesn't need to be turned off during nixos-install
|
||||
nix = {
|
||||
distributedBuilds = true;
|
||||
settings.builders-use-substitutes = true;
|
||||
};
|
||||
|
||||
nixpkgs = {
|
||||
config = {
|
||||
# For btop, ROCm support is needed for AMD GPU
|
||||
# https://github.com/aristocratos/btop?tab=readme-ov-file#gpu-compatibility
|
||||
rocmSupport = true;
|
||||
};
|
||||
|
||||
nixpkgs = {
|
||||
config = {
|
||||
# For btop, ROCm support is needed for AMD GPU
|
||||
# https://github.com/aristocratos/btop?tab=readme-ov-file#gpu-compatibility
|
||||
rocmSupport = true;
|
||||
};
|
||||
overlays = map import [
|
||||
../overlays/agenix.nix
|
||||
../overlays/disko.nix
|
||||
../overlays/nur.nix
|
||||
../overlays/wired-notify.nix
|
||||
../overlays/nix-tree.nix
|
||||
../overlays/wallpapers.nix
|
||||
../overlays/nil.nix
|
||||
../overlays/dix.nix
|
||||
../overlays/eepy.nix
|
||||
../overlays/calibre-no-mime.nix
|
||||
../overlays/fcitx5-table-extra-taiwanese.nix
|
||||
|
||||
overlays = map import [
|
||||
../overlays/agenix.nix
|
||||
../overlays/disko.nix
|
||||
../overlays/nur.nix
|
||||
../overlays/wired-notify.nix
|
||||
../overlays/nix-tree.nix
|
||||
../overlays/wallpapers.nix
|
||||
../overlays/nil.nix
|
||||
../overlays/dix.nix
|
||||
../overlays/eepy.nix
|
||||
../overlays/calibre-no-mime.nix
|
||||
../overlays/fcitx5-table-extra-taiwanese.nix
|
||||
../overlays/iosevka.nix
|
||||
../packages/overlay.nix
|
||||
|
||||
../overlays/iosevka.nix
|
||||
../packages/overlay.nix
|
||||
./vanadium/overlay.nix
|
||||
./vanadium/kernel-overlay.nix
|
||||
|
||||
./vanadium/overlay.nix
|
||||
./vanadium/kernel-overlay.nix
|
||||
# removed, but I need it for PLFA!
|
||||
../overlays/pin-emacs28.nix
|
||||
|
||||
# removed, but I need it for PLFA!
|
||||
../overlays/pin-emacs28.nix
|
||||
|
||||
# use lix everywhere and wrap it with nom
|
||||
../overlays/lix.nix
|
||||
../overlays/nix-monitored.nix
|
||||
];
|
||||
|
||||
# Set NIX_PATH and flake registry at the same time
|
||||
# https://github.com/NixOS/nixpkgs/pull/254405
|
||||
flake.source = sources.nixpkgs;
|
||||
};
|
||||
|
||||
nix.package = pkgs.nix-monitored;
|
||||
|
||||
system.nixos.version = lib.substring 0 8 sources.nixpkgs.revision;
|
||||
}
|
||||
|
||||
#
|
||||
# NixOS modules
|
||||
#
|
||||
./vanadium/nixos/hardware-configuration.nix # generated
|
||||
./vanadium/nixos/fs.nix
|
||||
./vanadium/nixos/restic.nix
|
||||
|
||||
./vanadium/nixos/battery.nix
|
||||
|
||||
./vanadium/nixos/audio.nix
|
||||
./vanadium/nixos/connectivity.nix
|
||||
./vanadium/nixos/input.nix
|
||||
|
||||
./vanadium/nixos/misc.nix
|
||||
|
||||
./vanadium/nixos/display.nix
|
||||
./vanadium/nixos/gui.nix
|
||||
|
||||
./vanadium/nixos/locale.nix
|
||||
./vanadium/nixos/unfree-predicate.nix
|
||||
./vanadium/nixos/programs.nix
|
||||
|
||||
../nixosModules/common/fish.nix
|
||||
../nixosModules/common/disable-command-not-found.nix
|
||||
../nixosModules/common/network.nix
|
||||
../nixosModules/common/sudo-conf.nix
|
||||
../nixosModules/common/system-nixconf.nix
|
||||
../nixosModules/common/xscreensaver.nix
|
||||
|
||||
# QUIRK:
|
||||
# Had issue when building the installer as it fails to bootstrap itself
|
||||
# Might be useful to disable for the first build.
|
||||
# ../nixosModules/extra/secure_dns.nix
|
||||
../nixosModules/extra/zram.nix
|
||||
../nixosModules/extra/leana.nix
|
||||
|
||||
#
|
||||
# Extern modules
|
||||
#
|
||||
(sources.disko + "/module.nix")
|
||||
../disko/vanadium/btrfs.nix
|
||||
|
||||
(sources.agenix + "/modules/age.nix")
|
||||
|
||||
(import sources.url-eater).nixosModules.default
|
||||
|
||||
(sources.nixos-hardware + "/framework/13-inch/7040-amd")
|
||||
|
||||
#
|
||||
# home-manager
|
||||
#
|
||||
(sources.home-manager + "/nixos")
|
||||
{
|
||||
home-manager = {
|
||||
useGlobalPkgs = true;
|
||||
useUserPackages = true;
|
||||
sharedModules = [{home.stateVersion = lib.mkDefault config.system.stateVersion;}];
|
||||
};
|
||||
|
||||
hm.imports = [
|
||||
#
|
||||
# hostname
|
||||
#
|
||||
{_module.args = {inherit hostname;};}
|
||||
|
||||
#
|
||||
# home modules
|
||||
#
|
||||
./vanadium/home/programs.nix
|
||||
./vanadium/home/misc.nix
|
||||
|
||||
./vanadium/home/firefox.nix
|
||||
./vanadium/home/xmobar.nix
|
||||
|
||||
# Language server packages, etc
|
||||
./vanadium/home/dev.nix
|
||||
|
||||
../homeModules/common/btop
|
||||
../homeModules/common/cmus
|
||||
../homeModules/common/fcitx5
|
||||
../homeModules/common/fish
|
||||
../homeModules/common/nushell.nix
|
||||
../homeModules/common/starship
|
||||
../homeModules/common/tmux
|
||||
../homeModules/common/vim
|
||||
../homeModules/common/wired
|
||||
../homeModules/common/atuin.nix
|
||||
../homeModules/common/direnv.nix
|
||||
../homeModules/common/feh.nix
|
||||
../homeModules/common/firefox.nix
|
||||
../homeModules/common/fzf.nix
|
||||
../homeModules/common/git.nix
|
||||
../homeModules/common/gpg.nix
|
||||
../homeModules/common/kitty.nix
|
||||
../homeModules/common/leana.nix
|
||||
../homeModules/common/locale.nix
|
||||
../homeModules/common/lazygit.nix
|
||||
../homeModules/common/packages.nix
|
||||
../homeModules/common/password-store.nix
|
||||
../homeModules/common/sioyek.nix
|
||||
../homeModules/common/tealdeer.nix
|
||||
../homeModules/common/user-nixconf.nix
|
||||
|
||||
../homeModules/extra/tmux-fish-integration.nix
|
||||
|
||||
#
|
||||
# Extern modules
|
||||
#
|
||||
(sources.agenix + "/modules/age-home.nix")
|
||||
(import sources.wired-notify).homeManagerModules.default
|
||||
# use lix everywhere and wrap it with nom
|
||||
../overlays/lix.nix
|
||||
../overlays/nix-monitored.nix
|
||||
];
|
||||
}
|
||||
|
||||
#
|
||||
# Secrets
|
||||
#
|
||||
{
|
||||
# Set NIX_PATH and flake registry at the same time
|
||||
# https://github.com/NixOS/nixpkgs/pull/254405
|
||||
flake.source = sources.nixpkgs;
|
||||
};
|
||||
|
||||
nix.package = pkgs.nix-monitored;
|
||||
|
||||
system.nixos.version = lib.substring 0 8 sources.nixpkgs.revision;
|
||||
}
|
||||
|
||||
#
|
||||
# NixOS modules
|
||||
#
|
||||
./vanadium/nixos/hardware-configuration.nix # generated
|
||||
./vanadium/nixos/fs.nix
|
||||
./vanadium/nixos/restic.nix
|
||||
|
||||
./vanadium/nixos/battery.nix
|
||||
|
||||
./vanadium/nixos/audio.nix
|
||||
./vanadium/nixos/connectivity.nix
|
||||
./vanadium/nixos/input.nix
|
||||
|
||||
./vanadium/nixos/misc.nix
|
||||
|
||||
./vanadium/nixos/display.nix
|
||||
./vanadium/nixos/gui.nix
|
||||
|
||||
./vanadium/nixos/locale.nix
|
||||
./vanadium/nixos/unfree-predicate.nix
|
||||
./vanadium/nixos/programs.nix
|
||||
|
||||
../nixosModules/common/fish.nix
|
||||
../nixosModules/common/disable-command-not-found.nix
|
||||
../nixosModules/common/network.nix
|
||||
../nixosModules/common/sudo-conf.nix
|
||||
../nixosModules/common/system-nixconf.nix
|
||||
../nixosModules/common/xscreensaver.nix
|
||||
|
||||
# QUIRK:
|
||||
# Had issue when building the installer as it fails to bootstrap itself
|
||||
# Might be useful to disable for the first build.
|
||||
# ../nixosModules/extra/secure_dns.nix
|
||||
../nixosModules/extra/zram.nix
|
||||
../nixosModules/extra/leana.nix
|
||||
|
||||
#
|
||||
# Extern modules
|
||||
#
|
||||
(sources.disko + "/module.nix")
|
||||
../disko/vanadium/btrfs.nix
|
||||
|
||||
(sources.agenix + "/modules/age.nix")
|
||||
|
||||
(import sources.url-eater).nixosModules.default
|
||||
|
||||
(sources.nixos-hardware + "/framework/13-inch/7040-amd")
|
||||
|
||||
#
|
||||
# home-manager
|
||||
#
|
||||
(sources.home-manager + "/nixos")
|
||||
{
|
||||
home-manager = {
|
||||
useGlobalPkgs = true;
|
||||
useUserPackages = true;
|
||||
sharedModules = [ { home.stateVersion = lib.mkDefault config.system.stateVersion; } ];
|
||||
};
|
||||
|
||||
hm.imports = [
|
||||
#
|
||||
# hostname
|
||||
#
|
||||
{ _module.args = { inherit hostname; }; }
|
||||
|
||||
#
|
||||
# home modules
|
||||
#
|
||||
./vanadium/home/programs.nix
|
||||
./vanadium/home/misc.nix
|
||||
|
||||
./vanadium/home/firefox.nix
|
||||
./vanadium/home/xmobar.nix
|
||||
|
||||
# Language server packages, etc
|
||||
./vanadium/home/dev.nix
|
||||
|
||||
../homeModules/common/btop
|
||||
../homeModules/common/cmus
|
||||
../homeModules/common/fcitx5
|
||||
../homeModules/common/fish
|
||||
../homeModules/common/nushell.nix
|
||||
../homeModules/common/starship
|
||||
../homeModules/common/tmux
|
||||
../homeModules/common/vim
|
||||
../homeModules/common/wired
|
||||
../homeModules/common/atuin.nix
|
||||
../homeModules/common/direnv.nix
|
||||
../homeModules/common/feh.nix
|
||||
../homeModules/common/firefox.nix
|
||||
../homeModules/common/fzf.nix
|
||||
../homeModules/common/git.nix
|
||||
../homeModules/common/gpg.nix
|
||||
../homeModules/common/kitty.nix
|
||||
../homeModules/common/leana.nix
|
||||
../homeModules/common/locale.nix
|
||||
../homeModules/common/lazygit.nix
|
||||
../homeModules/common/packages.nix
|
||||
../homeModules/common/password-store.nix
|
||||
../homeModules/common/sioyek.nix
|
||||
../homeModules/common/tealdeer.nix
|
||||
../homeModules/common/user-nixconf.nix
|
||||
|
||||
../homeModules/extra/tmux-fish-integration.nix
|
||||
|
||||
#
|
||||
# Extern modules
|
||||
#
|
||||
(sources.agenix + "/modules/age-home.nix")
|
||||
(import sources.wired-notify).homeManagerModules.default
|
||||
];
|
||||
}
|
||||
|
||||
#
|
||||
# Secrets
|
||||
#
|
||||
{
|
||||
age.secrets = {
|
||||
wpa_password.file = "${../secrets/wpa_password.age}";
|
||||
|
||||
restic_backblaze_pwd.file = "${../secrets/restic_backblaze_pwd.age}";
|
||||
restic_backblaze_repo.file = "${../secrets/restic_backblaze_repo.age}";
|
||||
restic_backblaze_env.file = "${../secrets/restic_backblaze_env.age}";
|
||||
|
||||
four_pwd.file = "${../secrets/four_pwd.age}";
|
||||
restic_four_pwd.file = "${../secrets/restic_four_pwd.age}";
|
||||
|
||||
sgbk_pwd.file = "${../secrets/sgbk_pwd.age}";
|
||||
restic_sgbk_pwd.file = "${../secrets/restic_sgbk_pwd.age}";
|
||||
|
||||
two_pwd.file = "${../secrets/two_pwd.age}";
|
||||
};
|
||||
|
||||
hm = {
|
||||
age.secrets = {
|
||||
wpa_password.file = "${../secrets/wpa_password.age}";
|
||||
|
||||
restic_backblaze_pwd.file = "${../secrets/restic_backblaze_pwd.age}";
|
||||
restic_backblaze_repo.file = "${../secrets/restic_backblaze_repo.age}";
|
||||
restic_backblaze_env.file = "${../secrets/restic_backblaze_env.age}";
|
||||
|
||||
four_pwd.file = "${../secrets/four_pwd.age}";
|
||||
restic_four_pwd.file = "${../secrets/restic_four_pwd.age}";
|
||||
|
||||
sgbk_pwd.file = "${../secrets/sgbk_pwd.age}";
|
||||
restic_sgbk_pwd.file = "${../secrets/restic_sgbk_pwd.age}";
|
||||
|
||||
two_pwd.file = "${../secrets/two_pwd.age}";
|
||||
};
|
||||
|
||||
hm = {
|
||||
age.secrets = {
|
||||
sshconfig = {
|
||||
file = "${../secrets/sshconfig.age}";
|
||||
path = "/home/leana/.ssh/config";
|
||||
};
|
||||
iambconfig = {
|
||||
file = "${../secrets/iambconfig.age}";
|
||||
path = "/home/leana/.config/iamb/config.toml";
|
||||
};
|
||||
sshconfig = {
|
||||
file = "${../secrets/sshconfig.age}";
|
||||
path = "/home/leana/.ssh/config";
|
||||
};
|
||||
iambconfig = {
|
||||
file = "${../secrets/iambconfig.age}";
|
||||
path = "/home/leana/.config/iamb/config.toml";
|
||||
};
|
||||
};
|
||||
}
|
||||
];
|
||||
}
|
||||
};
|
||||
}
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,7 +3,8 @@
|
|||
lib,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
{
|
||||
home.packages = [
|
||||
# preview markdown
|
||||
pkgs.python3Packages.grip
|
||||
|
|
@ -42,10 +43,11 @@
|
|||
"haskell/cabal"
|
||||
];
|
||||
};
|
||||
includes = let
|
||||
fromList = import ../../../git-identities/git-compat.nix;
|
||||
identities = import ../../../git-identities/list.nix;
|
||||
in
|
||||
includes =
|
||||
let
|
||||
fromList = import ../../../git-identities/git-compat.nix;
|
||||
identities = import ../../../git-identities/list.nix;
|
||||
in
|
||||
fromList identities;
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -2,9 +2,11 @@
|
|||
pkgs,
|
||||
config,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (pkgs) nur;
|
||||
in {
|
||||
in
|
||||
{
|
||||
programs.firefox = {
|
||||
enable = true;
|
||||
|
||||
|
|
@ -106,26 +108,29 @@ in {
|
|||
font-family: monospace;
|
||||
}
|
||||
'';
|
||||
extensions.packages = let
|
||||
addons = nur.repos.rycee.firefox-addons;
|
||||
in [
|
||||
addons.sponsorblock
|
||||
addons.return-youtube-dislikes
|
||||
addons.consent-o-matic
|
||||
];
|
||||
extensions.packages =
|
||||
let
|
||||
addons = nur.repos.rycee.firefox-addons;
|
||||
in
|
||||
[
|
||||
addons.sponsorblock
|
||||
addons.return-youtube-dislikes
|
||||
addons.consent-o-matic
|
||||
];
|
||||
};
|
||||
|
||||
junk = {
|
||||
id = 1;
|
||||
inherit
|
||||
(config.programs.firefox.profiles.default)
|
||||
inherit (config.programs.firefox.profiles.default)
|
||||
settings
|
||||
userChrome
|
||||
;
|
||||
|
||||
extensions.packages = let
|
||||
addons = nur.repos.rycee.firefox-addons;
|
||||
in [addons.multi-account-containers];
|
||||
extensions.packages =
|
||||
let
|
||||
addons = nur.repos.rycee.firefox-addons;
|
||||
in
|
||||
[ addons.multi-account-containers ];
|
||||
|
||||
containers = {
|
||||
raisin = {
|
||||
|
|
@ -144,15 +149,16 @@ in {
|
|||
# Isolate it because it's proprietary
|
||||
tampermonkey = {
|
||||
id = 2;
|
||||
inherit
|
||||
(config.programs.firefox.profiles.default)
|
||||
inherit (config.programs.firefox.profiles.default)
|
||||
settings
|
||||
userChrome
|
||||
;
|
||||
|
||||
extensions.packages = let
|
||||
addons = nur.repos.rycee.firefox-addons;
|
||||
in [addons.tampermonkey];
|
||||
extensions.packages =
|
||||
let
|
||||
addons = nur.repos.rycee.firefox-addons;
|
||||
in
|
||||
[ addons.tampermonkey ];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
|||
|
|
@ -1,19 +1,23 @@
|
|||
{
|
||||
pkgs,
|
||||
lib,
|
||||
nixosConfig ? {},
|
||||
nixosConfig ? { },
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
{
|
||||
#
|
||||
# fonts
|
||||
#
|
||||
fonts.fontconfig = {
|
||||
enable = true;
|
||||
defaultFonts = lib.mapAttrsRecursive (_: v: v ++ ["Last Resort"]) {
|
||||
sansSerif = ["Ubuntu" "Noto Sans CJK TC"];
|
||||
serif = ["Noto Serif CJK TC"];
|
||||
monospace = ["Iosevka"];
|
||||
emoji = ["Noto Color Emoji"];
|
||||
defaultFonts = lib.mapAttrsRecursive (_: v: v ++ [ "Last Resort" ]) {
|
||||
sansSerif = [
|
||||
"Ubuntu"
|
||||
"Noto Sans CJK TC"
|
||||
];
|
||||
serif = [ "Noto Serif CJK TC" ];
|
||||
monospace = [ "Iosevka" ];
|
||||
emoji = [ "Noto Color Emoji" ];
|
||||
};
|
||||
};
|
||||
home.packages = [
|
||||
|
|
@ -39,8 +43,7 @@
|
|||
x11.enable = true;
|
||||
gtk.enable = true;
|
||||
|
||||
inherit
|
||||
(nixosConfig.services.xserver.displayManager.lightdm.greeters.gtk.cursorTheme)
|
||||
inherit (nixosConfig.services.xserver.displayManager.lightdm.greeters.gtk.cursorTheme)
|
||||
name
|
||||
package
|
||||
size
|
||||
|
|
@ -55,7 +58,7 @@
|
|||
xdg.mimeApps = {
|
||||
enable = true;
|
||||
defaultApplications = {
|
||||
"x-scheme-handler/mailto" = ["org.gnome.Evolution.desktop"];
|
||||
"x-scheme-handler/mailto" = [ "org.gnome.Evolution.desktop" ];
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,16 +3,19 @@
|
|||
lib,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
{
|
||||
home.sessionPath = [
|
||||
"${config.home.homeDirectory}/.local/bin"
|
||||
];
|
||||
|
||||
home.sessionVariables = let
|
||||
fishCfg = config.programs.fish;
|
||||
in {
|
||||
"SHELL" = lib.mkIf fishCfg.enable (lib.getExe fishCfg.package);
|
||||
};
|
||||
home.sessionVariables =
|
||||
let
|
||||
fishCfg = config.programs.fish;
|
||||
in
|
||||
{
|
||||
"SHELL" = lib.mkIf fishCfg.enable (lib.getExe fishCfg.package);
|
||||
};
|
||||
|
||||
home.packages = [
|
||||
pkgs.ghc # my favorite calculator
|
||||
|
|
@ -37,9 +40,7 @@
|
|||
# lol
|
||||
pkgs.macchanger
|
||||
|
||||
/*
|
||||
The file picker is not ergonomic enough, sadly
|
||||
*/
|
||||
# The file picker is not ergonomic enough, sadly
|
||||
# pkgs.helix
|
||||
# pkgs.nushell
|
||||
|
||||
|
|
@ -172,7 +173,7 @@
|
|||
|
||||
gnome-keyring = {
|
||||
enable = true;
|
||||
components = ["secrets"];
|
||||
components = [ "secrets" ];
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,23 +1,31 @@
|
|||
{pkgs, ...}: {
|
||||
home.packages = let
|
||||
inherit (pkgs) lib;
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
home.packages =
|
||||
let
|
||||
inherit (pkgs) lib;
|
||||
|
||||
ghc = pkgs.haskellPackages.ghc.withPackages (haskellPackages: [
|
||||
haskellPackages.xmobar
|
||||
]);
|
||||
ghc = pkgs.haskellPackages.ghc.withPackages (haskellPackages: [
|
||||
haskellPackages.xmobar
|
||||
]);
|
||||
|
||||
wrapped-xmobar = pkgs.symlinkJoin {
|
||||
name = "xmobar";
|
||||
paths = [pkgs.xmobar];
|
||||
buildInputs = [pkgs.makeWrapper];
|
||||
postBuild = ''
|
||||
wrapProgram $out/bin/xmobar \
|
||||
--prefix PATH : "${lib.makeBinPath [ghc pkgs.libnotify]}"
|
||||
'';
|
||||
};
|
||||
in [
|
||||
wrapped-xmobar
|
||||
];
|
||||
wrapped-xmobar = pkgs.symlinkJoin {
|
||||
name = "xmobar";
|
||||
paths = [ pkgs.xmobar ];
|
||||
buildInputs = [ pkgs.makeWrapper ];
|
||||
postBuild = ''
|
||||
wrapProgram $out/bin/xmobar \
|
||||
--prefix PATH : "${
|
||||
lib.makeBinPath [
|
||||
ghc
|
||||
pkgs.libnotify
|
||||
]
|
||||
}"
|
||||
'';
|
||||
};
|
||||
in
|
||||
[
|
||||
wrapped-xmobar
|
||||
];
|
||||
|
||||
xdg.configFile = {
|
||||
"xmobar" = {
|
||||
|
|
|
|||
|
|
@ -1,6 +1,8 @@
|
|||
final: prev: let
|
||||
final: prev:
|
||||
let
|
||||
inherit (final) lib;
|
||||
in {
|
||||
in
|
||||
{
|
||||
linuxPackages = final.linuxPackagesFor (
|
||||
prev.linuxPackages.kernel.override {
|
||||
# TODO: The error message is quite unintuitive, maybe improve it?
|
||||
|
|
|
|||
|
|
@ -5,5 +5,5 @@
|
|||
jack.enable = true;
|
||||
};
|
||||
|
||||
me.extraGroups = ["audio"];
|
||||
me.extraGroups = [ "audio" ];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,12 +3,16 @@
|
|||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
{
|
||||
# For nautilius and iOS
|
||||
services.gvfs.enable = true;
|
||||
# iOS
|
||||
services.usbmuxd.enable = true;
|
||||
environment.systemPackages = with pkgs; [libimobiledevice idevicerestore];
|
||||
environment.systemPackages = with pkgs; [
|
||||
libimobiledevice
|
||||
idevicerestore
|
||||
];
|
||||
|
||||
# https://unix.stackexchange.com/questions/592775/how-can-i-enable-apple-ios-fast-charge-support
|
||||
services.udev.extraRules = ''
|
||||
|
|
@ -34,10 +38,11 @@
|
|||
userControlled.enable = true;
|
||||
secretsFile = config.age.secrets.wpa_password.path;
|
||||
scanOnLowSignal = false;
|
||||
networks = let
|
||||
fromList = import ../../../networks/wpa_supplicant-compat.nix;
|
||||
networks = import ../../../networks/list.nix;
|
||||
in
|
||||
networks =
|
||||
let
|
||||
fromList = import ../../../networks/wpa_supplicant-compat.nix;
|
||||
networks = import ../../../networks/list.nix;
|
||||
in
|
||||
fromList networks;
|
||||
};
|
||||
};
|
||||
|
|
|
|||
|
|
@ -2,13 +2,14 @@
|
|||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
#
|
||||
# builtin screen
|
||||
#
|
||||
{
|
||||
me.extraGroups = ["video"];
|
||||
me.extraGroups = [ "video" ];
|
||||
programs.light.enable = true;
|
||||
}
|
||||
|
||||
|
|
@ -16,10 +17,10 @@
|
|||
# external screen
|
||||
#
|
||||
{
|
||||
me.extraGroups = ["i2c"];
|
||||
me.extraGroups = [ "i2c" ];
|
||||
hardware.i2c.enable = true;
|
||||
environment.systemPackages = [pkgs.ddcutil];
|
||||
boot.kernelModules = ["i2c-dev"];
|
||||
environment.systemPackages = [ pkgs.ddcutil ];
|
||||
boot.kernelModules = [ "i2c-dev" ];
|
||||
}
|
||||
];
|
||||
|
||||
|
|
@ -33,145 +34,160 @@
|
|||
"20_xmonad" = "${lib.getExe pkgs.haskellPackages.xmonad} --restart"; # make sure feh keeps up
|
||||
};
|
||||
|
||||
profiles = let
|
||||
singleton = k: v: {${k} = v;};
|
||||
profiles =
|
||||
let
|
||||
singleton = k: v: { ${k} = v; };
|
||||
|
||||
fingerprints = {
|
||||
built-in = singleton "eDP-1" "00ffffffffffff0009e5ca0b000000002f200104a51c137803de50a3544c99260f505400000001010101010101010101010101010101115cd01881e02d50302036001dbe1000001aa749d01881e02d50302036001dbe1000001a000000fe00424f452043510a202020202020000000fe004e4531333546424d2d4e34310a0073";
|
||||
amethyst = device: singleton device "00ffffffffffff0006b35b27010101012c210103803c22782a29d5ad4f44a7240f5054bfef00714f81809500d1c0d1e8d1fc01010101565e00a0a0a029503020350055502100001a000000fd0030901edf3c000a202020202020000000fc005647323741514c33410a202020000000ff0052414c4d51533139373533370a0111020347f14a90030204014061603f1f230907078301000067030c002000384468d85dc401788003026d1a000002013090f00069096909e305ff01e6060701696900e2006ae20fc0eae70070a0a067500820980455502100001a6fc200a0a0a055503020350055502100001a5aa000a0a0a046503020350055502100001a0000bc";
|
||||
orchid = device: singleton device "00ffffffffffff0004699a24642900002416010380341d782a2ac5a4564f9e280f5054b7ef00714f814081809500b300d1c081c08100023a801871382d40582c450009252100001e000000ff0043394c4d54463031303539360a000000fd00324b185311000a202020202020000000fc00415355532056533234370a20200173020322714f0102031112130414050e0f1d1e1f10230917078301000065030c0010008c0ad08a20e02d10103e9600092521000018011d007251d01e206e28550009252100001e011d00bc52d01e20b828554009252100001e8c0ad090204031200c4055000925210000180000000000000000000000000000000000000000005d";
|
||||
};
|
||||
fingerprints = {
|
||||
built-in = singleton "eDP-1" "00ffffffffffff0009e5ca0b000000002f200104a51c137803de50a3544c99260f505400000001010101010101010101010101010101115cd01881e02d50302036001dbe1000001aa749d01881e02d50302036001dbe1000001a000000fe00424f452043510a202020202020000000fe004e4531333546424d2d4e34310a0073";
|
||||
amethyst =
|
||||
device:
|
||||
singleton device "00ffffffffffff0006b35b27010101012c210103803c22782a29d5ad4f44a7240f5054bfef00714f81809500d1c0d1e8d1fc01010101565e00a0a0a029503020350055502100001a000000fd0030901edf3c000a202020202020000000fc005647323741514c33410a202020000000ff0052414c4d51533139373533370a0111020347f14a90030204014061603f1f230907078301000067030c002000384468d85dc401788003026d1a000002013090f00069096909e305ff01e6060701696900e2006ae20fc0eae70070a0a067500820980455502100001a6fc200a0a0a055503020350055502100001a5aa000a0a0a046503020350055502100001a0000bc";
|
||||
orchid =
|
||||
device:
|
||||
singleton device "00ffffffffffff0004699a24642900002416010380341d782a2ac5a4564f9e280f5054b7ef00714f814081809500b300d1c081c08100023a801871382d40582c450009252100001e000000ff0043394c4d54463031303539360a000000fd00324b185311000a202020202020000000fc00415355532056533234370a20200173020322714f0102031112130414050e0f1d1e1f10230917078301000065030c0010008c0ad08a20e02d10103e9600092521000018011d007251d01e206e28550009252100001e011d00bc52d01e20b828554009252100001e8c0ad090204031200c4055000925210000180000000000000000000000000000000000000000005d";
|
||||
};
|
||||
|
||||
devices = rec {
|
||||
built-in = "eDP-1";
|
||||
# Run `xrandr` to see the max number
|
||||
extern = map (portNumber: "DP-${toString portNumber}") (lib.range 1 8);
|
||||
all = [built-in] ++ extern;
|
||||
};
|
||||
devices = rec {
|
||||
built-in = "eDP-1";
|
||||
# Run `xrandr` to see the max number
|
||||
extern = map (portNumber: "DP-${toString portNumber}") (lib.range 1 8);
|
||||
all = [ built-in ] ++ extern;
|
||||
};
|
||||
|
||||
switches = {
|
||||
setDPI = {dpi}:
|
||||
singleton "10_xrdb-dpi" "${lib.getExe pkgs.xorg.xrdb} -merge ${pkgs.writeText "xrdb-dpi-config" ''
|
||||
Xcursor.size: 64
|
||||
Xft.dpi: ${toString dpi}
|
||||
''}";
|
||||
switches = {
|
||||
setDPI =
|
||||
{ dpi }:
|
||||
singleton "10_xrdb-dpi" "${lib.getExe pkgs.xorg.xrdb} -merge ${pkgs.writeText "xrdb-dpi-config" ''
|
||||
Xcursor.size: 64
|
||||
Xft.dpi: ${toString dpi}
|
||||
''}";
|
||||
|
||||
# Is scoped to an output device, no need to be called on built-in display
|
||||
setSoftwareBrightness = {
|
||||
device, # obtain with `xrandr`
|
||||
brightness, # [0..1]
|
||||
}:
|
||||
singleton "10_xrandr_brightness" ''
|
||||
${lib.getExe pkgs.xorg.xrandr} --output ${device} --brightness ${toString brightness}
|
||||
'';
|
||||
# Is scoped to an output device, no need to be called on built-in display
|
||||
setSoftwareBrightness =
|
||||
{
|
||||
device, # obtain with `xrandr`
|
||||
brightness, # [0..1]
|
||||
}:
|
||||
singleton "10_xrandr_brightness" ''
|
||||
${lib.getExe pkgs.xorg.xrandr} --output ${device} --brightness ${toString brightness}
|
||||
'';
|
||||
|
||||
# Is scoped to an output device, no need to be called on built-in display
|
||||
setDDCBrightness = {
|
||||
modelName, # obtain with `ddcutil detect`
|
||||
brightness, # [0..1]
|
||||
}:
|
||||
singleton "10_ddc_brightness" ''
|
||||
${lib.getExe pkgs.ddcutil} --model ${modelName} setvcp 10 ${toString (builtins.floor (brightness * 100))}
|
||||
'';
|
||||
# Is scoped to an output device, no need to be called on built-in display
|
||||
setDDCBrightness =
|
||||
{
|
||||
modelName, # obtain with `ddcutil detect`
|
||||
brightness, # [0..1]
|
||||
}:
|
||||
singleton "10_ddc_brightness" ''
|
||||
${lib.getExe pkgs.ddcutil} --model ${modelName} setvcp 10 ${
|
||||
toString (builtins.floor (brightness * 100))
|
||||
}
|
||||
'';
|
||||
|
||||
setDDCContrast = {
|
||||
modelName, # obtain with `ddcutil detect`
|
||||
contrast, # [0..1]
|
||||
}:
|
||||
singleton "10_ddc_contrast" ''
|
||||
${lib.getExe pkgs.ddcutil} --model ${modelName} setvcp 12 ${toString (builtins.floor (contrast * 100))}
|
||||
'';
|
||||
};
|
||||
setDDCContrast =
|
||||
{
|
||||
modelName, # obtain with `ddcutil detect`
|
||||
contrast, # [0..1]
|
||||
}:
|
||||
singleton "10_ddc_contrast" ''
|
||||
${lib.getExe pkgs.ddcutil} --model ${modelName} setvcp 12 ${
|
||||
toString (builtins.floor (contrast * 100))
|
||||
}
|
||||
'';
|
||||
};
|
||||
|
||||
# Note: the "position" field corresponds to the "pos" field outputted by autorandr
|
||||
# To get the current config, run `xrandr --auto` and then `autorandr --config`
|
||||
configs = {
|
||||
allOff = lib.genAttrs devices.all (_: {enable = lib.mkDefault false;});
|
||||
enableBuiltin = {
|
||||
eDP-1 = {
|
||||
enable = true;
|
||||
crtc = 0;
|
||||
mode = "2256x1504";
|
||||
rate = "60.00";
|
||||
primary = true;
|
||||
# Note: the "position" field corresponds to the "pos" field outputted by autorandr
|
||||
# To get the current config, run `xrandr --auto` and then `autorandr --config`
|
||||
configs = {
|
||||
allOff = lib.genAttrs devices.all (_: {
|
||||
enable = lib.mkDefault false;
|
||||
});
|
||||
enableBuiltin = {
|
||||
eDP-1 = {
|
||||
enable = true;
|
||||
crtc = 0;
|
||||
mode = "2256x1504";
|
||||
rate = "60.00";
|
||||
primary = true;
|
||||
};
|
||||
};
|
||||
enableAmethyst = name: {
|
||||
${name} = {
|
||||
enable = true;
|
||||
primary = true;
|
||||
crtc = 1;
|
||||
mode = "2560x1440";
|
||||
rate = "59.95";
|
||||
};
|
||||
};
|
||||
enableOrchid = name: {
|
||||
${name} = {
|
||||
enable = true;
|
||||
primary = true;
|
||||
crtc = 1;
|
||||
mode = "1920x1080";
|
||||
rate = "60.00";
|
||||
};
|
||||
};
|
||||
};
|
||||
enableAmethyst = name: {
|
||||
${name} = {
|
||||
enable = true;
|
||||
primary = true;
|
||||
crtc = 1;
|
||||
mode = "2560x1440";
|
||||
rate = "59.95";
|
||||
};
|
||||
|
||||
frameworkBuiltin = {
|
||||
fingerprint = fingerprints.built-in;
|
||||
config = lib.mkMerge [
|
||||
configs.allOff
|
||||
configs.enableBuiltin
|
||||
];
|
||||
hooks.postswitch = switches.setDPI { dpi = 150; };
|
||||
};
|
||||
enableOrchid = name: {
|
||||
${name} = {
|
||||
enable = true;
|
||||
primary = true;
|
||||
crtc = 1;
|
||||
mode = "1920x1080";
|
||||
rate = "60.00";
|
||||
};
|
||||
|
||||
mkAmethyst = name: {
|
||||
fingerprint = lib.mkMerge [
|
||||
fingerprints.built-in
|
||||
(fingerprints.amethyst name)
|
||||
];
|
||||
config = lib.mkMerge [
|
||||
configs.allOff
|
||||
(configs.enableAmethyst name)
|
||||
];
|
||||
hooks.postswitch = lib.mkMerge [
|
||||
(switches.setDPI { dpi = 110; })
|
||||
(switches.setSoftwareBrightness {
|
||||
device = name;
|
||||
brightness = 1;
|
||||
})
|
||||
(switches.setDDCBrightness {
|
||||
modelName = "VG27AQL3A";
|
||||
brightness = 0;
|
||||
})
|
||||
(switches.setDDCContrast {
|
||||
modelName = "VG27AQL3A";
|
||||
contrast = 0.5;
|
||||
})
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
frameworkBuiltin = {
|
||||
fingerprint = fingerprints.built-in;
|
||||
config = lib.mkMerge [
|
||||
configs.allOff
|
||||
configs.enableBuiltin
|
||||
];
|
||||
hooks.postswitch = switches.setDPI {dpi = 150;};
|
||||
};
|
||||
|
||||
mkAmethyst = name: {
|
||||
fingerprint = lib.mkMerge [
|
||||
fingerprints.built-in
|
||||
(fingerprints.amethyst name)
|
||||
];
|
||||
config = lib.mkMerge [
|
||||
configs.allOff
|
||||
(configs.enableAmethyst name)
|
||||
];
|
||||
hooks.postswitch = lib.mkMerge [
|
||||
(switches.setDPI {dpi = 110;})
|
||||
(switches.setSoftwareBrightness {
|
||||
device = name;
|
||||
brightness = 1;
|
||||
})
|
||||
(switches.setDDCBrightness {
|
||||
modelName = "VG27AQL3A";
|
||||
brightness = 0;
|
||||
})
|
||||
(switches.setDDCContrast {
|
||||
modelName = "VG27AQL3A";
|
||||
contrast = 0.5;
|
||||
})
|
||||
];
|
||||
};
|
||||
|
||||
mkOrchid = name: {
|
||||
fingerprint = lib.mkMerge [
|
||||
fingerprints.built-in
|
||||
(fingerprints.orchid name)
|
||||
];
|
||||
config = lib.mkMerge [
|
||||
configs.allOff
|
||||
(configs.enableOrchid name)
|
||||
];
|
||||
# seems like this display doesn't support DDC
|
||||
hooks.postswitch = lib.mkMerge [
|
||||
(switches.setDPI {dpi = 100;})
|
||||
(switches.setSoftwareBrightness {
|
||||
device = name;
|
||||
brightness = 0.5;
|
||||
})
|
||||
];
|
||||
};
|
||||
in
|
||||
mkOrchid = name: {
|
||||
fingerprint = lib.mkMerge [
|
||||
fingerprints.built-in
|
||||
(fingerprints.orchid name)
|
||||
];
|
||||
config = lib.mkMerge [
|
||||
configs.allOff
|
||||
(configs.enableOrchid name)
|
||||
];
|
||||
# seems like this display doesn't support DDC
|
||||
hooks.postswitch = lib.mkMerge [
|
||||
(switches.setDPI { dpi = 100; })
|
||||
(switches.setSoftwareBrightness {
|
||||
device = name;
|
||||
brightness = 0.5;
|
||||
})
|
||||
];
|
||||
};
|
||||
in
|
||||
lib.mkMerge [
|
||||
{default = frameworkBuiltin;}
|
||||
{ default = frameworkBuiltin; }
|
||||
(lib.genAttrs' devices.extern (name: lib.nameValuePair "amethyst-${name}" (mkAmethyst name)))
|
||||
(lib.genAttrs' devices.extern (name: lib.nameValuePair "orchid-${name}" (mkOrchid name)))
|
||||
];
|
||||
|
|
|
|||
|
|
@ -2,7 +2,8 @@
|
|||
config,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
{
|
||||
services.btrfs.autoScrub = {
|
||||
enable = true;
|
||||
fileSystems = [
|
||||
|
|
@ -21,9 +22,9 @@
|
|||
|
||||
fileSystems = {
|
||||
/*
|
||||
WARNING:
|
||||
Use "noauto" if you want to mount the drive at a later time and not all the time
|
||||
Otherwise the mount would fail and cascade into the graphical session being stopped
|
||||
WARNING:
|
||||
Use "noauto" if you want to mount the drive at a later time and not all the time
|
||||
Otherwise the mount would fail and cascade into the graphical session being stopped
|
||||
*/
|
||||
|
||||
"/home/leana/mnt/tdk32" = {
|
||||
|
|
@ -53,21 +54,23 @@
|
|||
sgbk /dev/disk/by-uuid/21b5207e-c3cf-49da-b944-fb405ae1eee2 ${config.age.secrets.sgbk_pwd.path} noauto
|
||||
'';
|
||||
|
||||
systemd.mounts = let
|
||||
bindToCryptDev = dev: {
|
||||
what = "/dev/mapper/${dev}";
|
||||
where = "/mnt/${dev}";
|
||||
unitConfig = {
|
||||
Requires = ["systemd-cryptsetup@${dev}.service"];
|
||||
After = ["systemd-cryptsetup@${dev}.service"];
|
||||
PropagatesStopTo = ["systemd-cryptsetup@${dev}.service"];
|
||||
systemd.mounts =
|
||||
let
|
||||
bindToCryptDev = dev: {
|
||||
what = "/dev/mapper/${dev}";
|
||||
where = "/mnt/${dev}";
|
||||
unitConfig = {
|
||||
Requires = [ "systemd-cryptsetup@${dev}.service" ];
|
||||
After = [ "systemd-cryptsetup@${dev}.service" ];
|
||||
PropagatesStopTo = [ "systemd-cryptsetup@${dev}.service" ];
|
||||
};
|
||||
};
|
||||
};
|
||||
in [
|
||||
(bindToCryptDev "four")
|
||||
(bindToCryptDev "two")
|
||||
(bindToCryptDev "sgbk")
|
||||
];
|
||||
in
|
||||
[
|
||||
(bindToCryptDev "four")
|
||||
(bindToCryptDev "two")
|
||||
(bindToCryptDev "sgbk")
|
||||
];
|
||||
|
||||
environment.systemPackages = [
|
||||
pkgs.lsof
|
||||
|
|
|
|||
|
|
@ -2,7 +2,8 @@
|
|||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
{
|
||||
services.xserver.windowManager.xmonad = {
|
||||
enable = true;
|
||||
enableContribAndExtras = true;
|
||||
|
|
|
|||
|
|
@ -7,15 +7,20 @@
|
|||
pkgs,
|
||||
modulesPath,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "thunderbolt"];
|
||||
boot.initrd.kernelModules = ["dm-snapshot"];
|
||||
boot.kernelModules = ["kvm-amd"];
|
||||
boot.extraModulePackages = [];
|
||||
boot.initrd.availableKernelModules = [
|
||||
"nvme"
|
||||
"xhci_pci"
|
||||
"thunderbolt"
|
||||
];
|
||||
boot.initrd.kernelModules = [ "dm-snapshot" ];
|
||||
boot.kernelModules = [ "kvm-amd" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
# 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
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@
|
|||
};
|
||||
};
|
||||
|
||||
me.extraGroups = ["scanner"];
|
||||
me.extraGroups = [ "scanner" ];
|
||||
hardware.sane = {
|
||||
enable = true;
|
||||
brscan5.enable = true;
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
{lib, ...}: {
|
||||
{ lib, ... }:
|
||||
{
|
||||
# https://en.wikipedia.org/wiki/List_of_tz_database_time_zones
|
||||
# `timedatectl list-timezones`
|
||||
time.timeZone = "Asia/Taipei";
|
||||
|
|
@ -28,16 +29,16 @@
|
|||
let
|
||||
genLocale = locale: lib.flip lib.genAttrs (_: locale);
|
||||
in
|
||||
# - xscreensaver freaks out on the time display
|
||||
# - evolution add event becomes hard to use
|
||||
# https://gitlab.gnome.org/GNOME/evolution/-/issues/3120
|
||||
genLocale "fr_FR.UTF-8" [
|
||||
"LC_TIME"
|
||||
]
|
||||
// genLocale "zh_TW.UTF-8" [
|
||||
"LC_MONETARY"
|
||||
"LC_ADDRESS"
|
||||
];
|
||||
# - xscreensaver freaks out on the time display
|
||||
# - evolution add event becomes hard to use
|
||||
# https://gitlab.gnome.org/GNOME/evolution/-/issues/3120
|
||||
genLocale "fr_FR.UTF-8" [
|
||||
"LC_TIME"
|
||||
]
|
||||
// genLocale "zh_TW.UTF-8" [
|
||||
"LC_MONETARY"
|
||||
"LC_ADDRESS"
|
||||
];
|
||||
};
|
||||
|
||||
# Wireless Regulatory Domain, uses ISO / IEC 3166 country code
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
{config, ...}: {
|
||||
{ config, ... }:
|
||||
{
|
||||
system.stateVersion = "24.11";
|
||||
|
||||
boot.loader = {
|
||||
|
|
@ -16,6 +17,6 @@
|
|||
|
||||
# Cross building
|
||||
# https://discourse.nixos.org/t/how-do-i-get-my-aarch64-linux-machine-to-build-x86-64-linux-extra-platforms-doesnt-seem-to-work/38106/2?u=leana8959
|
||||
boot.binfmt.emulatedSystems = ["aarch64-linux"];
|
||||
boot.binfmt.emulatedSystems = [ "aarch64-linux" ];
|
||||
nix.settings.extra-platforms = config.boot.binfmt.emulatedSystems;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,14 +2,15 @@
|
|||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
#
|
||||
# Docker
|
||||
#
|
||||
{
|
||||
virtualisation.docker.enable = true;
|
||||
me.extraGroups = ["docker"];
|
||||
me.extraGroups = [ "docker" ];
|
||||
}
|
||||
|
||||
# #
|
||||
|
|
|
|||
|
|
@ -1,91 +1,94 @@
|
|||
{config, ...}: {
|
||||
services.restic.backups = let
|
||||
pruneOpts = [
|
||||
"--keep-daily 7"
|
||||
"--keep-weekly 4"
|
||||
"--keep-monthly 12"
|
||||
"--keep-yearly 10"
|
||||
];
|
||||
in {
|
||||
"backblaze" = {
|
||||
paths = [
|
||||
"/home/leana/Documents"
|
||||
"/home/leana/Calibre"
|
||||
{ config, ... }:
|
||||
{
|
||||
services.restic.backups =
|
||||
let
|
||||
pruneOpts = [
|
||||
"--keep-daily 7"
|
||||
"--keep-weekly 4"
|
||||
"--keep-monthly 12"
|
||||
"--keep-yearly 10"
|
||||
];
|
||||
in
|
||||
{
|
||||
"backblaze" = {
|
||||
paths = [
|
||||
"/home/leana/Documents"
|
||||
"/home/leana/Calibre"
|
||||
];
|
||||
|
||||
passwordFile = config.age.secrets.restic_backblaze_pwd.path;
|
||||
repositoryFile = config.age.secrets.restic_backblaze_repo.path;
|
||||
environmentFile = config.age.secrets.restic_backblaze_env.path;
|
||||
passwordFile = config.age.secrets.restic_backblaze_pwd.path;
|
||||
repositoryFile = config.age.secrets.restic_backblaze_repo.path;
|
||||
environmentFile = config.age.secrets.restic_backblaze_env.path;
|
||||
|
||||
timerConfig = {
|
||||
OnCalendar = "daily";
|
||||
Persistent = true;
|
||||
RandomizedDelaySec = "1h";
|
||||
timerConfig = {
|
||||
OnCalendar = "daily";
|
||||
Persistent = true;
|
||||
RandomizedDelaySec = "1h";
|
||||
};
|
||||
|
||||
inherit pruneOpts;
|
||||
};
|
||||
|
||||
inherit pruneOpts;
|
||||
"four" = {
|
||||
paths = [
|
||||
"/home/leana/Music"
|
||||
"/home/leana/Documents"
|
||||
"/home/leana/Calibre"
|
||||
"/home/leana/Images"
|
||||
];
|
||||
|
||||
repository = "/mnt/four/restic";
|
||||
passwordFile = config.age.secrets.restic_four_pwd.path;
|
||||
|
||||
timerConfig = null;
|
||||
|
||||
inherit pruneOpts;
|
||||
};
|
||||
|
||||
"sgbk" = {
|
||||
paths = [
|
||||
"/home/leana/Music"
|
||||
"/home/leana/Documents"
|
||||
"/home/leana/Calibre"
|
||||
"/home/leana/Images"
|
||||
];
|
||||
|
||||
timerConfig = null;
|
||||
|
||||
repository = "/mnt/sgbk/restic";
|
||||
passwordFile = config.age.secrets.restic_sgbk_pwd.path;
|
||||
|
||||
inherit pruneOpts;
|
||||
};
|
||||
|
||||
"two-to-four" = {
|
||||
paths = [ "/mnt/two" ];
|
||||
|
||||
timerConfig = null;
|
||||
|
||||
repository = "/mnt/four/restic";
|
||||
passwordFile = config.age.secrets.restic_four_pwd.path;
|
||||
|
||||
exclude = [ "lost+found" ];
|
||||
|
||||
inherit pruneOpts;
|
||||
};
|
||||
};
|
||||
|
||||
"four" = {
|
||||
paths = [
|
||||
"/home/leana/Music"
|
||||
"/home/leana/Documents"
|
||||
"/home/leana/Calibre"
|
||||
"/home/leana/Images"
|
||||
];
|
||||
|
||||
repository = "/mnt/four/restic";
|
||||
passwordFile = config.age.secrets.restic_four_pwd.path;
|
||||
|
||||
timerConfig = null;
|
||||
|
||||
inherit pruneOpts;
|
||||
};
|
||||
|
||||
"sgbk" = {
|
||||
paths = [
|
||||
"/home/leana/Music"
|
||||
"/home/leana/Documents"
|
||||
"/home/leana/Calibre"
|
||||
"/home/leana/Images"
|
||||
];
|
||||
|
||||
timerConfig = null;
|
||||
|
||||
repository = "/mnt/sgbk/restic";
|
||||
passwordFile = config.age.secrets.restic_sgbk_pwd.path;
|
||||
|
||||
inherit pruneOpts;
|
||||
};
|
||||
|
||||
"two-to-four" = {
|
||||
paths = ["/mnt/two"];
|
||||
|
||||
timerConfig = null;
|
||||
|
||||
repository = "/mnt/four/restic";
|
||||
passwordFile = config.age.secrets.restic_four_pwd.path;
|
||||
|
||||
exclude = ["lost+found"];
|
||||
|
||||
inherit pruneOpts;
|
||||
};
|
||||
};
|
||||
|
||||
systemd.services = {
|
||||
# TODO:
|
||||
# Wait for upstream to introduce direct access to unitConfig
|
||||
# c.f. https://github.com/NixOS/nixpkgs/pull/368234
|
||||
"restic-backups-four" = {
|
||||
requires = ["mnt-four.mount"];
|
||||
after = ["mnt-four.mount"];
|
||||
unitConfig.PropagatesStopTo = ["mnt-four.mount"];
|
||||
requires = [ "mnt-four.mount" ];
|
||||
after = [ "mnt-four.mount" ];
|
||||
unitConfig.PropagatesStopTo = [ "mnt-four.mount" ];
|
||||
};
|
||||
|
||||
"restic-backups-sgbk" = {
|
||||
requires = ["mnt-sgbk.mount"];
|
||||
after = ["mnt-sgbk.mount"];
|
||||
unitConfig.PropagatesStopTo = ["mnt-sgbk.mount"];
|
||||
requires = [ "mnt-sgbk.mount" ];
|
||||
after = [ "mnt-sgbk.mount" ];
|
||||
unitConfig.PropagatesStopTo = [ "mnt-sgbk.mount" ];
|
||||
};
|
||||
|
||||
"restic-backups-two-to-four" = {
|
||||
|
|
|
|||
|
|
@ -1,27 +1,29 @@
|
|||
{lib, ...}: {
|
||||
{ lib, ... }:
|
||||
{
|
||||
nixpkgs.config.allowUnfreePredicate = lib.mkDefault (
|
||||
pkg: let
|
||||
pkg:
|
||||
let
|
||||
name = lib.getName pkg;
|
||||
in
|
||||
builtins.elem name [
|
||||
"languagetool"
|
||||
builtins.elem name [
|
||||
"languagetool"
|
||||
|
||||
"vscode"
|
||||
"code"
|
||||
"vscode"
|
||||
"code"
|
||||
|
||||
"tampermonkey"
|
||||
"tampermonkey"
|
||||
|
||||
"aseprite"
|
||||
"aseprite"
|
||||
|
||||
"posy-cursors"
|
||||
"posy-cursors"
|
||||
|
||||
"discord"
|
||||
]
|
||||
|| builtins.any (lib.flip lib.hasInfix name) [
|
||||
# Scanner
|
||||
"brscan5"
|
||||
"discord"
|
||||
]
|
||||
|| builtins.any (lib.flip lib.hasInfix name) [
|
||||
# Scanner
|
||||
"brscan5"
|
||||
|
||||
"steam"
|
||||
]
|
||||
"steam"
|
||||
]
|
||||
);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,73 +9,75 @@ let
|
|||
|
||||
infuse = lib.flip infuse-lib.v1.infuse;
|
||||
in
|
||||
# Why shouldn't I go crazy with overlays?
|
||||
final:
|
||||
infuse {
|
||||
cmus.__input.alsaSupport = _: false;
|
||||
# Why shouldn't I go crazy with overlays?
|
||||
final:
|
||||
infuse {
|
||||
cmus.__input.alsaSupport = _: false;
|
||||
|
||||
fish.__input.usePython = _: false;
|
||||
fish.__input.usePython = _: false;
|
||||
|
||||
tmux.__input.withSixel = _: false;
|
||||
tmux.__input.withSixel = _: false;
|
||||
|
||||
vlc.__input.chromecastSupport = _: false;
|
||||
vlc.__input.waylandSupport = _: false;
|
||||
vlc.__input.chromecastSupport = _: false;
|
||||
vlc.__input.waylandSupport = _: false;
|
||||
|
||||
# I don't really use helix, but it's nice to have the W alias just in case
|
||||
helix.__output.patches.__append = [
|
||||
./patches/helix/W-as-write.patch
|
||||
];
|
||||
# I don't really use helix, but it's nice to have the W alias just in case
|
||||
helix.__output.patches.__append = [
|
||||
./patches/helix/W-as-write.patch
|
||||
];
|
||||
|
||||
# Too loud
|
||||
alejandra.__output.patches.__append = [
|
||||
./patches/alejandra/no-ads.patch
|
||||
];
|
||||
alejandra.__output.doCheck = _: false;
|
||||
# Too loud
|
||||
alejandra.__output.patches.__append = [
|
||||
./patches/alejandra/no-ads.patch
|
||||
];
|
||||
alejandra.__output.doCheck = _: false;
|
||||
|
||||
# TODO:
|
||||
# pinned branch of https://github.com/astrand/xclip/tree/xerror
|
||||
# use this until #43 gets resolved properly
|
||||
xclip.__output.src = _:
|
||||
final.fetchFromGitHub {
|
||||
owner = "astrand";
|
||||
repo = "xclip";
|
||||
rev = "2c3b811002b35d3be7f39cc1145dd06bdb32e31c";
|
||||
hash = "sha256-hHbq97GTKiRw8LZa/LY4LUOFOd/5H4+S+NR0BJfcu6M=";
|
||||
};
|
||||
# TODO:
|
||||
# pinned branch of https://github.com/astrand/xclip/tree/xerror
|
||||
# use this until #43 gets resolved properly
|
||||
xclip.__output.src =
|
||||
_:
|
||||
final.fetchFromGitHub {
|
||||
owner = "astrand";
|
||||
repo = "xclip";
|
||||
rev = "2c3b811002b35d3be7f39cc1145dd06bdb32e31c";
|
||||
hash = "sha256-hHbq97GTKiRw8LZa/LY4LUOFOd/5H4+S+NR0BJfcu6M=";
|
||||
};
|
||||
|
||||
fcitx5.__output.cmakeFlags.__append = [
|
||||
(lib.cmakeFeature "ENABLE_EMOJI" "Off")
|
||||
(lib.cmakeFeature "ENABLE_WAYLAND" "Off")
|
||||
];
|
||||
fcitx5.__output.patches.__append = [
|
||||
./patches/fcitx5/disable-clipboard.patch
|
||||
./patches/fcitx5/disable-quickphrase.patch
|
||||
./patches/fcitx5/disable-unicode.patch
|
||||
];
|
||||
fcitx5-chinese-addons.__output.cmakeFlags.__append = [
|
||||
(lib.cmakeFeature "ENABLE_BROWSER" "Off")
|
||||
(lib.cmakeFeature "ENABLE_CLOUDPINYIN" "Off")
|
||||
(lib.cmakeFeature "ENABLE_DATA" "Off")
|
||||
];
|
||||
fcitx5-chinese-addons.__output.patches.__append = [
|
||||
./patches/fcitx5-chinese-addons/disable-chttrans.patch
|
||||
./patches/fcitx5-chinese-addons/disable-fullwidth.patch
|
||||
# Note: disabling pinyin helper breaks canjie
|
||||
];
|
||||
fcitx5.__output.cmakeFlags.__append = [
|
||||
(lib.cmakeFeature "ENABLE_EMOJI" "Off")
|
||||
(lib.cmakeFeature "ENABLE_WAYLAND" "Off")
|
||||
];
|
||||
fcitx5.__output.patches.__append = [
|
||||
./patches/fcitx5/disable-clipboard.patch
|
||||
./patches/fcitx5/disable-quickphrase.patch
|
||||
./patches/fcitx5/disable-unicode.patch
|
||||
];
|
||||
fcitx5-chinese-addons.__output.cmakeFlags.__append = [
|
||||
(lib.cmakeFeature "ENABLE_BROWSER" "Off")
|
||||
(lib.cmakeFeature "ENABLE_CLOUDPINYIN" "Off")
|
||||
(lib.cmakeFeature "ENABLE_DATA" "Off")
|
||||
];
|
||||
fcitx5-chinese-addons.__output.patches.__append = [
|
||||
./patches/fcitx5-chinese-addons/disable-chttrans.patch
|
||||
./patches/fcitx5-chinese-addons/disable-fullwidth.patch
|
||||
# Note: disabling pinyin helper breaks canjie
|
||||
];
|
||||
|
||||
# Security, Xorg vuln
|
||||
# Backport has failed in upstream currently <https://github.com/NixOS/nixpkgs/pull/457804>,
|
||||
# might as well patch it while people are blogging about it <https://github.com/Xe/site/pull/1062>
|
||||
# Upstream talks about it here https://lists.x.org/archives/xorg-announce/2025-October/003635.html
|
||||
xorg.xorgserver.__output.version = oldVersion: let
|
||||
version = "21.1.20";
|
||||
in
|
||||
if oldVersion == version
|
||||
then throw "This patch has been merged upstream"
|
||||
else version;
|
||||
xorg.xorgserver.__output.src = _:
|
||||
final.fetchurl {
|
||||
url = "mirror://xorg/individual/xserver/xorg-server-21.1.20.tar.xz";
|
||||
sha256 = "sha256-dpW8YYJLOoG2utL3iwVADKAVAD3kAtGzIhFxBbcC6Tc=";
|
||||
};
|
||||
}
|
||||
# Security, Xorg vuln
|
||||
# Backport has failed in upstream currently <https://github.com/NixOS/nixpkgs/pull/457804>,
|
||||
# might as well patch it while people are blogging about it <https://github.com/Xe/site/pull/1062>
|
||||
# Upstream talks about it here https://lists.x.org/archives/xorg-announce/2025-October/003635.html
|
||||
xorg.xorgserver.__output.version =
|
||||
oldVersion:
|
||||
let
|
||||
version = "21.1.20";
|
||||
in
|
||||
if oldVersion == version then throw "This patch has been merged upstream" else version;
|
||||
xorg.xorgserver.__output.src =
|
||||
_:
|
||||
final.fetchurl {
|
||||
url = "mirror://xorg/individual/xserver/xorg-server-21.1.20.tar.xz";
|
||||
sha256 = "sha256-dpW8YYJLOoG2utL3iwVADKAVAD3kAtGzIhFxBbcC6Tc=";
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue