add wrappers
This commit is contained in:
parent
05bf2c1c60
commit
8a2c922b27
10 changed files with 154 additions and 108 deletions
53
flake.lock
generated
53
flake.lock
generated
|
@ -201,11 +201,11 @@
|
|||
"nixpkgs": "nixpkgs"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1703368619,
|
||||
"narHash": "sha256-ZGPMYL7FMA6enhuwby961bBANmoFX14EA86m2/Jw5Jo=",
|
||||
"lastModified": 1703527373,
|
||||
"narHash": "sha256-AjypRssRtS6F3xkf7rE3/bXkIF2WJOZLbTIspjcE1zM=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "a2523ea0343b056ba240abbac90ab5f116a7aa7b",
|
||||
"rev": "80679ea5074ab7190c4cce478c600057cfb5edae",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -240,11 +240,11 @@
|
|||
"nixpkgs": "nixpkgs_2"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1703380831,
|
||||
"narHash": "sha256-JqptMO/EPgeeJOeyzF0whENAbKoN2DpMcr07fwwYy44=",
|
||||
"lastModified": 1703553195,
|
||||
"narHash": "sha256-4iOPcdDwGsiVhHM26a+uSkLmdlrZGCBUabpp4NuCEdU=",
|
||||
"owner": "fufexan",
|
||||
"repo": "nix-gaming",
|
||||
"rev": "e12595103fee68cc57a9a16a6288c00f3d7ab828",
|
||||
"rev": "219145d5cba3b597de446fc0ee1d7213713aef43",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -255,11 +255,11 @@
|
|||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1702312524,
|
||||
"narHash": "sha256-gkZJRDBUCpTPBvQk25G0B7vfbpEYM5s5OZqghkjZsnE=",
|
||||
"lastModified": 1703255338,
|
||||
"narHash": "sha256-Z6wfYJQKmDN9xciTwU3cOiOk+NElxdZwy/FiHctCzjU=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "a9bf124c46ef298113270b1f84a164865987a91c",
|
||||
"rev": "6df37dc6a77654682fe9f071c62b4242b5342e04",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -358,11 +358,11 @@
|
|||
"utils": "utils"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1703423749,
|
||||
"narHash": "sha256-riAEcZJCVbUhfC5aAL+gJ6nC/IE3P/W2w7MGLNFxsio=",
|
||||
"lastModified": 1703540559,
|
||||
"narHash": "sha256-QjOHZc8z2ULBbecRPszSZXBk36+A6Oy/MPmrQNQ9Mgk=",
|
||||
"owner": "wamserma",
|
||||
"repo": "flake-programs-sqlite",
|
||||
"rev": "0b7ded98747dfb565baebe5aa0177e71264558ee",
|
||||
"rev": "b00c2a2d12a2df83ad575b81195ed4215dcdac4c",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -379,7 +379,8 @@
|
|||
"nixpkgs": "nixpkgs_3",
|
||||
"nixpkgs-local": "nixpkgs-local",
|
||||
"programsdb": "programsdb",
|
||||
"stylix": "stylix"
|
||||
"stylix": "stylix",
|
||||
"wrapper-manager": "wrapper-manager"
|
||||
}
|
||||
},
|
||||
"stylix": {
|
||||
|
@ -397,11 +398,11 @@
|
|||
"nixpkgs": "nixpkgs_4"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1703334881,
|
||||
"narHash": "sha256-T7O1fbBXg4eq+4Bi+SDN9p4xgOHeZWOXQWTq0U8ximA=",
|
||||
"lastModified": 1703528325,
|
||||
"narHash": "sha256-ajoMmEPbLhp9xsReDDQFaY7xX+ayIqwfMlZNg8YxHnw=",
|
||||
"owner": "danth",
|
||||
"repo": "stylix",
|
||||
"rev": "96f0794dbd4b2ea499fe3c496a8e659bd4ffd68a",
|
||||
"rev": "7ccd1293a48f01eace7d0ce8d82af51919105b76",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -424,6 +425,26 @@
|
|||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"wrapper-manager": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1702396227,
|
||||
"narHash": "sha256-JTgwZK6m3Lt1LrjgWdl5+9RyDlAI9mzH3QHFMY8RwVY=",
|
||||
"owner": "viperML",
|
||||
"repo": "wrapper-manager",
|
||||
"rev": "3a4c510ffb9f01fc7cab5e23f5ae818d72a66e1a",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "viperML",
|
||||
"repo": "wrapper-manager",
|
||||
"type": "github"
|
||||
}
|
||||
}
|
||||
},
|
||||
"root": "root",
|
||||
|
|
60
flake.nix
60
flake.nix
|
@ -12,10 +12,10 @@
|
|||
url = "github:wamserma/flake-programs-sqlite";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
# wrapper-manager = {
|
||||
# url = "github:viperML/wrapper-manager";
|
||||
# inputs.nixpkgs.follows = "nixpkgs";
|
||||
# };
|
||||
wrapper-manager = {
|
||||
url = "github:viperML/wrapper-manager";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
# wrapper-manager-hm-compat = {
|
||||
# url = "github:nrabulinski/wrapper-manager-hm-compat";
|
||||
# inputs.nixpkgs.follows = "nixpkgs";
|
||||
|
@ -30,33 +30,37 @@
|
|||
home-manager,
|
||||
...
|
||||
} @ inputs: let
|
||||
opt = nixpkgs.lib.optionals;
|
||||
dirFiles = dir: map (file: "${dir}/${file}") (builtins.attrNames (builtins.readDir dir));
|
||||
dirUtils = {
|
||||
opt = nixpkgs.lib.optionals;
|
||||
dirFiles = dir: map (file: "${dir}/${file}") (builtins.attrNames (builtins.readDir dir));
|
||||
};
|
||||
system = hostname: isDesktop:
|
||||
nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
specialArgs = {
|
||||
inherit inputs self;
|
||||
};
|
||||
with dirUtils;
|
||||
nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
specialArgs = {
|
||||
inherit inputs self isDesktop dirUtils;
|
||||
};
|
||||
|
||||
modules =
|
||||
[
|
||||
"${self}/${hostname}/configuration.nix"
|
||||
"${self}/${hostname}/hardware-configuration.nix"
|
||||
inputs.nix-gaming.nixosModules.pipewireLowLatency
|
||||
]
|
||||
++ dirFiles ./modules/common
|
||||
++ opt isDesktop (
|
||||
(dirFiles ./modules/common-desktop)
|
||||
++ [
|
||||
stylix.nixosModules.stylix
|
||||
./stylix.nix
|
||||
|
||||
home-manager.nixosModules.home-manager
|
||||
./home-manager.nix
|
||||
modules =
|
||||
[
|
||||
./wrappers
|
||||
"${self}/${hostname}/configuration.nix"
|
||||
"${self}/${hostname}/hardware-configuration.nix"
|
||||
inputs.nix-gaming.nixosModules.pipewireLowLatency
|
||||
]
|
||||
);
|
||||
};
|
||||
++ dirFiles ./modules/common
|
||||
++ opt isDesktop (
|
||||
(dirFiles ./modules/common-desktop)
|
||||
++ [
|
||||
stylix.nixosModules.stylix
|
||||
./stylix.nix
|
||||
|
||||
home-manager.nixosModules.home-manager
|
||||
./home-manager.nix
|
||||
]
|
||||
);
|
||||
};
|
||||
in {
|
||||
nixosConfigurations = {
|
||||
"quadraticpc" = system "quadraticpc" true;
|
||||
|
|
|
@ -19,7 +19,6 @@
|
|||
./home-manager/vscode.nix
|
||||
./home-manager/direnv.nix
|
||||
./home-manager/firefox.nix
|
||||
./home-manager/neofetch.nix
|
||||
./home-manager/mangohud.nix
|
||||
./home-manager/sway.nix
|
||||
];
|
||||
|
|
|
@ -1,60 +0,0 @@
|
|||
{
|
||||
xdg.configFile."neofetch/config.conf".text = ''
|
||||
print_info() {
|
||||
prin " ''${cl7}┌─────────''${cl0}\n Hardware Information \n''${cl7}──────────"
|
||||
info "├" cpu
|
||||
info "├─" gpu
|
||||
info "├" memory
|
||||
prin " ''${cl7}├─────────''${cl0}\n Software Information \n''${cl7}──────────"
|
||||
info "├" distro
|
||||
info "├" kernel
|
||||
info "├" de
|
||||
info "├" shell
|
||||
info "├" term
|
||||
info "├" theme
|
||||
info "├" packages
|
||||
prin " ''${cl7}└────────────────────────────────────────"
|
||||
prin "\n \n \n \n \n ''${cl3} \n \n ''${cl5} \n \n ''${cl2} \n \n ''${cl6} \n \n ''${cl4} \n \n ''${cl1} \n \n ''${cl7} \n \n ''${cl0}"
|
||||
}
|
||||
|
||||
magenta="\033[1;35m"
|
||||
green="\033[1;32m"
|
||||
white="\033[1;37m"
|
||||
blue="\033[1;34m"
|
||||
red="\033[1;31m"
|
||||
black="\033[1;40;30m"
|
||||
yellow="\033[1;33m"
|
||||
cyan="\033[1;36m"
|
||||
reset="\033[0m"
|
||||
bgyellow="\033[1;43;33m"
|
||||
bgwhite="\033[1;47;37m"
|
||||
cl0="''${reset}"
|
||||
cl1="''${magenta}"
|
||||
cl2="''${green}"
|
||||
cl3="''${white}"
|
||||
cl4="''${blue}"
|
||||
cl5="''${red}"
|
||||
cl6="''${yellow}"
|
||||
cl7="''${cyan}"
|
||||
cl8="''${black}"
|
||||
cl9="''${bgyellow}"
|
||||
cl10="''${bgwhite}"
|
||||
color_blocks="off"
|
||||
os_arch="off"
|
||||
memory_percent="on"
|
||||
package_managers="on"
|
||||
shell_version="off"
|
||||
speed_shorthand="on"
|
||||
cpu_brand="on"
|
||||
cpu_speed="off"
|
||||
cpu_cores="off"
|
||||
gtk_shorthand="on"
|
||||
de_version="off"
|
||||
separator=""
|
||||
memory_display="on"
|
||||
disk_display="on"
|
||||
colors=(0 0 0 6 6 7)
|
||||
ascii_colors=(6 6 6 6 6 6)
|
||||
image_size="250px"
|
||||
'';
|
||||
}
|
|
@ -12,8 +12,6 @@
|
|||
aspell
|
||||
killall
|
||||
ripgrep
|
||||
vesktop
|
||||
hyfetch
|
||||
inkscape
|
||||
r2modman
|
||||
pciutils
|
||||
|
|
|
@ -4,7 +4,6 @@
|
|||
interactiveShellInit = "neofetch";
|
||||
};
|
||||
environment = {
|
||||
systemPackages = [pkgs.hyfetch];
|
||||
sessionVariables.fish_greeting = "";
|
||||
shells = [pkgs.fish];
|
||||
shellAliases = {
|
||||
|
|
6
wrappers/common-desktop/vesktop.nix
Normal file
6
wrappers/common-desktop/vesktop.nix
Normal file
|
@ -0,0 +1,6 @@
|
|||
{pkgs, ...}: {
|
||||
wrappers.vesktop = {
|
||||
basePackage = pkgs.vesktop;
|
||||
env.NIXOS_OZONE_WL.value = null;
|
||||
};
|
||||
}
|
9
wrappers/common/neofetch/default.nix
Normal file
9
wrappers/common/neofetch/default.nix
Normal file
|
@ -0,0 +1,9 @@
|
|||
{pkgs, ...}: {
|
||||
wrappers.neofetch = {
|
||||
basePackage = pkgs.hyfetch;
|
||||
flags = [
|
||||
"--config"
|
||||
./neofetch.conf
|
||||
];
|
||||
};
|
||||
}
|
56
wrappers/common/neofetch/neofetch.conf
Normal file
56
wrappers/common/neofetch/neofetch.conf
Normal file
|
@ -0,0 +1,56 @@
|
|||
print_info() {
|
||||
prin " ${cl7}┌─────────${cl0}\n Hardware Information \n${cl7}──────────"
|
||||
info "├" cpu
|
||||
info "├─" gpu
|
||||
info "├" memory
|
||||
prin " ${cl7}├─────────${cl0}\n Software Information \n${cl7}──────────"
|
||||
info "├" distro
|
||||
info "├" kernel
|
||||
info "├" de
|
||||
info "├" shell
|
||||
info "├" term
|
||||
info "├" theme
|
||||
info "├" packages
|
||||
prin " ${cl7}└────────────────────────────────────────"
|
||||
prin "\n \n \n \n \n ${cl3} \n \n ${cl5} \n \n ${cl2} \n \n ${cl6} \n \n ${cl4} \n \n ${cl1} \n \n ${cl7} \n \n ${cl0}"
|
||||
}
|
||||
|
||||
magenta="\033[1;35m"
|
||||
green="\033[1;32m"
|
||||
white="\033[1;37m"
|
||||
blue="\033[1;34m"
|
||||
red="\033[1;31m"
|
||||
black="\033[1;40;30m"
|
||||
yellow="\033[1;33m"
|
||||
cyan="\033[1;36m"
|
||||
reset="\033[0m"
|
||||
bgyellow="\033[1;43;33m"
|
||||
bgwhite="\033[1;47;37m"
|
||||
cl0="${reset}"
|
||||
cl1="${magenta}"
|
||||
cl2="${green}"
|
||||
cl3="${white}"
|
||||
cl4="${blue}"
|
||||
cl5="${red}"
|
||||
cl6="${yellow}"
|
||||
cl7="${cyan}"
|
||||
cl8="${black}"
|
||||
cl9="${bgyellow}"
|
||||
cl10="${bgwhite}"
|
||||
color_blocks="off"
|
||||
os_arch="off"
|
||||
memory_percent="on"
|
||||
package_managers="on"
|
||||
shell_version="off"
|
||||
speed_shorthand="on"
|
||||
cpu_brand="on"
|
||||
cpu_speed="off"
|
||||
cpu_cores="off"
|
||||
gtk_shorthand="on"
|
||||
de_version="off"
|
||||
separator=""
|
||||
memory_display="on"
|
||||
disk_display="on"
|
||||
colors=(0 0 0 6 6 7)
|
||||
ascii_colors=(6 6 6 6 6 6)
|
||||
image_size="250px"
|
14
wrappers/default.nix
Normal file
14
wrappers/default.nix
Normal file
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
pkgs,
|
||||
inputs,
|
||||
dirUtils,
|
||||
isDesktop,
|
||||
...
|
||||
}: {
|
||||
environment.systemPackages = with dirUtils; [
|
||||
(inputs.wrapper-manager.lib.build {
|
||||
inherit pkgs;
|
||||
modules = dirFiles ./common ++ opt isDesktop (dirFiles ./common-desktop);
|
||||
})
|
||||
];
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue