mirror of
https://github.com/thilobillerbeck/dotfiles.git
synced 2024-12-26 21:30:51 +01:00
updated dotfiles
This commit is contained in:
parent
757ec9bab0
commit
8450ff1abd
1 changed files with 179 additions and 88 deletions
267
home.nix
267
home.nix
|
@ -1,10 +1,25 @@
|
|||
{ config, pkgs, lib, ... }:
|
||||
let
|
||||
chromeArgs = "--force-dark-mode --enable-features=WebUIDarkMode --enable-smooth-scrolling --ozone-platform-hint=auto --ignore-gpu-blocklist --enable-gpu-rasterization --enable-zero-copy";
|
||||
let
|
||||
chromeArgs =
|
||||
"--force-dark-mode --enable-features=WebUIDarkMode --enable-smooth-scrolling --ozone-platform-hint=auto --ignore-gpu-blocklist --enable-gpu-rasterization --enable-zero-copy";
|
||||
nixgl = import <nixgl> { };
|
||||
nixGLWrap = pkg:
|
||||
pkgs.runCommand "${pkg.name}-nixgl-wrapper" { } ''
|
||||
mkdir $out
|
||||
ln -s ${pkg}/* $out
|
||||
rm $out/bin
|
||||
mkdir $out/bin
|
||||
for bin in ${pkg}/bin/*; do
|
||||
wrapped_bin=$out/bin/$(basename $bin)
|
||||
echo "exec ${lib.getExe nixgl.auto.nixGLDefault} $bin \$@" > $wrapped_bin
|
||||
chmod +x $wrapped_bin
|
||||
done
|
||||
'';
|
||||
in {
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
targets.genericLinux.enable = true;
|
||||
|
||||
news.display = "silent";
|
||||
|
||||
home = {
|
||||
username = "thilo";
|
||||
homeDirectory = "/home/thilo";
|
||||
|
@ -15,15 +30,17 @@ in {
|
|||
pkgs.cargo-update
|
||||
pkgs.htop
|
||||
pkgs.rustup
|
||||
(pkgs.nerdfonts.override { fonts = [ "JetBrainsMono" "FiraCode" "FiraMono" ]; })
|
||||
(pkgs.vivaldi.override {
|
||||
pkgs.nixfmt
|
||||
(pkgs.nerdfonts.override {
|
||||
fonts = [ "JetBrainsMono" "FiraCode" "FiraMono" ];
|
||||
})
|
||||
(nixGLWrap (pkgs.vivaldi.override {
|
||||
proprietaryCodecs = true;
|
||||
enableWidevine = true;
|
||||
commandLineArgs = chromeArgs;
|
||||
})
|
||||
(pkgs.google-chrome.override {
|
||||
commandLineArgs = chromeArgs;
|
||||
})
|
||||
}))
|
||||
(nixGLWrap
|
||||
(pkgs.google-chrome.override { commandLineArgs = chromeArgs; }))
|
||||
(pkgs.writeShellScriptBin "ssh-fix-permissions" ''
|
||||
chmod 700 ~/.ssh
|
||||
chmod 600 ~/.ssh/*
|
||||
|
@ -31,28 +48,25 @@ in {
|
|||
'')
|
||||
];
|
||||
file = {
|
||||
".config/htop/htoprc".source = ./dotfiles/htoprc;
|
||||
".config/nano/nanorc".source = ./dotfiles/nanorc;
|
||||
".config/locale.conf".source = ./dotfiles/locale.conf;
|
||||
".ssh/config".source = ./dotfiles/ssh-config;
|
||||
".config/beets/config.yaml".source = ./dotfiles/beets.yaml;
|
||||
};
|
||||
sessionVariables = {
|
||||
|
||||
|
||||
};
|
||||
activation = {
|
||||
linkDesktopApplications = {
|
||||
after = [ "writeBoundary" "createXdgUserDirectories" ];
|
||||
before = [ ];
|
||||
data = ''
|
||||
rm -rf ${config.xdg.dataHome}/"applications/home-manager"
|
||||
mkdir -p ${config.xdg.dataHome}/"applications/home-manager"
|
||||
cp -Lr ${config.home.homeDirectory}/.nix-profile/share/applications/* ${config.xdg.dataHome}/"applications/home-manager/"
|
||||
for dir in ${config.home.homeDirectory}/.nix-profile/share/applications/*; do
|
||||
chmod +x $(realpath $dir) -v
|
||||
done
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
;
|
||||
};
|
||||
xdg = {
|
||||
enable = true;
|
||||
mime.enable = true;
|
||||
|
@ -62,7 +76,77 @@ in {
|
|||
home-manager.enable = true;
|
||||
vscode = {
|
||||
enable = true;
|
||||
package = pkgs.vscode.override { commandLineArgs = "--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations --gtk-version=4"; };
|
||||
package = (nixGLWrap (pkgs.vscode.override {
|
||||
commandLineArgs =
|
||||
"--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations --gtk-version=4";
|
||||
}));
|
||||
};
|
||||
htop = {
|
||||
enable = true;
|
||||
settings = {
|
||||
fields="0 48 17 18 38 39 40 2 46 47 49 1";
|
||||
sort_key="46";
|
||||
sort_direction="1";
|
||||
tree_sort_key="0";
|
||||
tree_sort_direction="1";
|
||||
hide_kernel_threads="1";
|
||||
hide_userland_threads="0";
|
||||
shadow_other_users="0";
|
||||
show_thread_names="0";
|
||||
show_program_path="1";
|
||||
highlight_base_name="0";
|
||||
highlight_megabytes="1";
|
||||
highlight_threads="1";
|
||||
highlight_changes="0";
|
||||
highlight_changes_delay_secs="5";
|
||||
find_comm_in_cmdline="1";
|
||||
strip_exe_from_cmdline="1";
|
||||
show_merged_command="0";
|
||||
tree_view="1";
|
||||
tree_view_always_by_pid="0";
|
||||
header_margin="1";
|
||||
detailed_cpu_time="0";
|
||||
cpu_count_from_one="0";
|
||||
show_cpu_usage="1";
|
||||
show_cpu_frequency="0";
|
||||
show_cpu_temperature="0";
|
||||
degree_fahrenheit="0";
|
||||
update_process_names="0";
|
||||
account_guest_in_cpu_meter="0";
|
||||
color_scheme="0";
|
||||
enable_mouse="1";
|
||||
delay="15";
|
||||
left_meters="LeftCPUs2 CPU Memory DiskIO NetworkIO";
|
||||
left_meter_modes="1 1 1 2 2";
|
||||
right_meters="RightCPUs2 Tasks LoadAverage Uptime Battery";
|
||||
right_meter_modes="1 2 2 2 2";
|
||||
hide_function_bar="0";
|
||||
};
|
||||
};
|
||||
beets = {
|
||||
enable = true;
|
||||
settings = {
|
||||
directory = "~/Music/dj/Library";
|
||||
library = "~/Music/dj/library.db";
|
||||
plugins = "spotify acousticbrainz badfiles duplicates fetchart";
|
||||
import = {
|
||||
write = "yes";
|
||||
copy = "yes";
|
||||
resume = "no";
|
||||
duplicate_action = "ask";
|
||||
default_action = "apply";
|
||||
};
|
||||
badfiles = {
|
||||
check_on_import = "yes";
|
||||
};
|
||||
match = {
|
||||
max_rec = {
|
||||
track_length = "strong";
|
||||
track_title = "strong";
|
||||
track_artist = "strong";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
zsh = {
|
||||
enable = true;
|
||||
|
@ -70,6 +154,27 @@ in {
|
|||
enableCompletion = true;
|
||||
enableSyntaxHighlighting = true;
|
||||
enableVteIntegration = true;
|
||||
zplug = {
|
||||
enable = true;
|
||||
plugins = [
|
||||
{
|
||||
name = "plugins/git";
|
||||
tags = [ from:oh-my-zsh ];
|
||||
}
|
||||
{
|
||||
name = "plugins/archlinux";
|
||||
tags = [ from:oh-my-zsh ];
|
||||
}
|
||||
{
|
||||
name = "plugins/composer";
|
||||
tags = [ from:oh-my-zsh ];
|
||||
}
|
||||
{
|
||||
name = "plugins/colored-man-pages";
|
||||
tags = [ from:oh-my-zsh ];
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
git = {
|
||||
enable = true;
|
||||
|
@ -80,28 +185,20 @@ in {
|
|||
color = {
|
||||
diff = "auto";
|
||||
status = "auto";
|
||||
branch = "auto";
|
||||
branch = "auto";
|
||||
interactive = "auto";
|
||||
ui = true;
|
||||
pager = true;
|
||||
};
|
||||
log = {
|
||||
date = "short";
|
||||
};
|
||||
rerere = {
|
||||
enabled = "1";
|
||||
};
|
||||
log = { date = "short"; };
|
||||
rerere = { enabled = "1"; };
|
||||
core = {
|
||||
whitespace="fix,-indent-with-non-tab,trailing-space,cr-at-eol";
|
||||
whitespace = "fix,-indent-with-non-tab,trailing-space,cr-at-eol";
|
||||
excludesfile = "~/.gitignore-rab";
|
||||
autocrlf = "input";
|
||||
};
|
||||
apply = {
|
||||
whitespace = "nowarn";
|
||||
};
|
||||
branch = {
|
||||
autosetuprebase = "always";
|
||||
};
|
||||
apply = { whitespace = "nowarn"; };
|
||||
branch = { autosetuprebase = "always"; };
|
||||
};
|
||||
};
|
||||
direnv = {
|
||||
|
@ -112,89 +209,83 @@ in {
|
|||
enable = true;
|
||||
settings = {
|
||||
add_newline = false;
|
||||
character = {
|
||||
success_symbol = "[❯](bold white)";
|
||||
};
|
||||
package = {
|
||||
disabled = true;
|
||||
};
|
||||
character = { success_symbol = "[❯](bold white)"; };
|
||||
package = { disabled = true; };
|
||||
};
|
||||
};
|
||||
topgrade = {
|
||||
enable = true;
|
||||
settings = {
|
||||
assume_yes = true;
|
||||
ignore_failures = ["git_repos"];
|
||||
ignore_failures = [ "git_repos" ];
|
||||
no_retry = true;
|
||||
pre_sudo = false;
|
||||
cleanup = true;
|
||||
skip_notify = true;
|
||||
firmware = {
|
||||
upgrade = true;
|
||||
};
|
||||
firmware = { upgrade = true; };
|
||||
};
|
||||
};
|
||||
alacritty = {
|
||||
enable = true;
|
||||
package = (nixGLWrap pkgs.alacritty);
|
||||
settings = {
|
||||
window = {
|
||||
decorations = "full";
|
||||
dynamic_title = true;
|
||||
gtk_theme_variant = "None";
|
||||
decorations = "full";
|
||||
dynamic_title = true;
|
||||
gtk_theme_variant = "None";
|
||||
};
|
||||
background_opacity = 1;
|
||||
window.opacity = 1;
|
||||
font = {
|
||||
normal = {
|
||||
family = "FiraMono Nerd Font";
|
||||
style = "Regular";
|
||||
};
|
||||
bold = {
|
||||
family = "FiraMono Nerd Font";
|
||||
style = "Bold";
|
||||
};
|
||||
size = 14;
|
||||
offset = {
|
||||
x = 1;
|
||||
};
|
||||
normal = {
|
||||
family = "FiraMono Nerd Font";
|
||||
style = "Regular";
|
||||
};
|
||||
cursor.style.shape = "Beam";
|
||||
colors = {
|
||||
primary = {
|
||||
background = "0x282a36";
|
||||
foreground = "0xeff0eb";
|
||||
};
|
||||
normal = {
|
||||
black = "0x282a36";
|
||||
red = "0xff5c57";
|
||||
green = "0x5af78e";
|
||||
yellow = "0xf3f99d";
|
||||
blue = "0x57c7ff";
|
||||
magenta = "0xff6ac1";
|
||||
cyan = "0x9aedfe";
|
||||
white = "0xf1f1f0";
|
||||
};
|
||||
bright = {
|
||||
black = "0x686868";
|
||||
red = "0xff5c57";
|
||||
green = "0x5af78e";
|
||||
yellow = "0xf3f99d";
|
||||
blue = "0x57c7ff";
|
||||
magenta = "0xff6ac1";
|
||||
cyan = "0x9aedfe";
|
||||
white = "0xf1f1f0";
|
||||
};
|
||||
bold = {
|
||||
family = "FiraMono Nerd Font";
|
||||
style = "Bold";
|
||||
};
|
||||
size = 14;
|
||||
offset = { x = 1; };
|
||||
};
|
||||
cursor.style.shape = "Beam";
|
||||
colors = {
|
||||
primary = {
|
||||
background = "0x282a36";
|
||||
foreground = "0xeff0eb";
|
||||
};
|
||||
normal = {
|
||||
black = "0x282a36";
|
||||
red = "0xff5c57";
|
||||
green = "0x5af78e";
|
||||
yellow = "0xf3f99d";
|
||||
blue = "0x57c7ff";
|
||||
magenta = "0xff6ac1";
|
||||
cyan = "0x9aedfe";
|
||||
white = "0xf1f1f0";
|
||||
};
|
||||
bright = {
|
||||
black = "0x686868";
|
||||
red = "0xff5c57";
|
||||
green = "0x5af78e";
|
||||
yellow = "0xf3f99d";
|
||||
blue = "0x57c7ff";
|
||||
magenta = "0xff6ac1";
|
||||
cyan = "0x9aedfe";
|
||||
white = "0xf1f1f0";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
yt-dlp = {
|
||||
enable = true;
|
||||
};
|
||||
neovim = {
|
||||
defaultEditor = true;
|
||||
enable = true;
|
||||
viAlias = true;
|
||||
vimAlias = true;
|
||||
vimdiffAlias = true;
|
||||
coc = {
|
||||
enable = true;
|
||||
};
|
||||
coc = { enable = true; };
|
||||
extraConfig = ''
|
||||
set title
|
||||
set number
|
||||
|
@ -218,4 +309,4 @@ in {
|
|||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue