This commit is contained in:
Varris 2024-01-30 18:51:06 +01:00
parent ebfdf1b3a1
commit 915a1a3b29
15 changed files with 113 additions and 67 deletions

View File

@ -26,6 +26,7 @@
};
hyprland = {
# url = "github:hyprwm/hyprland/12d79d63421e2ed3f31130755c7a37f0e4fb5cb1";
url = "github:hyprwm/hyprland";
inputs.nixpkgs.follows = "nixpkgs";
};
@ -100,14 +101,23 @@
self.overlays.default
];
};
#edit as you see fit
hostName = "terra";
userName = "manuel";
flakeDir = "/home/${userName}/.dotfiles";
in {
formatter.${system} = nixpkgs.legacyPackages.${system}.alejandra;
overlays = import ./overlay.nix {inherit inputs;};
nixosConfigurations.terra = nixpkgs.lib.nixosSystem {
nixosConfigurations.${hostName} = nixpkgs.lib.nixosSystem {
inherit system;
inherit pkgs;
specialArgs = {inherit inputs;};
specialArgs = {
inherit inputs;
inherit hostName;
inherit userName;
};
modules = [
./system/configuration.nix
inputs.chaotic-nyx.nixosModules.default
@ -115,9 +125,13 @@
];
};
homeConfigurations.manuel = home-manager.lib.homeManagerConfiguration {
homeConfigurations.${userName} = home-manager.lib.homeManagerConfiguration {
inherit pkgs;
extraSpecialArgs = {inherit inputs;};
extraSpecialArgs = {
inherit inputs;
inherit userName;
inherit flakeDir;
};
modules = [
./user/home.nix
inputs.nix-index-database.hmModules.nix-index

View File

@ -27,6 +27,15 @@
version = "9999";
src = inputs.openmw-git;
buildInputs = (prev.lib.lists.remove prev.mygui old.buildInputs) ++ [prev.libyamlcpp prev.luajit prev.collada-dom final.mygui-openmw];
cmakeFlags =
old.cmakeFlags
++ [
"-DBUILD_BSATOOL=OFF"
"-DBUILD_BULLETOBJECTTOOL=OFF"
"-DBUILD_ESMTOOL=OFF"
"-DBUILD_NIFTEST=OFF"
"-DBUILD_OPENCS=OFF"
];
patches = [];
});
@ -42,14 +51,5 @@
prev.mpg123
];
};
vimPlugins =
prev.vimPlugins
// {
presence-nvim = prev.vimUtils.buildVimPlugin {
name = "presence";
src = inputs.nvim-presence;
};
};
};
}

View File

@ -3,6 +3,8 @@
lib,
config,
inputs,
hostName,
userName,
...
}: {
imports = [
@ -41,7 +43,7 @@
powerManagement.cpuFreqGovernor = "schedutil";
networking = {
hostName = "terra"; # Define your hostname.
hostName = "${hostName}"; #hostname declared in flake.nix
firewall.enable = false;
useNetworkd = true;
extraHosts = ''
@ -84,7 +86,7 @@
enable = true;
extraRules = [
{
users = ["manuel"];
users = ["${userName}"];
keepEnv = true;
persist = true;
}
@ -92,7 +94,7 @@
};
};
users.users.manuel = {
users.users.${userName} = {
isNormalUser = true;
extraGroups = ["audio" "games" "input" "lp" "networkmanager" "scanner" "users" "vboxusers" "video" "wheel"];
shell = pkgs.fish;
@ -167,6 +169,7 @@
settings = {
auto-optimise-store = true;
extra-sandbox-paths = [config.programs.ccache.cacheDir];
substituters = [
"https://nyx.chaotic.cx"

View File

@ -1,5 +1,10 @@
{pkgs, ...}: {
programs = {
adb.enable = true;
ccache = {
enable = true;
packageNames = ["openmw"];
};
dconf.enable = true;
fish.enable = true;
hyprland.enable = true;

View File

@ -23,9 +23,11 @@
redirector
return-youtube-dislikes
sponsorblock
startpage-private-search
stylus
tampermonkey
ublock-origin
vimium
youtube-shorts-block
];
@ -45,6 +47,10 @@
name = "NixOS Search";
url = "https://search.nixos.org";
}
{
name = "NUR Search";
url = "https://nur.nix-community.org";
}
{
name = "Home Manager Options List";
url = "https://nix-community.github.io/home-manager/options.xhtml";

View File

@ -2,6 +2,7 @@
config,
pkgs,
inputs,
flakeDir,
...
}: {
programs.fish = {
@ -32,20 +33,20 @@
fish_greeting = "";
nor = ''
doas nixos-rebuild switch --flake ${config.home.homeDirectory}/.dotfiles
doas nixos-rebuild switch --flake ${flakeDir}
'';
hms = ''
home-manager switch --flake ${config.home.homeDirectory}/.dotfiles
home-manager switch --flake ${flakeDir}
'';
nou = ''
nix flake update ${config.home.homeDirectory}/.dotfiles --commit-lock-file
doas nixos-rebuild switch --upgrade --flake ${config.home.homeDirectory}/.dotfiles
nix flake update ${flakeDir} --commit-lock-file
doas nixos-rebuild switch --upgrade --flake ${flakeDir}
'';
};
shellAliases = {
ec = "hx ~/.dotfiles";
ec = "hx ${flakeDir}";
nf = "${pkgs.fastfetch}/bin/fastfetch";
ls = "${pkgs.eza}/bin/eza --icons";
ll = "${pkgs.eza}/bin/eza --icons -l";

View File

@ -2,6 +2,7 @@
config,
inputs,
pkgs,
flakeDir,
...
}: {
programs.helix = {
@ -13,6 +14,21 @@
custom-gruvbox = {
inherits = "gruvbox";
"ui.background" = {bg = "none";};
"ui.statusline.normal" = {
bg = "#AA9A85";
fg = "#232323";
modifiers = ["bold"];
};
"ui.statusline.insert" = {
bg = "#84A799";
fg = "#232323";
modifiers = ["bold"];
};
"ui.statusline.select" = {
bg = "#FE8112";
fg = "#232323";
modifiers = ["bold"];
};
};
};
@ -36,8 +52,7 @@
statusline = {
separator = "|";
left = ["mode" "separator" "spinner"];
center = ["file-name"];
left = ["mode" "file-name"];
right = ["selections" "file-type" "position"];
mode.normal = "NORMAL";
@ -53,7 +68,7 @@
keys.normal = {
"esc" = ["collapse_selection" "keep_primary_selection"];
space."e" = ":open ~/.dotfiles";
space."e" = ":open ${flakeDir}";
};
};

View File

@ -1,24 +1,4 @@
{pkgs, ...}: let
previewer = pkgs.writeShellScriptBin "pv.sh" ''
file=$1
w=$2
h=$3
x=$4
y=$5
if [[ "$( ${pkgs.file}/bin/file -Lb --mime-type "$file")" =~ ^image ]]; then
# ''${pkgs.kitty}/bin/kitty +kitten icat --silent --stdin no --transfer-mode file --place "''${w}x''${h}@''${x}x''${y}" "$file" < /dev/null > /dev/tty
${pkgs.chafa}/bin/chafa -f kitty "$file"
exit 1
fi
${pkgs.pistol}/bin/pistol "$file"
'';
cleaner = pkgs.writeShellScriptBin "clean.sh" ''
${pkgs.kitty}/bin/kitty +kitten icat --clear --stdin no --silent --transfer-mode file < /dev/null > /dev/tty
'';
in {
{pkgs, ...}: {
xdg.configFile."lf/icons".source = ./icons;
programs.lf = {
@ -29,10 +9,7 @@ in {
icons = true;
ignorecase = true;
preview = true;
#image previewer
cleaner = "${cleaner}/bin/clean.sh";
previewer = "${previewer}/bin/pv.sh";
sixel = true;
};
};
}

View File

@ -1,4 +1,4 @@
{
{pkgs, ...}: {
programs.mpv = {
enable = true;
config = {
@ -7,6 +7,14 @@
hwdec = "vaapi";
force-window = "yes";
ao = "pipewire";
video-sync = "display-resample";
};
scripts = with pkgs.mpvScripts; [
quality-menu
uosc
sponsorblock
thumbfast
];
};
}

View File

@ -5,5 +5,9 @@
}: {
programs.tmux = {
enable = true;
plugins = with pkgs; [
tmuxPlugins.sensible
];
};
}

View File

@ -1,5 +1,5 @@
(defpoll TIME :interval "1s" "date '+%H:%M'")
(defpoll VOL :interval "1s" "scripts/getvol")
;; (defpoll VOL :interval "1s" "scripts/getvol")
(deflisten ACTIVEWINDOW :initial "[]" "hyprland-activewindow _")
(deflisten WORKSPACE0 :initial "[]" "hyprland-workspaces $(hyprctl monitors -j | jq -r \".[0].name\")")
@ -88,10 +88,10 @@
)
(defwidget widget_time [monitor]
(box
:class "widget-time"
TIME
)
(box
:class "widget-time"
TIME
)
)
;; --------------------------

View File

@ -26,7 +26,7 @@
[Desktop Action setSWWWWallpaper]
Name=Set Image as Wallpaper
Exec=swww img "%f" && ln -sf "%f" ~/.cache/swww/wallpaper
Exec=swww img "%f"
'';
home.packages = [

View File

@ -101,7 +101,6 @@
"${pkgs.openrgb}/bin/openrgb --startminimized --profile autorun.orp"
"${pkgs.polkit_gnome}/libexec/polkit-gnome-authentication-agent-1"
"${pkgs.ydotool}/bin/ydotoold"
"${pkgs.bitwarden}/bin/bitwarden"
];
exec = [
@ -125,12 +124,12 @@
"${modKey}, 5, workspace, 5"
"${modKey}, 6, workspace, 6"
"${modKey} SHIFT, 1, movetoworkspace, 1"
"${modKey} SHIFT, 2, movetoworkspace, 2"
"${modKey} SHIFT, 3, movetoworkspace, 3"
"${modKey} SHIFT, 4, movetoworkspace, 4"
"${modKey} SHIFT, 5, movetoworkspace, 5"
"${modKey} SHIFT, 6, movetoworkspace, 6"
"${modKey} SHIFT, 1, movetoworkspacesilent, 1"
"${modKey} SHIFT, 2, movetoworkspacesilent, 2"
"${modKey} SHIFT, 3, movetoworkspacesilent, 3"
"${modKey} SHIFT, 4, movetoworkspacesilent, 4"
"${modKey} SHIFT, 5, movetoworkspacesilent, 5"
"${modKey} SHIFT, 6, movetoworkspacesilent, 6"
"${modKey}, P, pseudo, # dwindle"
"${modKey}, J, togglesplit, # dwindle"

View File

@ -23,7 +23,7 @@
font = wezterm.font "JetBrainsMono Nerd Font",
font_size = 10,
color_scheme = 'Gruvbox Dark (Gogh)',
color_scheme = "Gruvbox Dark (Gogh)",
hide_tab_bar_if_only_one_tab = true,
line_height = 1.1,
window_background_opacity = 0.9,

View File

@ -3,6 +3,7 @@
pkgs,
lib,
inputs,
userName,
...
}: {
imports = [
@ -23,8 +24,8 @@
./configs/xdg-mime.nix
];
home.username = "manuel";
home.homeDirectory = "/home/manuel";
home.username = "${userName}";
home.homeDirectory = "/home/${userName}";
home.packages = with pkgs; [
appimage-run
armcord
@ -72,15 +73,17 @@
twemoji-color-font
vimv
vulkan-tools
wineWowPackages.staging
winetricks
wqy_zenhei #fix for missing non-ascii fonts in TF2
xdg-utils
];
home.sessionVariables = {
GTK_THEME = "${builtins.toString config.gtk.theme.name}";
NIXOS_OZONE_WL = "1";
NIXPKGS_ALLOW_UNFREE = "1";
WINEDEBUG = "fixme-all";
WINEDLLOVERRIDES = "winemenubuilder.exe=d";
};
@ -162,6 +165,14 @@
enable = true;
plugins = [pkgs.obs-studio-plugins.obs-vkcapture];
};
rbw = {
enable = true;
settings = {
pinentry = "gtk2";
email = "varris@posteo.net";
};
};
};
services.gnome-keyring.enable = true;
@ -179,6 +190,9 @@
download = "/mnt/hdd/Downloads";
};
home.file."Downloads".source = config.lib.file.mkOutOfStoreSymlink "/mnt/hdd/Downloads";
home.file."Music".source = config.lib.file.mkOutOfStoreSymlink "/mnt/hdd/Music";
programs.home-manager.enable = true;
home.stateVersion = "23.05";