mirror of
https://github.com/kittywitch/nixfiles.git
synced 2026-02-09 12:29:19 -08:00
feat: work on laptop and shell stuff
This commit is contained in:
parent
a4b63004fb
commit
1071288f6e
21 changed files with 165 additions and 38 deletions
36
flake.lock
generated
36
flake.lock
generated
|
|
@ -223,6 +223,23 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"cpu-microcodes": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1759588812,
|
||||
"narHash": "sha256-HMq/XjTY/Dmjzufho8dw8bL/2iMlcIZEUcJI84o6/no=",
|
||||
"owner": "platomav",
|
||||
"repo": "CPUMicrocodes",
|
||||
"rev": "ae2c33ecd7a5855a743b360a05bc984911d16957",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "platomav",
|
||||
"repo": "CPUMicrocodes",
|
||||
"rev": "ae2c33ecd7a5855a743b360a05bc984911d16957",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"crane": {
|
||||
"locked": {
|
||||
"lastModified": 1731098351,
|
||||
|
|
@ -1575,6 +1592,7 @@
|
|||
"systems": "systems_3",
|
||||
"tree": "tree",
|
||||
"treefmt-nix": "treefmt-nix",
|
||||
"ucodenix": "ucodenix",
|
||||
"wezterm": "wezterm"
|
||||
}
|
||||
},
|
||||
|
|
@ -2012,6 +2030,24 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"ucodenix": {
|
||||
"inputs": {
|
||||
"cpu-microcodes": "cpu-microcodes"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1759935526,
|
||||
"narHash": "sha256-ul9G+RlFA1OdfNY2s/qD2ANOagXktbvKpjtWaH8SiVk=",
|
||||
"owner": "e-tho",
|
||||
"repo": "ucodenix",
|
||||
"rev": "ae546711cdd5dbbd284fe9a47bd4f6ae9bbc7449",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "e-tho",
|
||||
"repo": "ucodenix",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"wezterm": {
|
||||
"inputs": {
|
||||
"flake-utils": [
|
||||
|
|
|
|||
|
|
@ -161,6 +161,7 @@
|
|||
flake-compat.follows = "flake-compat";
|
||||
};
|
||||
};
|
||||
ucodenix.url = "github:e-tho/ucodenix";
|
||||
nh = {
|
||||
url = "github:nix-community/nh";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
|
|
|
|||
|
|
@ -1,6 +1,13 @@
|
|||
{lib, ...}: let
|
||||
{
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
inherit (lib.modules) mkDefault mkMerge;
|
||||
in {
|
||||
home.packages = [
|
||||
pkgs.gpg-tui
|
||||
];
|
||||
services.gpg-agent = {
|
||||
enable = mkDefault true;
|
||||
enableExtraSocket = true;
|
||||
|
|
|
|||
6
home/profiles/shell/bottom.nix
Normal file
6
home/profiles/shell/bottom.nix
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
{pkgs, ...}: {
|
||||
programs.bottom = {
|
||||
enable = true;
|
||||
package = pkgs.bottom;
|
||||
};
|
||||
}
|
||||
19
home/profiles/shell/data.nix
Normal file
19
home/profiles/shell/data.nix
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
{pkgs, ...}: {
|
||||
programs.jq = {
|
||||
enable = true;
|
||||
};
|
||||
programs.jqp = {
|
||||
enable = true;
|
||||
};
|
||||
home.packages = with pkgs; [
|
||||
htmlq # JQ for HTML
|
||||
gron # Make JSON greppable
|
||||
jless # Command-line JSON viewer
|
||||
jo # Interface for creating JSON objects in shell
|
||||
jc # Turn output of common/popular packages into JSON
|
||||
dasel # JSON, YAML, TOML, XML, and CSV multitool
|
||||
yj # Convert between YAML, TOML, JSON, and HCL. Preserves map order.
|
||||
csview # CSV viewer
|
||||
glow # Markdown viewer
|
||||
];
|
||||
}
|
||||
5
home/profiles/shell/htop.nix
Normal file
5
home/profiles/shell/htop.nix
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
_: {
|
||||
programs.htop = {
|
||||
enable = true;
|
||||
};
|
||||
}
|
||||
|
|
@ -1,8 +1,6 @@
|
|||
{pkgs, ...}: {
|
||||
home.packages = with pkgs; [
|
||||
watchexec
|
||||
htop
|
||||
btop
|
||||
gdu
|
||||
nixpkgs-fmt
|
||||
file
|
||||
|
|
@ -10,7 +8,6 @@
|
|||
sd
|
||||
sops
|
||||
fd
|
||||
ripgrep
|
||||
rename
|
||||
tmate
|
||||
socat
|
||||
|
|
@ -21,5 +18,26 @@
|
|||
hyperfine
|
||||
poop
|
||||
nix-search-cli
|
||||
pandoc
|
||||
slides
|
||||
sc-im
|
||||
asciinema
|
||||
bandwhich
|
||||
pciutils
|
||||
bingrep
|
||||
chafa
|
||||
dust
|
||||
eva
|
||||
gfold
|
||||
kmon
|
||||
lemmeknow
|
||||
lnav
|
||||
pastel
|
||||
pipe-rename
|
||||
procs
|
||||
tz
|
||||
tre
|
||||
tmpmail
|
||||
wikit
|
||||
];
|
||||
}
|
||||
|
|
|
|||
10
home/profiles/shell/ripgrep.nix
Normal file
10
home/profiles/shell/ripgrep.nix
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
_: {
|
||||
programs = {
|
||||
ripgrep = {
|
||||
enable = true;
|
||||
};
|
||||
ripgrep-all = {
|
||||
enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
5
home/profiles/shell/xplr.nix
Normal file
5
home/profiles/shell/xplr.nix
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
_: {
|
||||
programs.xplr = {
|
||||
enable = true;
|
||||
};
|
||||
}
|
||||
|
|
@ -1,21 +1,6 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
# ensure .local/share/z is created
|
||||
xdg.dataFile."z/.keep".text = "";
|
||||
|
||||
programs.zsh = {
|
||||
localVariables = {
|
||||
_Z_DATA = "${config.xdg.dataHome}/z/data";
|
||||
};
|
||||
plugins =
|
||||
map (plugin: (with pkgs.${plugin}; {
|
||||
name = pname;
|
||||
inherit src;
|
||||
})) [
|
||||
"zsh-z"
|
||||
];
|
||||
_: {
|
||||
programs.zoxide = {
|
||||
enable = true;
|
||||
enableZshIntegration = true;
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -90,7 +90,8 @@ in {
|
|||
'';
|
||||
shellAliases = mkMerge [
|
||||
{
|
||||
nixdirfmt = "nixpkgs-fmt $(fd -e nix)";
|
||||
cat = "bat";
|
||||
top = "btm";
|
||||
dmesg = "dmesg -HP";
|
||||
hg = "history 0 | rg";
|
||||
}
|
||||
|
|
|
|||
8
nixos/hardware/amd.nix
Normal file
8
nixos/hardware/amd.nix
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
{config, ...}: {
|
||||
boot = {
|
||||
blacklistedKernelModules = ["k10temp"];
|
||||
extraModulePackages = [config.boot.kernelPackages.zenpower];
|
||||
kernelModules = ["zenpower"];
|
||||
};
|
||||
services.ucodenix.enable = true;
|
||||
}
|
||||
|
|
@ -1,7 +1,15 @@
|
|||
_: {
|
||||
{config, ...}: {
|
||||
# https://github.com/NixOS/nixos-hardware/issues/1581
|
||||
hardware.framework.enableKmod = false;
|
||||
|
||||
boot = {
|
||||
initrd = {
|
||||
availableKernelModules = ["nvme" "xhci_pci" "thunderbolt" "usb_storage" "sd_mod"];
|
||||
};
|
||||
kernelModules = ["cros_ec" "cros_ec_lpcs"];
|
||||
extraModprobeConfig = "options snd_hda_intel power_save=0";
|
||||
extraModulePackages = with config.boot.kernelPackages; [
|
||||
framework-laptop-kmod
|
||||
];
|
||||
};
|
||||
}
|
||||
|
|
|
|||
4
nixos/hardware/framework/general.nix
Normal file
4
nixos/hardware/framework/general.nix
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
_: {
|
||||
hardware.framework.laptop13.audioEnhancement.enable = true;
|
||||
services.ucodenix.cpuModelId = "00A70F41";
|
||||
}
|
||||
|
|
@ -7,6 +7,9 @@
|
|||
(with tree.nixos.profiles; [
|
||||
uefi
|
||||
])
|
||||
++ (with tree.nixos.hardware; [
|
||||
amd
|
||||
])
|
||||
++ [
|
||||
inputs.nixos-hardware.outputs.nixosModules.framework-13-7040-amd
|
||||
];
|
||||
|
|
|
|||
|
|
@ -2,5 +2,10 @@
|
|||
environment.systemPackages = with pkgs; [
|
||||
ida-pro-kat
|
||||
android-studio
|
||||
bingrep
|
||||
hexyl
|
||||
jwt-cli
|
||||
silicon
|
||||
tokei
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,4 +1,11 @@
|
|||
{pkgs, ...}: {
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
boot.extraModulePackages = with config.boot.kernelPackages; [
|
||||
v4l2loopback
|
||||
];
|
||||
programs.obs-studio = {
|
||||
enable = true;
|
||||
enableVirtualCamera = true;
|
||||
|
|
|
|||
8
nixos/profiles/graphical/upower.nix
Normal file
8
nixos/profiles/graphical/upower.nix
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
{pkgs, ...}: {
|
||||
services.upower = {
|
||||
enable = true;
|
||||
};
|
||||
environment.systemPackages = [
|
||||
pkgs.acpi
|
||||
];
|
||||
}
|
||||
|
|
@ -184,9 +184,6 @@ _: let
|
|||
};
|
||||
|
||||
boot = {
|
||||
extraModulePackages = with config.boot.kernelPackages; [
|
||||
config.boot.kernelPackages.v4l2loopback.out
|
||||
];
|
||||
loader = {
|
||||
systemd-boot.enable = true;
|
||||
efi.canTouchEfiVariables = true;
|
||||
|
|
|
|||
|
|
@ -2,7 +2,6 @@ _: let
|
|||
hostConfig = {
|
||||
tree,
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}: let
|
||||
inherit (lib.attrsets) nameValuePair listToAttrs;
|
||||
|
|
@ -97,23 +96,17 @@ _: let
|
|||
|
||||
powerManagement.enable = true;
|
||||
|
||||
hardware.framework.enableKmod = false;
|
||||
|
||||
boot = {
|
||||
loader = {
|
||||
grub.useOSProber = true;
|
||||
systemd-boot.enable = lib.mkForce false;
|
||||
#systemd-boot.enable = lib.mkForce false;
|
||||
systemd-boot.enable = true;
|
||||
};
|
||||
zfs = {
|
||||
forceImportRoot = false;
|
||||
allowHibernation = true;
|
||||
};
|
||||
kernelModules = ["cros_ec" "cros_ec_lpcs"];
|
||||
extraModprobeConfig = "options snd_hda_intel power_save=0";
|
||||
extraModulePackages = with config.boot.kernelPackages; [
|
||||
config.boot.kernelPackages.v4l2loopback.out
|
||||
framework-laptop-kmod
|
||||
];
|
||||
};
|
||||
|
||||
# optional, useful when the builder has a faster internet connection than yours
|
||||
|
|
|
|||
1
tree.nix
1
tree.nix
|
|
@ -94,6 +94,7 @@
|
|||
microvm.nixosModules.host
|
||||
mewtris.nixosModules.mewtris
|
||||
noctalia.nixosModules.default
|
||||
ucodenix.nixosModules.default
|
||||
];
|
||||
};
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue