mirror of
https://git.gay/xqtc/nixos-config
synced 2024-12-11 22:03:03 +01:00
lexi refactor das muss ich mir nochmal nuechtern anschauen
This commit is contained in:
parent
d5ef609f6f
commit
4b5034ef41
|
@ -8,7 +8,7 @@
|
|||
inputs.sops-nix.nixosModules.sops
|
||||
];
|
||||
|
||||
sops = {
|
||||
sops = {
|
||||
defaultSopsFile = ../secrets.yaml;
|
||||
validateSopsFiles = false;
|
||||
|
||||
|
|
11
flake-mods/allowUnfree.nix
Normal file
11
flake-mods/allowUnfree.nix
Normal file
|
@ -0,0 +1,11 @@
|
|||
{inputs, ...}: {
|
||||
perSystem = { system, ...}: {
|
||||
_module.args.pkgs = import inputs.nixpkgs {
|
||||
inherit system;
|
||||
config.allowUnfree = true;
|
||||
# The allowUnfreePredicate is due to home-manager#2942 (I haven't actually checked that it is necessary)
|
||||
# https://github.com/nix-community/home-manager/issues/2942
|
||||
config.allowUnfreePredicate = (_: true);
|
||||
};
|
||||
};
|
||||
}
|
21
flake-mods/hm-flake-part.nix
Normal file
21
flake-mods/hm-flake-part.nix
Normal file
|
@ -0,0 +1,21 @@
|
|||
{ lib, flake-parts-lib, ... }:
|
||||
let
|
||||
inherit (lib)
|
||||
mkOption
|
||||
types
|
||||
;
|
||||
inherit (flake-parts-lib)
|
||||
mkTransposedPerSystemModule
|
||||
;
|
||||
in
|
||||
mkTransposedPerSystemModule {
|
||||
name = "homeConfigurations";
|
||||
option = mkOption {
|
||||
type = types.raw;
|
||||
default = { };
|
||||
description = ''
|
||||
home-manager configs
|
||||
'';
|
||||
};
|
||||
file = ./hm-flake-part.nix;
|
||||
}
|
28
flake-mods/hm.nix
Normal file
28
flake-mods/hm.nix
Normal file
|
@ -0,0 +1,28 @@
|
|||
{inputs, lib, ...}: {
|
||||
imports = [
|
||||
./hm-flake-part.nix
|
||||
];
|
||||
perSystem = { config, self', inputs', pkgs, system, ... }: let
|
||||
# split system (e.g. x86_64-linux) into os and arch
|
||||
splitSystem = lib.splitString "-" system;
|
||||
os = builtins.elemAt splitSystem 0;
|
||||
arch = builtins.elemAt splitSystem 1;
|
||||
in {
|
||||
legacyPackages.homeConfigurations.xqtc = inputs.home-manager.lib.homeManagerConfiguration {
|
||||
inherit pkgs;
|
||||
modules = [
|
||||
../home
|
||||
inputs.nixvim.homeManagerModules.nixvim
|
||||
inputs.sops-nix.homeManagerModules.sops
|
||||
{ inherit os arch; }
|
||||
];
|
||||
extraSpecialArgs = {inherit inputs;};
|
||||
};
|
||||
|
||||
# # this sounds stupid, but it's the only way to make home-manager consume a
|
||||
# # flake output with the system in it, which *should* be the case because it
|
||||
# # wants system-specific pkgs, but flake-parts (rightfully so!) complains
|
||||
# # that this isn't a package, so we do this to make both happy.
|
||||
# packages.homeConfigurations.type = "derivation";
|
||||
};
|
||||
}
|
11
flake-mods/nixosHosts.nix
Normal file
11
flake-mods/nixosHosts.nix
Normal file
|
@ -0,0 +1,11 @@
|
|||
{inputs, lib, ...}: {
|
||||
flake = lib.genAttrs [
|
||||
"asmodeus" "seraphim" "lilith" "lambda" "beleth"
|
||||
] (name: inputs.nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
modules = [
|
||||
../hosts/x86_64-linux/${name}
|
||||
];
|
||||
specialArgs = {inherit inputs;};
|
||||
});
|
||||
}
|
33
flake.lock
33
flake.lock
|
@ -164,6 +164,24 @@
|
|||
}
|
||||
},
|
||||
"flake-parts": {
|
||||
"inputs": {
|
||||
"nixpkgs-lib": "nixpkgs-lib"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1727826117,
|
||||
"narHash": "sha256-K5ZLCyfO/Zj9mPFldf3iwS6oZStJcU4tSpiXTMYaaL0=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"rev": "3d04084d54bedc3d6b8b736c70ef449225c361b1",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-parts_2": {
|
||||
"inputs": {
|
||||
"nixpkgs-lib": [
|
||||
"nixvim",
|
||||
|
@ -558,6 +576,18 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs-lib": {
|
||||
"locked": {
|
||||
"lastModified": 1727825735,
|
||||
"narHash": "sha256-0xHYkMkeLVQAMa7gvkddbPqpxph+hDzdu1XdGPJR+Os=",
|
||||
"type": "tarball",
|
||||
"url": "https://github.com/NixOS/nixpkgs/archive/fb192fec7cc7a4c26d51779e9bab07ce6fa5597a.tar.gz"
|
||||
},
|
||||
"original": {
|
||||
"type": "tarball",
|
||||
"url": "https://github.com/NixOS/nixpkgs/archive/fb192fec7cc7a4c26d51779e9bab07ce6fa5597a.tar.gz"
|
||||
}
|
||||
},
|
||||
"nixpkgs-master": {
|
||||
"locked": {
|
||||
"lastModified": 1727111026,
|
||||
|
@ -720,7 +750,7 @@
|
|||
"inputs": {
|
||||
"devshell": "devshell",
|
||||
"flake-compat": "flake-compat_2",
|
||||
"flake-parts": "flake-parts",
|
||||
"flake-parts": "flake-parts_2",
|
||||
"git-hooks": "git-hooks",
|
||||
"home-manager": "home-manager_2",
|
||||
"nix-darwin": "nix-darwin",
|
||||
|
@ -816,6 +846,7 @@
|
|||
"compose2nix": "compose2nix",
|
||||
"dwl-source": "dwl-source",
|
||||
"firefox-addons": "firefox-addons",
|
||||
"flake-parts": "flake-parts",
|
||||
"flake-utils": "flake-utils_3",
|
||||
"home-manager": "home-manager",
|
||||
"lix-module": "lix-module",
|
||||
|
|
83
flake.nix
83
flake.nix
|
@ -6,6 +6,7 @@
|
|||
nixos-aarch64-widevine.url = "github:epetousis/nixos-aarch64-widevine";
|
||||
nixpkgs-master.url = "github:NixOS/nixpkgs/master";
|
||||
apple-silicon.url = "github:tpwrules/nixos-apple-silicon";
|
||||
flake-parts.url = "github:hercules-ci/flake-parts";
|
||||
compose2nix = {
|
||||
url = "github:aksiksi/compose2nix";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
|
@ -41,78 +42,14 @@
|
|||
};
|
||||
#inputs.agenix.url = "github:ryantm/agenix";
|
||||
|
||||
outputs = inputs @ {
|
||||
self,
|
||||
nixpkgs,
|
||||
nixpkgs-master,
|
||||
firefox-addons,
|
||||
home-manager,
|
||||
proxmox-nixos,
|
||||
nixos-hardware,
|
||||
nixvim,
|
||||
nh,
|
||||
lix-module,
|
||||
dwl-source,
|
||||
sops-nix,
|
||||
...
|
||||
}: let
|
||||
lib = nixpkgs.lib;
|
||||
util = (import ./overlays/util.nix {} {}).util;
|
||||
system = "x86_64-linux";
|
||||
in {
|
||||
nixosConfigurations = {
|
||||
"asmodeus" = lib.nixosSystem rec {
|
||||
system = "x86_64-linux";
|
||||
modules = [
|
||||
./hosts/x86_64-linux/asmodeus
|
||||
];
|
||||
specialArgs = {inherit inputs;};
|
||||
};
|
||||
"seraphim" = lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
modules = [./hosts/x86_64-linux/seraphim];
|
||||
specialArgs = {inherit inputs;};
|
||||
};
|
||||
"lilith" = lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
modules = [./hosts/x86_64-linux/lilith];
|
||||
specialArgs = {inherit inputs;};
|
||||
};
|
||||
"lambda" = lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
modules = [./hosts/x86_64-linux/lambda];
|
||||
specialArgs = {inherit inputs;};
|
||||
};
|
||||
"beleth" = lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
modules = [
|
||||
./hosts/x86_64-linux/beleth
|
||||
proxmox-nixos.nixosModules.proxmox-ve
|
||||
|
||||
({
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
services.proxmox-ve.enable = false;
|
||||
nixpkgs.overlays = [
|
||||
proxmox-nixos.overlays.${system}
|
||||
];
|
||||
services.openssh.settings.AcceptEnv = lib.mkForce "GIT_PROTOCOL LANG LC_*";
|
||||
})
|
||||
];
|
||||
specialArgs = {inherit inputs;};
|
||||
};
|
||||
"alastor" = lib.nixosSystem {
|
||||
system = "aarch64-linux";
|
||||
modules = [./hosts/aarch64-linux/alastor {nixpkgs.overlays = [inputs.nixos-aarch64-widevine.overlays.default];}];
|
||||
specialArgs = {inherit inputs;};
|
||||
};
|
||||
outputs = inputs@{ flake-parts, ... }: flake-parts.lib.mkFlake { inherit inputs; } {
|
||||
imports = [
|
||||
./flake-mods/hm.nix
|
||||
./flake-mods/nixosHosts.nix
|
||||
./flake-mods/allowUnfree.nix
|
||||
];
|
||||
systems = [ "x86_64-linux" "aarch64-linux" "aarch64-darwin" "x86_64-darwin" ];
|
||||
perSystem = { config, self', inputs', pkgs, system, ... }: {};
|
||||
flake = {};
|
||||
};
|
||||
|
||||
formatter = {
|
||||
x86_64-linux = inputs.nixpkgs.legacyPackages.x86_64-linux.alejandra;
|
||||
aarch64-linux = inputs.nixpkgs.legacyPackages.aarch64-linux.alejandra;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
unicode=" "
|
||||
unicode=" "
|
||||
version="1.2.0"
|
||||
|
||||
|
||||
_black=$(tput setaf 0)
|
||||
red=$(tput setaf 1)
|
||||
green=$(tput setaf 2)
|
||||
|
@ -29,7 +29,7 @@ up=$(uptime | awk -F'( |,|:)+' '{
|
|||
up=$(sed -e "s/ h/h/g" <<< ${up})
|
||||
up=$(sed -e "s/ m/m/g" <<< ${up})
|
||||
|
||||
pkgs=$(nix-store --query --requisites /run/current-system | wc -l)
|
||||
pkgs=$(nix-store --query --requisites /run/current-system 2>/dev/null | wc -l)
|
||||
arch=$(nix-instantiate --eval -E 'builtins.currentSystem')
|
||||
arch_sanitized=$(echo $arch | sed 's/^"//;s/"$//')
|
||||
|
||||
|
@ -39,7 +39,7 @@ fetch() {
|
|||
# echo "${cyan}$(tput bold) / |/ (_)_ __/ __ \/ __/ ${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold) / / /\ \ / /_/ /\ \ ${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold) /_/|_/_//_\_"'\\'"____/___/ ${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold)⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣀⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold)⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣀⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold)⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣰⠞⠛⣦⠎⠁⠹⣆⣤⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold)⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣠⣄⣿⠀⠀⢸⠀⠀⢰⡏⢀⠿⢦⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold)⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣾⠁⠘⣿⡀⢀⣸⠀⡴⠋⠻⡏⠀⢘⡇⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀${normal}$(tput sgr0)"
|
||||
|
@ -93,7 +93,7 @@ fetch() {
|
|||
# echo "${cyan}$(tput bold)⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠘⣿⣿⣿⣿⣿⣿⠏⠙⠋⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold)⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠉⠙⠛⠉⠉⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀${normal}$(tput sgr0)"
|
||||
# if [[ $(($RANDOM % 2)) == 0 ]]; then
|
||||
# echo "${cyan}$(tput bold)⠀⠀⠀⠀⠀⠀⠀⠙⣿⣷⣄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ ${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold)⠀⠀⠀⠀⠀⠀⠀⠙⣿⣷⣄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ ${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold)⠀⠀⠀⠀⠀⠀⠀⠀⢺⣿⣿⡆⠀⠀⠀⠀⠀⠀⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold)⠀⠀⠀⠀⠀⠀⠀⠀⢸⣿⣿⡇⠀⠀⠀⠀⠀⠀⣾⢡⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢢⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold)⠀⠀⠀⠀⠀⠀⠀⠀⠈⣿⣿⣷⡦⠀⠀⠀⠀⢰⣿⣿⣷⠀⠀⠀⠀⠀⠀⠀⠀⠃⣠⣾⡇⠀⠀⠀⠀⠀⠀⠀⠀⠀${normal}$(tput sgr0)"
|
||||
|
@ -120,14 +120,14 @@ fetch() {
|
|||
# echo "${cyan}$(tput bold)⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ ${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold) meow! ${normal}$(tput sgr0)"
|
||||
# else
|
||||
# echo "${cyan}$(tput bold) _ へ ╱|、 ${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold) ૮ - ՛ ) つ(> < 7 ${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold) / ⁻ ៸ 、˜〵${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold) 乀 (ˍ, ل じしˍ,)ノ${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold) _ へ ╱|、 ${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold) ૮ - ՛ ) つ(> < 7 ${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold) / ⁻ ៸ 、˜〵${normal}$(tput sgr0)"
|
||||
# echo "${cyan}$(tput bold) 乀 (ˍ, ل じしˍ,)ノ${normal}$(tput sgr0)"
|
||||
echo ""
|
||||
echo " ╭─────────────╮ "
|
||||
echo " │ ${red} ${normal} user │ ${red}$(whoami)${normal}"
|
||||
echo " │ ${yellow} ${normal} distro │ ${yellow}$(sed -nE "s@PRETTY_NAME=\"([^\"]*)\"@\1@p" /etc/os-release)${normal} "
|
||||
echo " │ ${yellow} ${normal} distro │ ${yellow}$(sed -nE "s@PRETTY_NAME=\"([^\"]*)\"@\1@p" /etc/os-release 2>/dev/null || echo "MacOS")${normal} "
|
||||
echo " │ ${green} ${normal} kernel │ ${green}$(uname -r)${normal} "
|
||||
echo " │ ${cyan} ${normal} de/wm │ ${cyan}$XDG_CURRENT_DESKTOP${normal} "
|
||||
echo " │ ${blue} ${normal} uptime │ ${blue}${up}${normal} "
|
||||
|
|
|
@ -3,6 +3,10 @@ vim.keymap.set("n", "<C-Right>", "<c-w>l")
|
|||
vim.keymap.set("n", "<C-Left>", "<c-w>h")
|
||||
vim.keymap.set("n", "<C-Up>", "<c-w>k")
|
||||
vim.keymap.set("n", "<C-Down>", "<c-w>j")
|
||||
vim.keymap.set("n", "<C-L>", "<c-w>l")
|
||||
vim.keymap.set("n", "<C-H>", "<c-w>h")
|
||||
vim.keymap.set("n", "<C-K>", "<c-w>k")
|
||||
vim.keymap.set("n", "<C-J>", "<c-w>j")
|
||||
|
||||
-- Escape for exiting terminal mode
|
||||
vim.keymap.set('t', '<Esc>', '<C-\\><C-n>')
|
||||
|
|
|
@ -7,9 +7,10 @@
|
|||
}: {
|
||||
imports = [
|
||||
./modules
|
||||
./system.nix
|
||||
];
|
||||
home.username = "xqtc";
|
||||
home.homeDirectory = "/home/xqtc";
|
||||
home.homeDirectory = if config.os == "linux" then "/home/xqtc" else "/Users/xqtc";
|
||||
|
||||
programs.wezterm = {
|
||||
enable = true;
|
||||
|
@ -18,7 +19,7 @@
|
|||
|
||||
programs.joshuto = {enable = true;};
|
||||
|
||||
dconf.enable = true;
|
||||
dconf.enable = config.os == "linux";
|
||||
|
||||
services.easyeffects = lib.mkIf (pkgs.system == "x86_64-linux") {enable = true;};
|
||||
|
||||
|
|
|
@ -22,6 +22,6 @@
|
|||
./zoxide.nix
|
||||
./sops.nix
|
||||
./spotify-cli.nix
|
||||
# ./ssh.nix
|
||||
./ssh.nix
|
||||
];
|
||||
}
|
||||
|
|
|
@ -3,12 +3,13 @@
|
|||
outputs,
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
with inputs; {
|
||||
home.sessionVariables.DEFAULT_BROWSER = "${pkgs.firefox}/bin/firefox";
|
||||
home.sessionVariables.DEFAULT_BROWSER = if (config.os == "linux") then "${pkgs.firefox}/bin/firefox" else "firefox";
|
||||
|
||||
programs.firefox = {
|
||||
programs.firefox = lib.mkIf (config.os == "linux") {
|
||||
enable = true;
|
||||
package =
|
||||
pkgs.firefox.override {cfg = {enableGnomeExtensions = true;};};
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
...
|
||||
}: {
|
||||
programs.foot = {
|
||||
enable = true;
|
||||
enable = config.os == "linux";
|
||||
settings = {
|
||||
main = {
|
||||
font = "ComicShannsMono Nerd Font Mono:size=11";
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
config,
|
||||
pkgs,
|
||||
inputs,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
dconf.settings = {
|
||||
|
@ -52,7 +53,7 @@
|
|||
'';
|
||||
};
|
||||
};
|
||||
home.packages = with pkgs; [
|
||||
home.packages = lib.optionals (config.os == "linux") (with pkgs; [
|
||||
gnomeExtensions.user-themes
|
||||
gnomeExtensions.blur-my-shell
|
||||
gnomeExtensions.tray-icons-reloaded
|
||||
|
@ -63,7 +64,7 @@
|
|||
gnomeExtensions.burn-my-windows
|
||||
gnomeExtensions.desktop-cube
|
||||
catppuccin-cursors.mochaPink
|
||||
];
|
||||
]);
|
||||
# home.pointerCursor = {
|
||||
# gtk.enable = true;
|
||||
# x11.enable = true;
|
||||
|
|
|
@ -2,131 +2,126 @@
|
|||
config,
|
||||
inputs,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
flameshot = pkgs.flameshot.overrideDerivation (old: {NIX_CFLAGS_COMPILE = "-DUSE_WAYLAND_GRIM";});
|
||||
x86pkgs =
|
||||
if pkgs.system == "x86_64-linux"
|
||||
then [
|
||||
pkgs.steam
|
||||
pkgs.heroic
|
||||
pkgs.protonup-qt
|
||||
pkgs.via
|
||||
pkgs.telegram-desktop
|
||||
pkgs.jetbrains.rust-rover
|
||||
pkgs.tutanota-desktop
|
||||
pkgs.bitwarden-desktop
|
||||
pkgs.bottles
|
||||
flameshot
|
||||
pkgs.grim
|
||||
# pkgs.ida-free
|
||||
# pkgs.spotify
|
||||
]
|
||||
else [];
|
||||
|
||||
maxfetch = pkgs.writeScriptBin "maxfetch" (builtins.readFile ../config-files/maxfetch.sh);
|
||||
startdwl = pkgs.writeScriptBin "startdwl" (builtins.readFile ../config-files/startdwl.sh);
|
||||
in {
|
||||
home.packages =
|
||||
[
|
||||
pkgs.yubioath-flutter
|
||||
home.packages = (lib.optionals (config.os == "linux") (with pkgs; [
|
||||
yubioath-flutter
|
||||
steam
|
||||
heroic
|
||||
protonup-qt
|
||||
via
|
||||
telegram-desktop
|
||||
jetbrains.rust-rover
|
||||
tutanota-desktop
|
||||
bitwarden-desktop
|
||||
bottles
|
||||
flameshot
|
||||
grim
|
||||
networkmanagerapplet
|
||||
nextcloud-client
|
||||
swaylock-effects
|
||||
wdisplays
|
||||
brightnessctl
|
||||
pavucontrol
|
||||
swayfx
|
||||
sway-contrib.grimshot
|
||||
libnotify
|
||||
swww
|
||||
strace
|
||||
ltrace
|
||||
ghidra
|
||||
imhex
|
||||
qmk-udev-rules
|
||||
jellyfin-media-player
|
||||
signal-desktop
|
||||
# ida-free
|
||||
# spotify
|
||||
])) ++ (with pkgs; [
|
||||
nh
|
||||
|
||||
pkgs.ncspot
|
||||
ncspot
|
||||
|
||||
pkgs.wakatime-cli
|
||||
wakatime-cli
|
||||
|
||||
pkgs.neofetch
|
||||
# pkgs.uwufetch
|
||||
maxfetch
|
||||
startdwl
|
||||
pkgs.btop
|
||||
pkgs.iftop
|
||||
pkgs.ranger
|
||||
neofetch
|
||||
# uwufetch
|
||||
maxfetch
|
||||
startdwl
|
||||
btop
|
||||
iftop
|
||||
ranger
|
||||
|
||||
pkgs.cargo-mommy
|
||||
pkgs.evcxr
|
||||
cargo-mommy
|
||||
|
||||
pkgs.just
|
||||
pkgs.fzf
|
||||
just
|
||||
fzf
|
||||
|
||||
pkgs.catppuccin-kde
|
||||
catppuccin-kde
|
||||
|
||||
pkgs.typst
|
||||
typst
|
||||
|
||||
pkgs.networkmanagerapplet
|
||||
# marked as broken
|
||||
# anki
|
||||
|
||||
pkgs.anki
|
||||
freetube
|
||||
|
||||
pkgs.freetube
|
||||
openvpn
|
||||
|
||||
pkgs.openvpn
|
||||
moodle-dl
|
||||
|
||||
pkgs.moodle-dl
|
||||
|
||||
pkgs.nextcloud-client
|
||||
obsidian
|
||||
|
||||
pkgs.obsidian
|
||||
|
||||
pkgs.swaylock-effects
|
||||
pkgs.wdisplays
|
||||
|
||||
pkgs.prismlauncher
|
||||
prismlauncher
|
||||
|
||||
pkgs.syncthingtray
|
||||
# marked as broken
|
||||
# syncthingtray
|
||||
|
||||
pkgs.brightnessctl
|
||||
pkgs.pavucontrol
|
||||
|
||||
pkgs.rbw
|
||||
rbw
|
||||
|
||||
pkgs.swayfx
|
||||
pkgs.sway-contrib.grimshot
|
||||
|
||||
pkgs.libnotify
|
||||
nodejs
|
||||
|
||||
pkgs.strace
|
||||
pkgs.ltrace
|
||||
# cabal
|
||||
ghc
|
||||
|
||||
pkgs.nodejs
|
||||
# marked as broken
|
||||
# rizin
|
||||
# (cutter.withPlugins (ps: with ps; [jsdec rz-ghidra sigdb]))
|
||||
|
||||
# pkgs.cabal
|
||||
pkgs.ghc
|
||||
|
||||
pkgs.rizin
|
||||
(pkgs.cutter.withPlugins (ps: with ps; [jsdec rz-ghidra sigdb]))
|
||||
nerdfonts
|
||||
ipafont
|
||||
|
||||
pkgs.imhex
|
||||
pkgs.ghidra
|
||||
vesktop
|
||||
element-desktop
|
||||
|
||||
pkgs.nerdfonts
|
||||
pkgs.ipafont
|
||||
qbittorrent
|
||||
nicotine-plus
|
||||
|
||||
pkgs.signal-desktop
|
||||
pkgs.vesktop
|
||||
pkgs.element-desktop
|
||||
qmk
|
||||
|
||||
pkgs.qbittorrent
|
||||
pkgs.nicotine-plus
|
||||
neovide
|
||||
|
||||
pkgs.qmk
|
||||
pkgs.qmk-udev-rules
|
||||
xournalpp
|
||||
zathura
|
||||
|
||||
pkgs.neovide
|
||||
ripgrep
|
||||
|
||||
pkgs.xournalpp
|
||||
pkgs.zathura
|
||||
sayonara
|
||||
# mpv
|
||||
feishin
|
||||
|
||||
pkgs.ripgrep
|
||||
nix-tree
|
||||
|
||||
pkgs.sayonara
|
||||
pkgs.mpv
|
||||
pkgs.jellyfin-media-player
|
||||
pkgs.feishin
|
||||
|
||||
pkgs.nix-tree
|
||||
|
||||
pkgs.nixos-icons
|
||||
pkgs.swww
|
||||
]
|
||||
++ x86pkgs;
|
||||
nixos-icons
|
||||
]);
|
||||
}
|
||||
|
|
|
@ -20,7 +20,7 @@
|
|||
|
||||
clipboard.providers.wl-copy.enable = true;
|
||||
|
||||
options = {
|
||||
opts = {
|
||||
number = true; # Show line numbers
|
||||
relativenumber = true; # Show relative line numbers
|
||||
|
||||
|
@ -47,22 +47,22 @@
|
|||
wakatime.enable = true;
|
||||
headlines.enable = true;
|
||||
twilight.enable = true;
|
||||
comment-nvim = {
|
||||
comment = {
|
||||
enable = true;
|
||||
};
|
||||
indent-blankline.enable = true;
|
||||
lualine = {
|
||||
enable = true;
|
||||
disabledFiletypes.statusline = ["neo-tree"];
|
||||
componentSeparators = {
|
||||
left = "";
|
||||
right = "";
|
||||
};
|
||||
sectionSeparators = {
|
||||
left = "";
|
||||
right = "";
|
||||
};
|
||||
settings = {
|
||||
disabled_filetypes.statusline = ["neo-tree"];
|
||||
component_separators = {
|
||||
left = "";
|
||||
right = "";
|
||||
};
|
||||
section_separators = {
|
||||
left = "";
|
||||
right = "";
|
||||
};
|
||||
sections = {
|
||||
lualine_y = [
|
||||
{
|
||||
|
@ -153,9 +153,7 @@
|
|||
# port = "31337";
|
||||
# host = "127.0.0.1";
|
||||
# };
|
||||
};
|
||||
server = {
|
||||
settings = {
|
||||
server.settings = {
|
||||
inlayHints = {
|
||||
closureStyle = "rust_analyzer";
|
||||
};
|
||||
|
@ -179,7 +177,7 @@
|
|||
nushell.enable = true;
|
||||
clangd.enable = true;
|
||||
svelte.enable = true;
|
||||
tsserver.enable = true;
|
||||
ts-ls.enable = true;
|
||||
java-language-server.enable = true;
|
||||
hls.enable = true;
|
||||
eslint.enable = true;
|
||||
|
@ -194,7 +192,7 @@
|
|||
typing.autoClosingAngleBrackets.enable = true;
|
||||
};
|
||||
};
|
||||
nil_ls.enable = true;
|
||||
nil-ls.enable = true;
|
||||
};
|
||||
};
|
||||
dap = {
|
||||
|
@ -210,12 +208,12 @@
|
|||
treesitter = {
|
||||
enable = true;
|
||||
folding = true;
|
||||
indent = true;
|
||||
nixvimInjections = true;
|
||||
settings = {
|
||||
ensure_installed = "all";
|
||||
# highlight.enable = true;
|
||||
highlight.enable = true;
|
||||
indent.enable = true;
|
||||
};
|
||||
};
|
||||
treesitter-refactor = {
|
||||
|
@ -269,6 +267,7 @@
|
|||
};
|
||||
};
|
||||
telescope.enable = true;
|
||||
web-devicons.enable = true; # required by telescope
|
||||
telescope.extensions = {file-browser.enable = true;};
|
||||
which-key.enable = true;
|
||||
cmp-nvim-lsp.enable = true;
|
||||
|
@ -285,7 +284,6 @@
|
|||
enable = true;
|
||||
theme = null;
|
||||
|
||||
iconsEnabled = true;
|
||||
layout = [
|
||||
{
|
||||
type = "padding";
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
...
|
||||
}: {
|
||||
programs.rbw = {
|
||||
enable = true;
|
||||
enable = config.os == "linux";
|
||||
settings = {
|
||||
email = "xqtc@tutanota.com";
|
||||
lock_timeout = 300;
|
||||
|
@ -14,7 +14,7 @@
|
|||
};
|
||||
};
|
||||
programs.rofi = {
|
||||
enable = true;
|
||||
enable = config.os == "linux";
|
||||
package = pkgs.rofi-wayland;
|
||||
plugins = [pkgs.rofi-rbw-wayland pkgs.rofi-power-menu];
|
||||
extraConfig = {
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
...
|
||||
}: {
|
||||
programs = {
|
||||
zsh.enable = true;
|
||||
zsh.enable = if config.os == "linux" then true else false;
|
||||
atuin = {
|
||||
enable = true;
|
||||
enableNushellIntegration = true;
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
|
||||
age = {
|
||||
sshKeyPaths = ["/etc/ssh/ssh_host_ed25519_key"];
|
||||
keyFile = "/home/xqtc/.config/sops/age/keys.txt";
|
||||
keyFile = if (config.os == "linux") then "/home/xqtc/.config/sops/age/keys.txt" else "/Users/xqtc/.config/sops/age/keys.txt";
|
||||
generateKey = true;
|
||||
};
|
||||
};
|
||||
|
|
|
@ -5,14 +5,14 @@
|
|||
inputs,
|
||||
...
|
||||
}: {
|
||||
services.spotifyd.enable = true;
|
||||
services.spotifyd.enable = config.os == "linux";
|
||||
services.spotifyd.settings.global = {
|
||||
bitrate = 320;
|
||||
username = "xqtc@tutanota.com";
|
||||
password_cmd = "cat /etc/spotifyd_pw";
|
||||
};
|
||||
|
||||
sops.secrets = {
|
||||
sops.secrets = lib.mkIf (config.os == "linux") {
|
||||
"spotify/password" = {
|
||||
path = "/etc/spotifyd_pw";
|
||||
};
|
||||
|
|
|
@ -5,16 +5,28 @@
|
|||
pkgs,
|
||||
...
|
||||
}: {
|
||||
sops.secrets = {
|
||||
"private_keys/xqtc" = {
|
||||
path = "/home/xqtc/.ssh/id_ed25519";
|
||||
sops = {
|
||||
# defaultSopsFile = ../secrets.yaml;
|
||||
# validateSopsFiles = false;
|
||||
#
|
||||
# age = {
|
||||
# sshKeyPaths = ["/etc/ssh/ssh_host_ed25519_key"];
|
||||
# keyFile = "/var/lib/sops/age/keys.txt";
|
||||
# generateKey = true;
|
||||
# };
|
||||
secrets = {
|
||||
"xqtc_private" = {
|
||||
# path = if (pkgs.system == "aarch64-darwin") then "/Users/xqtc/.ssh/id_ed25519" else "/home/xqtc/.ssh/id_ed25519";
|
||||
path = config.home.homeDirectory + "/.ssh/id_ed25519";
|
||||
# owner = "xqtc";
|
||||
mode = "600";
|
||||
};
|
||||
"public_keys/xqtc" = {
|
||||
path = "/home/xqtc/.ssh/id_ed25519.pub";
|
||||
"xqtc_public" = {
|
||||
# path = if (pkgs.system == "aarch64-darwin") then "/Users/xqtc/.ssh/id_ed25519.pub" else "/home/xqtc/.ssh/id_ed25519.pub";
|
||||
path = config.home.homeDirectory + "/.ssh/id_ed25519.pub";
|
||||
# owner = "xqtc";
|
||||
mode = "640";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
...
|
||||
}: {
|
||||
wayland.windowManager.hyprland = {
|
||||
enable = true;
|
||||
enable = config.os == "linux";
|
||||
package = pkgs.hyprland;
|
||||
|
||||
#xwayland.enable = true;
|
||||
|
@ -20,7 +20,7 @@
|
|||
lib.mkIf (pkgs.system == "x86_64-linux")
|
||||
*/
|
||||
{
|
||||
enable = true;
|
||||
enable = config.os == "linux";
|
||||
settings = {
|
||||
mainBar = {
|
||||
layer = "top";
|
||||
|
@ -113,7 +113,7 @@
|
|||
};
|
||||
|
||||
services.mako = {
|
||||
enable = true;
|
||||
enable = config.os == "linux";
|
||||
font = "ComicShannsMono Nerd Font Mono 15";
|
||||
backgroundColor = "#1e1e2e";
|
||||
textColor = "#cdd6f4";
|
||||
|
|
10
home/system.nix
Normal file
10
home/system.nix
Normal file
|
@ -0,0 +1,10 @@
|
|||
{lib, ...}: {
|
||||
options.os = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
default = "linux";
|
||||
};
|
||||
options.arch = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
default = "x86_64";
|
||||
};
|
||||
}
|
5
justfile
5
justfile
|
@ -27,6 +27,11 @@ beleth:
|
|||
# fi
|
||||
# @echo "Host arch needs to be 'x86_64-linux'! Aborting...";
|
||||
|
||||
beleth-non-nixos:
|
||||
set -euxo pipefail
|
||||
ssh {{beleth-user-host}} "cd nixos-config && git pull && nixos-rebuild --flake . switch && echo meow"
|
||||
ssh {{beleth-user-host}} "cd && cd /var/www/cheats-rs/ && git pull && zola build && cd && sh build_website.sh";
|
||||
|
||||
website:
|
||||
#!/usr/bin/env bash
|
||||
set -euxo pipefail
|
||||
|
|
1
result
Symbolic link
1
result
Symbolic link
|
@ -0,0 +1 @@
|
|||
/nix/store/7nlb2hg141qvsbychf5kd0pqb49yp579-home-manager-generation
|
Loading…
Reference in a new issue