blabla
This commit is contained in:
2
.gitignore
vendored
2
.gitignore
vendored
@ -2,4 +2,4 @@
|
||||
!*.secret
|
||||
configs/secrets.nix
|
||||
configs/secrets-desktop.nix
|
||||
configs/secrets-wireguard-publickeys.nix
|
||||
configs/secrets-thinkpad.nix
|
||||
|
217
configs/bspwm.nix
Normal file
217
configs/bspwm.nix
Normal file
@ -0,0 +1,217 @@
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
let
|
||||
unstable = import <nixos-unstable> { config.allowUnfree = true; };
|
||||
in
|
||||
{
|
||||
|
||||
services = {
|
||||
xserver = {
|
||||
enable = true;
|
||||
displayManager = {
|
||||
lightdm = {
|
||||
enable = true;
|
||||
background = pkgs.nixos-artwork.wallpapers.nineish-dark-gray.gnomeFilePath;
|
||||
greeters.gtk.theme = {
|
||||
name = "Adwaita-dark";
|
||||
};
|
||||
};
|
||||
defaultSession = "xsession";
|
||||
session = [{
|
||||
manage = "desktop";
|
||||
name = "xsession";
|
||||
start = ''exec $HOME/.xsession'';
|
||||
}];
|
||||
};
|
||||
|
||||
desktopManager = {
|
||||
gnome.enable = true;
|
||||
xfce = {
|
||||
enable = true;
|
||||
noDesktop = true;
|
||||
enableXfwm = true;
|
||||
thunarPlugins = [ pkgs.xfce.thunar-archive-plugin ];
|
||||
};
|
||||
};
|
||||
layout = "us";
|
||||
# Enable touchpad support.
|
||||
libinput.enable = true;
|
||||
updateDbusEnvironment = true;
|
||||
};
|
||||
};
|
||||
|
||||
home-manager.users.alex = { pkgs, ... }: {
|
||||
services = {
|
||||
# picom = {
|
||||
# enable = true;
|
||||
# blur = true;
|
||||
# shadow = true;
|
||||
# vSync = true;
|
||||
# };
|
||||
|
||||
dunst = {
|
||||
enable = true;
|
||||
settings = {
|
||||
global = {
|
||||
font = "SF Pro Display Regular 12";
|
||||
markup = "yes";
|
||||
format = "%s %p\n%b";
|
||||
sort = "yes";
|
||||
indicate_hidden = "no";
|
||||
alignment = "center";
|
||||
bounce_freq = 0;
|
||||
show_age_threshold = 60;
|
||||
word_wrap = "yes";
|
||||
ignore_newline = "no";
|
||||
geometry = "300x0-5-5";
|
||||
shrink = "yes";
|
||||
transparency = 0;
|
||||
idle_threshold = 120;
|
||||
monitor = 0;
|
||||
follow = "mouse";
|
||||
sticky_history = "yes";
|
||||
history_length = 20;
|
||||
show_indicators = "no";
|
||||
line_height = 0;
|
||||
separator_height = 1;
|
||||
stack_duplicates = "no";
|
||||
padding = 8;
|
||||
horizontal_padding = 8;
|
||||
separator_color = "frame";
|
||||
startup_notification = true;
|
||||
# dmenu = /usr/bin/dmenu -p dunst;
|
||||
# browser = /usr/bin/firefox -new-tab;
|
||||
icon_position = "left";
|
||||
icon_path = "/usr/share/icons/Arc";
|
||||
max_icon_size = 64;
|
||||
};
|
||||
|
||||
frame = {
|
||||
width = 1;
|
||||
color = "#A6A6A6";
|
||||
};
|
||||
|
||||
urgency_low = {
|
||||
background = "#000000";
|
||||
foreground = "#A6A6A6";
|
||||
timeout = 4;
|
||||
};
|
||||
|
||||
urgency_normal = {
|
||||
background = "#000000";
|
||||
foreground = "#A6A6A6";
|
||||
timeout = 4;
|
||||
};
|
||||
|
||||
urgency_critical = {
|
||||
background = "#900000";
|
||||
foreground = "#ffffff";
|
||||
timeout = 16;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
sxhkd = {
|
||||
enable = true;
|
||||
keybindings = {
|
||||
"super + x" = "notify-send Time $(date '+%H:%M')";
|
||||
"super + z" = "notify-send Battery $(cat /sys/class/power_supply/BAT0/capacity)%";
|
||||
"alt + Tab" = "rofi -show window";
|
||||
"super + Return" = "kitty";
|
||||
"super + shift + Return" = "rofi -show drun";
|
||||
"super + Escape" = "pkill -USR1 -x sxhkd";
|
||||
"super {_,shift + }Tab" = "bspc node -f {next,prev}";
|
||||
"super + shift + c" = "bspc node -c";
|
||||
"super + a" = "bspc node @/ --flip vertical";
|
||||
"super + d" = ''layer=normal; \
|
||||
bspc query -N -n "focused.$\{layer\}" && layer=below; \
|
||||
bspc node -l "$layer"'';
|
||||
"super + {s,f,k}" =
|
||||
''state={floating,fullscreen,pseudo_tiled}; \
|
||||
bspc query -N -n "focused.$\{state\}" && state=tiled; \
|
||||
bspc node -t "$state" '';
|
||||
"super + alt + {Left,Down,Up,Right}" = "bspc node -p {west,south,north,east}";
|
||||
"super + ctrl + {Left,Right,Up,Down}" = "xdo move {-x -50,-x +50,-y -50,-y +50}";
|
||||
"super + ctrl + alt + {Left,Right,Up,Down}" = "xdo resize {-w -50,-w +50,-h -50,-h +50}";
|
||||
"super + {_,shift + }{Left,Down,Up,Right}" = "bspc node -{f,s} {west,south,north,east}";
|
||||
"super + m" = "bspc node -s biggest";
|
||||
"super + l" = "~/.bin/lock";
|
||||
"super + ctrl + space" = "bspc node -p cancel";
|
||||
"super + apostrophe" = "bspc node -s last";
|
||||
"super + ctrl + comma" = "bspc node @/ --rotate 90";
|
||||
"super + shift + comma" = "bspc node @/ --circulate forward";
|
||||
"super + {1-9,0}" = "bspc desktop -f '{I,II,III,IV,V,VI,VII,VIII,IX,X}' && notify-send `bspc query -D -d --names`";
|
||||
"super + shift + {1-9,0}" = "bspc node -d '{I,II,III,IV,V,VI,VII,VIII,IX,X}'";
|
||||
# "XF86AudioMute" = "pulseaudio-ctl mute";
|
||||
# "XF86AudioLowerVolume" = "pulseaudio-ctl down";
|
||||
# "XF86AudioRaiseVolume" = "pulseaudio-ctl up";
|
||||
"Print" = "flameshot gui";
|
||||
"super + v" = "bspc node -g hidden";
|
||||
"super + shift + v" = "bspc node {,$(bspc query -N -n .hidden |tail -n 1)} -g hidden=off -d $(bspc query -D -d focused --names) -t floating -f";
|
||||
};
|
||||
};
|
||||
|
||||
nextcloud-client = {
|
||||
enable = true;
|
||||
startInBackground = true;
|
||||
};
|
||||
|
||||
redshift = {
|
||||
enable = true;
|
||||
duskTime = "21:00-22:00";
|
||||
dawnTime = "06:30-07:00";
|
||||
package = pkgs.redshift;
|
||||
};
|
||||
|
||||
flameshot.enable = true;
|
||||
};
|
||||
|
||||
xsession = {
|
||||
enable = true;
|
||||
pointerCursor = {
|
||||
defaultCursor = "left_ptr";
|
||||
name = "elementary";
|
||||
package = pkgs.pantheon.elementary-icon-theme;
|
||||
};
|
||||
windowManager = {
|
||||
command = pkgs.lib.mkForce ''
|
||||
${pkgs.bspwm}/bin/bspwm -c ~/.config/bspwm/bspwmrc &
|
||||
${pkgs.xfce.xfce4-session}/bin/xfce4-session
|
||||
'';
|
||||
bspwm = {
|
||||
enable = true;
|
||||
extraConfig = ''
|
||||
bspc wm --adopt-orphans
|
||||
|
||||
node /home/alex/Sync/windows.js
|
||||
bspc subscribe monitor_add monitor_remove| while read -r a event; do
|
||||
node /home/alex/Sync/windows.js
|
||||
done &
|
||||
'';
|
||||
settings = {
|
||||
border_width = 4;
|
||||
window_gap = 5;
|
||||
top_padding = 0;
|
||||
left_padding = 0;
|
||||
right_padding = 0;
|
||||
bottom_padding = 0;
|
||||
split_ratio = 0.50;
|
||||
borderless_monocle = true;
|
||||
single_monocle = true;
|
||||
gapless_monocle = true;
|
||||
focus_follows_pointer = true;
|
||||
pointer_follows_monitor = true;
|
||||
pointer_follows_focus = false;
|
||||
center_pseudo_tiled = true;
|
||||
automatic_scheme = "alternate";
|
||||
remove_unplugged_monitors = true;
|
||||
remove_disabled_monitors = true;
|
||||
normal_border_color = "#333333";
|
||||
focused_border_color = "#666666";
|
||||
presel_feedback_color = "#000000";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
@ -71,7 +71,7 @@ in
|
||||
nix-du
|
||||
nix-tree
|
||||
nmap
|
||||
nodejs
|
||||
nodejs-16_x
|
||||
parallel
|
||||
pciutils
|
||||
ruby
|
||||
|
@ -1,7 +1,8 @@
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
let
|
||||
unstable = import <nixos-unstable> { config.allowUnfree = true; };
|
||||
in
|
||||
{
|
||||
|
||||
nixpkgs.config = {
|
||||
allowUnfree = true;
|
||||
allowBroken = true;
|
||||
@ -15,7 +16,7 @@
|
||||
};
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
environment.systemPackages = with unstable.pkgs; [
|
||||
chromium
|
||||
fswebcam
|
||||
glxinfo
|
||||
@ -24,13 +25,9 @@
|
||||
lightlocker
|
||||
networkmanager-openconnect
|
||||
openconnect
|
||||
pantheon.elementary-gtk-theme
|
||||
pantheon.elementary-icon-theme
|
||||
ponymix
|
||||
pulseaudio-ctl
|
||||
python39Packages.pyyaml
|
||||
|
||||
i3pystatus (python38.withPackages(ps: with ps; [ i3pystatus keyring ]))
|
||||
];
|
||||
|
||||
programs = {
|
||||
@ -84,30 +81,6 @@
|
||||
"CloudPrintSubmitEnabled" = false;
|
||||
};
|
||||
};
|
||||
|
||||
# sway = {
|
||||
# enable = true;
|
||||
# extraPackages = with pkgs; [
|
||||
# dmenu
|
||||
# swaylock
|
||||
# swayidle
|
||||
# xwayland
|
||||
# mako
|
||||
# kanshi
|
||||
# grim
|
||||
# slurp
|
||||
# wl-clipboard
|
||||
# wf-recorder
|
||||
# (python38.withPackages(ps: with ps; [ i3pystatus keyring ]))
|
||||
# ];
|
||||
# extraSessionCommands = ''
|
||||
# export SDL_VIDEODRIVER=wayland
|
||||
# export QT_QPA_PLATFORM=wayland
|
||||
# export QT_WAYLAND_DISABLE_WINDOWDECORATION="1"
|
||||
# export _JAVA_AWT_WM_NONREPARENTING=1
|
||||
# export MOZ_ENABLE_WAYLAND=1
|
||||
# '';
|
||||
# };
|
||||
};
|
||||
|
||||
fonts = {
|
||||
@ -143,30 +116,6 @@
|
||||
|
||||
hardware.bluetooth.enable = true;
|
||||
|
||||
# systemd.user.targets.sway-session = {
|
||||
# description = "Sway compositor session";
|
||||
# documentation = [ "man:systemd.special(7)" ];
|
||||
# bindsTo = [ "graphical-session.target" ];
|
||||
# wants = [ "graphical-session-pre.target" ];
|
||||
# after = [ "graphical-session-pre.target" ];
|
||||
# };
|
||||
|
||||
# systemd.user.services.kanshi = {
|
||||
# description = "Kanshi output autoconfig ";
|
||||
# wantedBy = [ "graphical-session.target" ];
|
||||
# partOf = [ "graphical-session.target" ];
|
||||
# environment = { XDG_CONFIG_HOME="/home/alex/.config"; };
|
||||
# serviceConfig = {
|
||||
# # kanshi doesn't have an option to specifiy config file yet, so it looks
|
||||
# # at .config/kanshi/config
|
||||
# ExecStart = ''
|
||||
# ${pkgs.kanshi}/bin/kanshi
|
||||
# '';
|
||||
# RestartSec = 5;
|
||||
# Restart = "always";
|
||||
# };
|
||||
# };
|
||||
|
||||
services = {
|
||||
blueman.enable = true;
|
||||
udev.packages = with pkgs; [ gnome.gnome-settings-daemon ];
|
||||
@ -174,45 +123,5 @@
|
||||
enable = true;
|
||||
drivers = [ pkgs.brlaser ];
|
||||
};
|
||||
xserver = {
|
||||
enable = true;
|
||||
|
||||
# displayManager.defaultSession = "sway";
|
||||
# displayManager.sddm.enable = true;
|
||||
|
||||
# displayManager = {
|
||||
# lightdm = {
|
||||
# enable = true;
|
||||
# background = pkgs.nixos-artwork.wallpapers.nineish-dark-gray.gnomeFilePath;
|
||||
# # greeters.gtk.theme = {
|
||||
# # package = pkgs.pantheon.elementary-gtk-theme;
|
||||
# # name = "elementary";
|
||||
# # };
|
||||
# greeters.pantheon.enable = true;
|
||||
# };
|
||||
# defaultSession = "xsession";
|
||||
# session = [{
|
||||
# manage = "desktop";
|
||||
# name = "xsession";
|
||||
# start = ''exec $HOME/.xsession'';
|
||||
# }];
|
||||
# };
|
||||
|
||||
|
||||
displayManager.gdm.enable = true;
|
||||
desktopManager.gnome.enable = true;
|
||||
# desktopManager = {
|
||||
# xfce = {
|
||||
# enable = true;
|
||||
# noDesktop = true;
|
||||
# enableXfwm = true;
|
||||
# thunarPlugins = [ pkgs.xfce.thunar-archive-plugin ];
|
||||
# };
|
||||
# };
|
||||
layout = "us";
|
||||
# Enable touchpad support.
|
||||
libinput.enable = true;
|
||||
updateDbusEnvironment = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
54
configs/sway.nix
Normal file
54
configs/sway.nix
Normal file
@ -0,0 +1,54 @@
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
let
|
||||
unstable = import <nixos-unstable> { config.allowUnfree = true; };
|
||||
in
|
||||
{
|
||||
programs = {
|
||||
sway = {
|
||||
enable = true;
|
||||
extraPackages = with pkgs; [
|
||||
wofi
|
||||
swaylock
|
||||
swayidle
|
||||
xwayland
|
||||
kanshi
|
||||
grim
|
||||
slurp
|
||||
wl-clipboard
|
||||
(python38.withPackages(ps: with ps; [ i3pystatus keyring ]))
|
||||
];
|
||||
extraSessionCommands = ''
|
||||
export SDL_VIDEODRIVER=wayland
|
||||
export QT_QPA_PLATFORM=wayland
|
||||
export QT_WAYLAND_DISABLE_WINDOWDECORATION="1"
|
||||
export _JAVA_AWT_WM_NONREPARENTING=1
|
||||
export MOZ_ENABLE_WAYLAND=1
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
systemd.user.targets.sway-session = {
|
||||
description = "Sway compositor session";
|
||||
documentation = [ "man:systemd.special(7)" ];
|
||||
bindsTo = [ "graphical-session.target" ];
|
||||
wants = [ "graphical-session-pre.target" ];
|
||||
after = [ "graphical-session-pre.target" ];
|
||||
};
|
||||
|
||||
systemd.user.services.kanshi = {
|
||||
description = "Kanshi output autoconfig ";
|
||||
wantedBy = [ "graphical-session.target" ];
|
||||
partOf = [ "graphical-session.target" ];
|
||||
environment = { XDG_CONFIG_HOME="/home/alex/.config"; };
|
||||
serviceConfig = {
|
||||
# kanshi doesn't have an option to specifiy config file yet, so it looks
|
||||
# at .config/kanshi/config
|
||||
ExecStart = ''
|
||||
${pkgs.kanshi}/bin/kanshi
|
||||
'';
|
||||
RestartSec = 5;
|
||||
Restart = "always";
|
||||
};
|
||||
};
|
||||
}
|
@ -6,16 +6,6 @@ in
|
||||
{
|
||||
imports = [ <home-manager/nixos> ];
|
||||
|
||||
# systemd.user.services.barrierc = {
|
||||
# Unit = {
|
||||
# Description = "Barrier Server daemon";
|
||||
# After = [ "graphical-session-pre.target" ];
|
||||
# PartOf = [ "graphical-session.target" ];
|
||||
# };
|
||||
# Install.WantedBy = [ "graphical-session.target" ];
|
||||
# Service.ExecStart = "${unstable.pkgs.barrier}/bin/barrierc -c ~/.barrier";
|
||||
# };
|
||||
|
||||
home-manager.users.alex = { pkgs, ... }: {
|
||||
home = {
|
||||
file = {
|
||||
@ -34,13 +24,6 @@ in
|
||||
gnome.gnome-calculator
|
||||
keepassxc
|
||||
libnotify
|
||||
|
||||
swaylock
|
||||
swayidle
|
||||
wl-clipboard
|
||||
mako # notification daemon
|
||||
alacritty # Alacritty is the default terminal in the config
|
||||
dmenu # Dmenu is the default in the config but i recommend wofi since its wayland native
|
||||
];
|
||||
};
|
||||
|
||||
@ -96,8 +79,7 @@ in
|
||||
name = "elementary";
|
||||
};
|
||||
theme = {
|
||||
package = pkgs.pantheon.elementary-gtk-theme;
|
||||
name = "elementary";
|
||||
name = "Adwaita-dark";
|
||||
};
|
||||
};
|
||||
|
||||
@ -115,6 +97,8 @@ in
|
||||
mskelton.one-dark-theme
|
||||
ms-kubernetes-tools.vscode-kubernetes-tools
|
||||
ryu1kn.partial-diff
|
||||
jnoortheen.nix-ide
|
||||
brettm12345.nixfmt-vscode
|
||||
];
|
||||
# userSettings = {
|
||||
# #"terminal.integrated.fontFamily" = "Hack";
|
||||
@ -164,6 +148,14 @@ in
|
||||
};
|
||||
};
|
||||
|
||||
git = {
|
||||
extraConfig = {
|
||||
credential.helper = "${
|
||||
pkgs.git.override { withLibsecret = true; }
|
||||
}/bin/git-credential-libsecret";
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
kitty = {
|
||||
enable = true;
|
||||
@ -194,179 +186,5 @@ in
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
services = {
|
||||
# picom = {
|
||||
# enable = true;
|
||||
# blur = true;
|
||||
# shadow = true;
|
||||
# vSync = true;
|
||||
# };
|
||||
|
||||
# dunst = {
|
||||
# enable = true;
|
||||
# settings = {
|
||||
# global = {
|
||||
# font = "SF Pro Display Regular 12";
|
||||
# markup = "yes";
|
||||
# format = "%s %p\n%b";
|
||||
# sort = "yes";
|
||||
# indicate_hidden = "no";
|
||||
# alignment = "center";
|
||||
# bounce_freq = 0;
|
||||
# show_age_threshold = 60;
|
||||
# word_wrap = "yes";
|
||||
# ignore_newline = "no";
|
||||
# geometry = "300x0-5-5";
|
||||
# shrink = "yes";
|
||||
# transparency = 0;
|
||||
# idle_threshold = 120;
|
||||
# monitor = 0;
|
||||
# follow = "mouse";
|
||||
# sticky_history = "yes";
|
||||
# history_length = 20;
|
||||
# show_indicators = "no";
|
||||
# line_height = 0;
|
||||
# separator_height = 1;
|
||||
# stack_duplicates = "no";
|
||||
# padding = 8;
|
||||
# horizontal_padding = 8;
|
||||
# separator_color = "frame";
|
||||
# startup_notification = true;
|
||||
# # dmenu = /usr/bin/dmenu -p dunst;
|
||||
# # browser = /usr/bin/firefox -new-tab;
|
||||
# icon_position = "left";
|
||||
# icon_path = "/usr/share/icons/Arc";
|
||||
# max_icon_size = 64;
|
||||
# };
|
||||
|
||||
# frame = {
|
||||
# width = 1;
|
||||
# color = "#A6A6A6";
|
||||
# };
|
||||
|
||||
# urgency_low = {
|
||||
# background = "#000000";
|
||||
# foreground = "#A6A6A6";
|
||||
# timeout = 4;
|
||||
# };
|
||||
|
||||
# urgency_normal = {
|
||||
# background = "#000000";
|
||||
# foreground = "#A6A6A6";
|
||||
# timeout = 4;
|
||||
# };
|
||||
|
||||
# urgency_critical = {
|
||||
# background = "#900000";
|
||||
# foreground = "#ffffff";
|
||||
# timeout = 16;
|
||||
# };
|
||||
# };
|
||||
# };
|
||||
|
||||
# sxhkd = {
|
||||
# enable = true;
|
||||
# keybindings = {
|
||||
# "super + x" = "notify-send Time $(date '+%H:%M')";
|
||||
# "super + z" = "notify-send Battery $(cat /sys/class/power_supply/BAT0/capacity)%";
|
||||
# "alt + Tab" = "rofi -show window";
|
||||
# "super + Return" = "kitty";
|
||||
# "super + shift + Return" = "rofi -show drun";
|
||||
# "super + Escape" = "pkill -USR1 -x sxhkd";
|
||||
# "super {_,shift + }Tab" = "bspc node -f {next,prev}";
|
||||
# "super + shift + c" = "bspc node -c";
|
||||
# "super + a" = "bspc node @/ --flip vertical";
|
||||
# "super + d" = ''layer=normal; \
|
||||
# bspc query -N -n "focused.$\{layer\}" && layer=below; \
|
||||
# bspc node -l "$layer"'';
|
||||
# "super + {s,f,k}" =
|
||||
# ''state={floating,fullscreen,pseudo_tiled}; \
|
||||
# bspc query -N -n "focused.$\{state\}" && state=tiled; \
|
||||
# bspc node -t "$state" '';
|
||||
# "super + alt + {Left,Down,Up,Right}" = "bspc node -p {west,south,north,east}";
|
||||
# "super + ctrl + {Left,Right,Up,Down}" = "xdo move {-x -50,-x +50,-y -50,-y +50}";
|
||||
# "super + ctrl + alt + {Left,Right,Up,Down}" = "xdo resize {-w -50,-w +50,-h -50,-h +50}";
|
||||
# "super + {_,shift + }{Left,Down,Up,Right}" = "bspc node -{f,s} {west,south,north,east}";
|
||||
# "super + m" = "bspc node -s biggest";
|
||||
# "super + l" = "~/.bin/lock";
|
||||
# "super + ctrl + space" = "bspc node -p cancel";
|
||||
# "super + apostrophe" = "bspc node -s last";
|
||||
# "super + ctrl + comma" = "bspc node @/ --rotate 90";
|
||||
# "super + shift + comma" = "bspc node @/ --circulate forward";
|
||||
# "super + {1-9,0}" = "bspc desktop -f '{I,II,III,IV,V,VI,VII,VIII,IX,X}' && notify-send `bspc query -D -d --names`";
|
||||
# "super + shift + {1-9,0}" = "bspc node -d '{I,II,III,IV,V,VI,VII,VIII,IX,X}'";
|
||||
# # "XF86AudioMute" = "pulseaudio-ctl mute";
|
||||
# # "XF86AudioLowerVolume" = "pulseaudio-ctl down";
|
||||
# # "XF86AudioRaiseVolume" = "pulseaudio-ctl up";
|
||||
# "Print" = "flameshot gui";
|
||||
# };
|
||||
# };
|
||||
|
||||
nextcloud-client = {
|
||||
enable = true;
|
||||
startInBackground = true;
|
||||
};
|
||||
|
||||
redshift = {
|
||||
enable = true;
|
||||
duskTime = "21:00-22:00";
|
||||
dawnTime = "06:30-07:00";
|
||||
};
|
||||
|
||||
flameshot.enable = true;
|
||||
};
|
||||
|
||||
# xsession = {
|
||||
# enable = true;
|
||||
# pointerCursor = {
|
||||
# defaultCursor = "left_ptr";
|
||||
# name = "elementary";
|
||||
# package = pkgs.pantheon.elementary-icon-theme;
|
||||
# };
|
||||
# windowManager = {
|
||||
# command = pkgs.lib.mkForce ''
|
||||
# ${pkgs.bspwm}/bin/bspwm -c ~/.config/bspwm/bspwmrc &
|
||||
# ${pkgs.xfce.xfce4-session}/bin/xfce4-session
|
||||
# '';
|
||||
# bspwm = {
|
||||
# enable = true;
|
||||
# extraConfig = ''
|
||||
# bspc wm --adopt-orphans
|
||||
#
|
||||
# bspc subscribe monitor_add monitor_remove| while read -r a event; do
|
||||
# node /home/alex/Sync/windows.js
|
||||
# done &
|
||||
# '';
|
||||
# settings = {
|
||||
# border_width = 4;
|
||||
# window_gap = 5;
|
||||
# top_padding = 0;
|
||||
# left_padding = 0;
|
||||
# right_padding = 0;
|
||||
# bottom_padding = 0;
|
||||
# split_ratio = 0.50;
|
||||
# borderless_monocle = true;
|
||||
# single_monocle = true;
|
||||
# gapless_monocle = true;
|
||||
# focus_follows_pointer = true;
|
||||
# pointer_follows_monitor = true;
|
||||
# pointer_follows_focus = false;
|
||||
# center_pseudo_tiled = true;
|
||||
# automatic_scheme = "alternate";
|
||||
# remove_unplugged_monitors = true;
|
||||
# remove_disabled_monitors = true;
|
||||
# normal_border_color = "#333333";
|
||||
# focused_border_color = "#666666";
|
||||
# presel_feedback_color = "#000000";
|
||||
# };
|
||||
# };
|
||||
# };
|
||||
# };
|
||||
|
||||
wayland.windowManager.sway = {
|
||||
enable = true;
|
||||
wrapperFeatures.gtk = true ;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
@ -1,4 +1,7 @@
|
||||
{ config, pkgs, lib, ... }:
|
||||
let
|
||||
unstable = import <nixos-unstable> { config.allowUnfree = true; };
|
||||
in
|
||||
{
|
||||
imports = [ <home-manager/nixos> ];
|
||||
|
||||
@ -24,7 +27,7 @@
|
||||
home-manager.users.alex = { pkgs, ... }: {
|
||||
home = {
|
||||
enableNixpkgsReleaseCheck = false;
|
||||
packages = with pkgs; [
|
||||
packages = with unstable.pkgs; [
|
||||
atop
|
||||
bpytop
|
||||
dfc
|
||||
@ -71,6 +74,21 @@
|
||||
}];
|
||||
};
|
||||
|
||||
matchBlocks."new-vps" = {
|
||||
hostname = "207.180.220.97";
|
||||
localForwards = [ {
|
||||
bind.address = "127.0.0.1";
|
||||
bind.port = 8387;
|
||||
host.address = "127.0.0.1";
|
||||
host.port = 8384;
|
||||
} {
|
||||
bind.address = "127.0.0.1";
|
||||
bind.port = 9092;
|
||||
host.address = "127.0.0.1";
|
||||
host.port = 9091;
|
||||
}];
|
||||
};
|
||||
|
||||
matchBlocks."nixos-vm" = {
|
||||
hostname = "192.168.122.222";
|
||||
remoteForwards = [{
|
||||
@ -118,9 +136,6 @@
|
||||
color = { ui = "auto"; };
|
||||
push = { default = "current"; };
|
||||
pull = { rebase = true; };
|
||||
credential.helper = "${
|
||||
pkgs.git.override { withLibsecret = true; }
|
||||
}/bin/git-credential-libsecret";
|
||||
};
|
||||
};
|
||||
|
||||
@ -144,7 +159,7 @@
|
||||
plugins = [
|
||||
{
|
||||
name = "powerlevel10k";
|
||||
src = pkgs.zsh-powerlevel10k;
|
||||
src = unstable.pkgs.zsh-powerlevel10k;
|
||||
file = "share/zsh-powerlevel10k/powerlevel10k.zsh-theme";
|
||||
}
|
||||
{
|
||||
|
@ -2,7 +2,6 @@
|
||||
|
||||
let
|
||||
secrets = import ../configs/secrets.nix;
|
||||
secrets-wireguard = import ../configs/secrets-wireguard-publickeys.nix;
|
||||
secrets-desktop = import ../configs/secrets-desktop.nix;
|
||||
in
|
||||
{
|
||||
@ -16,6 +15,7 @@ in
|
||||
../configs/user-gui-applications.nix
|
||||
../configs/user-gui.nix
|
||||
../configs/user.nix
|
||||
../configs/bspwm.nix
|
||||
];
|
||||
|
||||
# Use the systemd-boot EFI boot loader.
|
||||
@ -42,8 +42,9 @@ in
|
||||
|
||||
initrd.kernelModules = [ "amdgpu" ];
|
||||
plymouth.enable = true;
|
||||
extraModulePackages = with pkgs.linuxPackages; [ it87 ];
|
||||
extraModulePackages = with pkgs.linuxPackages_5_14; [ it87 ];
|
||||
kernelModules = [ "it87" "v4l2loopback" ];
|
||||
kernelPackages = pkgs.linuxPackages_5_14;
|
||||
};
|
||||
|
||||
networking = {
|
||||
@ -52,12 +53,12 @@ in
|
||||
wireguard.interfaces = {
|
||||
wg0 = {
|
||||
ips = [ "10.100.0.2/24" ];
|
||||
privateKey = secrets-desktop.wireguard-desktop-private;
|
||||
privateKey = secrets-desktop.wireguard-private;
|
||||
|
||||
peers = [
|
||||
{
|
||||
publicKey = secrets-wireguard.wireguard-vps-public;
|
||||
presharedKey = secrets-wireguard.wireguard-preshared;
|
||||
publicKey = secrets.wireguard-vps-public;
|
||||
presharedKey = secrets.wireguard-preshared;
|
||||
allowedIPs = [ "10.100.0.0/24" ];
|
||||
endpoint = "szczepan.ski:51820";
|
||||
persistentKeepalive = 25;
|
||||
@ -118,17 +119,20 @@ in
|
||||
services = {
|
||||
printing.enable = true;
|
||||
xserver.videoDrivers = [ "amdgpu" ];
|
||||
xserver.deviceSection = ''
|
||||
Option "TearFree" "true"
|
||||
'';
|
||||
hardware.xow.enable = true;
|
||||
borgbackup.jobs.home = rec {
|
||||
compression = "auto,zstd";
|
||||
encryption = {
|
||||
mode = "repokey-blake2" ;
|
||||
passphrase = secrets-desktop.borg-desktop-key;
|
||||
passphrase = secrets-desktop.borg-key;
|
||||
};
|
||||
extraCreateArgs = "--checkpoint-interval 600 --exclude-caches";
|
||||
environment.BORG_RSH = "ssh -i ~/.ssh/id_borg_rsa";
|
||||
paths = "/home/alex";
|
||||
repo = "ssh://u278697-sub2@u278697.your-storagebox.de:23/./borg";
|
||||
repo = secrets-desktop.borg-repo;
|
||||
startAt = "daily";
|
||||
user = "alex";
|
||||
prune.keep = {
|
||||
|
@ -44,6 +44,10 @@ in
|
||||
# networking.firewall.allowedUDPPorts = [ ... ];
|
||||
# Or disable the firewall altogether.
|
||||
# networking.firewall.enable = false;
|
||||
services.xserver.enable = true;
|
||||
services.xserver.desktopManager.pantheon.enable = true;
|
||||
services.xserver.displayManager.lightdm.greeters.pantheon.enable = true;
|
||||
services.xserver.displayManager.lightdm.enable = true;
|
||||
|
||||
system.stateVersion = "21.05";
|
||||
}
|
||||
|
@ -11,7 +11,6 @@ let
|
||||
export __VK_LAYER_NV_optimus=NVIDIA_only
|
||||
exec -a "$0" "$@"
|
||||
'';
|
||||
secrets = import ../configs/secrets.nix;
|
||||
secrets-thinkpad = import ../configs/secrets-thinkpad.nix;
|
||||
in
|
||||
{
|
||||
@ -39,20 +38,20 @@ in
|
||||
|
||||
fileSystems."/".options = [ "noatime" "discard" ];
|
||||
|
||||
boot.loader.grub.enable = true;
|
||||
boot.loader.grub.version = 2;
|
||||
boot.loader.grub.device = "nodev";
|
||||
boot.loader.grub.efiSupport = true;
|
||||
boot.loader.efi.canTouchEfiVariables = true;
|
||||
boot.loader.grub.gfxmodeEfi = "1024x768";
|
||||
|
||||
# boot.plymouth.enable = true;
|
||||
|
||||
# environment.etc."issue.d/ip.issue".text = "\\4\n";
|
||||
boot = {
|
||||
loader = {
|
||||
grub.enable = true;
|
||||
grub.version = 2;
|
||||
grub.device = "nodev";
|
||||
grub.efiSupport = true;
|
||||
efi.canTouchEfiVariables = true;
|
||||
grub.gfxmodeEfi = "1024x768";
|
||||
};
|
||||
kernelPackages = pkgs.linuxPackages_5_14;
|
||||
boot.plymouth.enable = true;
|
||||
};
|
||||
|
||||
networking.hostName = "thinkpad"; # Define your hostname.
|
||||
|
||||
# Set your time zone.
|
||||
time.timeZone = "Europe/Berlin";
|
||||
|
||||
# The global useDHCP flag is deprecated, therefore explicitly set to false here.
|
||||
@ -131,8 +130,8 @@ in
|
||||
};
|
||||
hardware.sane.enable = true;
|
||||
|
||||
#thinkfan
|
||||
services.thinkfan = {
|
||||
services = {
|
||||
thinkfan = {
|
||||
enable = true;
|
||||
levels = [
|
||||
[0 0 67]
|
||||
@ -144,10 +143,12 @@ in
|
||||
[7 93 32767]
|
||||
];
|
||||
};
|
||||
services = {
|
||||
xserver = {
|
||||
videoDrivers = [ "nvidia" ];
|
||||
# deviceSection = ''BusID "PCI:0:2:0"'';
|
||||
# deviceSection = ''
|
||||
# Option "TearFree" "true"
|
||||
# '';
|
||||
};
|
||||
power-profiles-daemon.enable = false;
|
||||
tlp = {
|
||||
@ -161,12 +162,12 @@ in
|
||||
compression = "auto,zstd";
|
||||
encryption = {
|
||||
mode = "repokey-blake2" ;
|
||||
passphrase = secrets-thinkpad.borg-thinkpad-key;
|
||||
passphrase = secrets-thinkpad.borg-key;
|
||||
};
|
||||
extraCreateArgs = "--list --stats --verbose --checkpoint-interval 600 --exclude-caches";
|
||||
environment.BORG_RSH = "ssh -i ~/.ssh/id_borg_rsa";
|
||||
paths = "/home/alex";
|
||||
repo = "ssh://u278697-sub1@u278697.your-storagebox.de:23/./borg";
|
||||
repo = secrets-thinkpad.borg-thinkpad-key;
|
||||
startAt = "daily";
|
||||
user = "alex";
|
||||
prune.keep = {
|
||||
@ -202,7 +203,7 @@ in
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
nvidia-offload
|
||||
xorg.xf86videointel
|
||||
# xorg.xf86videointel
|
||||
intel-gpu-tools
|
||||
gnome.simple-scan
|
||||
];
|
||||
|
Reference in New Issue
Block a user