Refactor: Moved profiles/*/home to users/kat/... Reorganised

users/kat/...
This commit is contained in:
kat witch 2021-05-06 15:43:59 +01:00
parent 99da1a04e4
commit 82d22bf87b
No known key found for this signature in database
GPG key ID: 1B477797DCA5EC72
82 changed files with 302 additions and 428 deletions

3
.gitignore vendored
View file

@ -1,6 +1,3 @@
/result /result
/result* /result*
/.direnv/ /.direnv/
secrets.nix
!profiles/common/nixos/secrets.nix
!profiles/kat/home/secrets.nix

View file

@ -10,15 +10,18 @@ rec {
defaultFile = "nixos.nix"; defaultFile = "nixos.nix";
}; };
hosts = import ./lib/hosts.nix { users = witch.modList { modulesDir = ./users; };
inherit pkgs sources witch profiles;
inherit (import ./lib/hosts.nix {
inherit pkgs sources witch profiles users;
inherit (deploy) target; inherit (deploy) target;
}; })
hosts targets;
inherit (pkgs) lib; inherit (pkgs) lib;
deploy = import ./lib/deploy.nix { deploy = import ./lib/deploy.nix {
inherit pkgs sources; inherit pkgs sources;
inherit (hosts) hosts targets; inherit hosts targets;
}; };
} }

View file

@ -1,4 +1,4 @@
{ config, lib, pkgs, profiles, ... }: { config, users, lib, pkgs, profiles, ... }:
with lib; with lib;
@ -6,7 +6,7 @@ with lib;
imports = [ imports = [
./hw.nix ./hw.nix
# profiles # profiles
profiles.kat users.kat.server
# host-specific services # host-specific services
./virtualhosts.nix ./virtualhosts.nix
# services # services

View file

@ -1,8 +1,14 @@
{ config, pkgs, profiles, ... }: { config, users, pkgs, profiles, ... }:
{ {
imports = imports = [
[ ./hw.nix profiles.gui profiles.sway profiles.kat profiles.laptop ]; ./hw.nix
profiles.gui
profiles.sway
profiles.laptop
users.kat.sway
users.kat.gui
];
deploy.target = "mbp"; deploy.target = "mbp";

View file

@ -1,7 +1,7 @@
{ config, pkgs, profiles, ... }: { config, users, pkgs, profiles, ... }:
{ {
imports = [ ./hw.nix profiles.kat profiles.laptop ]; imports = [ ./hw.nix profiles.laptop ];
deploy.target = "slow"; deploy.target = "slow";

View file

@ -1,4 +1,4 @@
{ tf, config, pkgs, lib, profiles, sources, ... }: { tf, config, users, pkgs, lib, profiles, sources, ... }:
with lib; with lib;
@ -11,7 +11,7 @@ in {
./hw.nix ./hw.nix
profiles.gui profiles.gui
profiles.sway profiles.sway
profiles.kat users.kat.guiFull
../../../services/zfs.nix ../../../services/zfs.nix
../../../services/restic.nix ../../../services/restic.nix
../../../services/nginx.nix ../../../services/nginx.nix

View file

@ -1,4 +1,4 @@
{ config, pkgs, lib, profiles, ... }: { config, users, pkgs, lib, profiles, ... }:
with lib; with lib;
@ -13,8 +13,8 @@ with lib;
../../../services/nginx.nix ../../../services/nginx.nix
profiles.gui profiles.gui
profiles.sway profiles.sway
profiles.kat
profiles.laptop profiles.laptop
users.kat.guiFull
]; ];
deploy.target = "personal"; deploy.target = "personal";

View file

@ -1,5 +1,5 @@
{ pkgs, target, hostsDir ? ../hosts, profiles, pkgsPath ? ../pkgs, sources ? { } { pkgs, target, users, hostsDir ? ../hosts, profiles, pkgsPath ? ../pkgs
, witch ? { } }: , sources ? { }, witch ? { } }:
with pkgs.lib; with pkgs.lib;
@ -27,7 +27,7 @@ rec {
else else
{ }) { })
]; ];
specialArgs = { inherit sources target profiles witch hostName; }; specialArgs = { inherit sources target profiles witch hostName users; };
})) hostNames); })) hostNames);
targets = foldAttrs (host: hosts: [ host ] ++ hosts) [ ] (mapAttrsToList targets = foldAttrs (host: hosts: [ host ] ++ hosts) [ ] (mapAttrsToList

View file

@ -11,7 +11,6 @@
./private/profile/nixos; ./private/profile/nixos;
options = { options = {
deploy.profile.kat = lib.mkEnableOption "uhh meow";
deploy.profile.gui = lib.mkEnableOption "graphical system"; deploy.profile.gui = lib.mkEnableOption "graphical system";
deploy.profile.sway = lib.mkEnableOption "sway wm"; deploy.profile.sway = lib.mkEnableOption "sway wm";
deploy.profile.laptop = lib.mkEnableOption "lappytop"; deploy.profile.laptop = lib.mkEnableOption "lappytop";
@ -43,7 +42,6 @@
(import (./private/hosts + "/${hostName}/home")); (import (./private/hosts + "/${hostName}/home"));
options = { options = {
deploy.profile.kat = lib.mkEnableOption "uhh meow";
deploy.profile.gui = lib.mkEnableOption "graphical system"; deploy.profile.gui = lib.mkEnableOption "graphical system";
deploy.profile.sway = lib.mkEnableOption "sway wm"; deploy.profile.sway = lib.mkEnableOption "sway wm";
deploy.profile.laptop = lib.mkEnableOption "lappytop"; deploy.profile.laptop = lib.mkEnableOption "lappytop";

View file

@ -1,3 +0,0 @@
{ ... }:
{ }

View file

@ -1,7 +1,5 @@
{ config, lib, pkgs, ... }: { config, lib, pkgs, ... }:
{ {
imports = [ ./nixos ../../users ]; imports = [ ./nixos ];
config = { home-manager.users.kat = { imports = [ ./home.nix ]; }; };
} }

View file

@ -1,7 +1,9 @@
{ config, lib, pkgs, ... }: { config, users, lib, pkgs, ... }:
{ {
imports = [ imports = [
users.kat.base
users.arc
./system.nix ./system.nix
./net.nix ./net.nix
./access.nix ./access.nix

View file

@ -5,27 +5,9 @@
smartmontools smartmontools
hddtemp hddtemp
lm_sensors lm_sensors
htop
cachix cachix
borgbackup
ripgrep
git
nixfmt
wget
rsync
pv
pinentry-curses pinentry-curses
kitty.terminfo kitty.terminfo
progress
bc
bat
zstd
file
whois
fd
exa
socat
tmux
gnupg gnupg
]; ];
} }

View file

@ -1,7 +0,0 @@
{ lib, ... }:
{
imports = [ ./home ];
deploy.profile.gui = true;
}

View file

@ -1,17 +0,0 @@
{ ... }:
{
imports = [
./firefox
./kitty.nix
./packages.nix
./gpg.nix
./bitw.nix
./weechat.nix
./gtk.nix
./music.nix
./mpv.nix
./syncplay.nix
./obs.nix
];
}

View file

@ -1,58 +0,0 @@
{ config, lib, pkgs, ... }:
{
home.packages = with pkgs; [
_1password
bitwarden
wire-desktop
element-desktop
wf-recorder
mumble-speechd
niv
feh
rink
sd
kat-scrot
duc
exiftool
audacity
avidemux
gst_all_1.gstreamer.dev
gst_all_1.gstreamer
gst_all_1.gst-plugins-base
gst_all_1.gst-plugins-good
gst_all_1.gst-plugins-bad
gst_all_1.gst-plugins-ugly
vlc
ffmpeg-full
thunderbird
youtube-dl
mkchromecast
google-chrome
v4l-utils
transmission-remote-gtk
lm_sensors
p7zip
baresip
psmisc
discord
tdesktop
yubikey-manager
pinentry.gtk2
dino
libnotify
nextcloud-client
vegur
nitrogen
terminator
pavucontrol
gparted
scrot
gimp-with-plugins
vscode
cryptsetup
vifm
neofetch
htop
];
}

View file

@ -3,7 +3,5 @@
{ {
imports = [ ./nixos ]; imports = [ ./nixos ];
home-manager.users.kat = { imports = [ ./home.nix ]; };
deploy.profile.gui = true; deploy.profile.gui = true;
} }

View file

@ -8,21 +8,7 @@
''; '';
}; };
/* hardware.pulseaudio = { environment.systemPackages = with pkgs; [ pavucontrol ];
enable = true;
extraConfig = "unload-module module-role-cork";
daemon.config = {
exit-idle-time = 5;
resample-method = "speex-float-5";
avoid-resampling = "true";
flat-volumes = "no";
default-sample-format = "s32le";
default-sample-rate = 48000;
alternate-sample-rate = 44100;
default-sample-channels = 2;
};
};
*/
security.rtkit.enable = true; security.rtkit.enable = true;

View file

@ -1,7 +0,0 @@
{ lib, ... }:
{
imports = [ ./home ];
deploy.profile.kat = true;
}

View file

@ -1,5 +0,0 @@
{ config, lib, pkgs, ... }:
{
home.packages = with pkgs; [ hyperfine hexyl tokei ];
}

View file

@ -1,142 +0,0 @@
function term_title {
emulate -L zsh
unsetopt prompt_subst
[[ -t 1 ]] || return
local TITLE="$1"
local TAB="${2-$1}"
case "$TERM" in
cygwin|xterm*|putty*|rxvt*|ansi)
print -Pn "\e]2;$TITLE:q\a"
print -Pn "\e]1;$TAB:q\a"
;;
screen*)
print -Pn "\ek$TITLE:q\e\\"
;;
*)
if [[ "$TERM_PROGRAM" == "iTerm.app" ]]; then
print -Pn "\e]2;$TITLE:q\a"
print -Pn "\e]1;$TAB:q\a"
else
if [[ -n "$terminfo[fsl]" ]] && [[ -n "$terminfo[tsl]" ]]; then
echoti tsl
print -Pn "$TITLE"
echoti fsl
fi
fi
;;
esac
}
function term_dir {
emulate -L zsh
[[ -t 1 ]] || return
local DIR="${1-$PWD}"
if [[ "${TERM_PROGRAM-}" == "Apple_Terminal" ]]; then
local URL_PATH="$(__omz_urlencode -P "$DIR")"
[[ $? != 0 ]] && return 1
printf '\e]7;%s\a' "file://$HOST$URL_PATH"
fi
}
function __arc_update_precmd {
local TERM_TITLE="%~"
local TERM_TAB="%~"
if [[ "${TERM_PROGRAM-}" == "Apple_Terminal" ]]; then
TERM_TAB="$USER@%m"
TERM_TITLE="$TERM_TAB"
elif [[ "$USER" != "$DEFAULT_USER" || -n "${SSH_CLIENT-}" ]]; then
TERM_TAB="$USER@%m"
TERM_TITLE="$TERM_TAB - $TERM_TITLE"
fi
term_title "$TERM_TITLE" "$TERM_TAB"
}
function __arc_update_preexec {
emulate -L zsh
setopt extended_glob
local TERM_TAB=${1[(wr)^(*=*|sudo|ssh|mosh|rake|-*)]:gs/%/%%}
local TERM_TITLE="${2:gs/%/%%}"
if [[ "$USER" != "$DEFAULT_USER" || -n "${SSH_CLIENT-}" ]]; then
TERM_TAB="$USER@%m - $TERM_TAB"
TERM_TITLE="$USER@%m - $TERM_TITLE"
fi
term_title "$TERM_TITLE" "$TERM_TAB"
}
zmodload zsh/langinfo
function __omz_urlencode() {
emulate -L zsh
zparseopts -D -E -a opts r m P
local in_str=$1
local url_str=""
local spaces_as_plus
if [[ -z $opts[(r)-P] ]]; then spaces_as_plus=1; fi
local str="$in_str"
# URLs must use UTF-8 encoding; convert str to UTF-8 if required
local encoding=$langinfo[CODESET]
local safe_encodings
safe_encodings=(UTF-8 utf8 US-ASCII)
if [[ -z ${safe_encodings[(r)$encoding]} ]]; then
str=$(echo -E "$str" | iconv -f $encoding -t UTF-8)
if [[ $? != 0 ]]; then
echo "Error converting string from $encoding to UTF-8" >&2
return 1
fi
fi
# Use LC_CTYPE=C to process text byte-by-byte
local i byte ord LC_ALL=C
export LC_ALL
local reserved=';/?:@&=+$,'
local mark='_.!~*''()-'
local dont_escape="[A-Za-z0-9"
if [[ -z $opts[(r)-r] ]]; then
dont_escape+=$reserved
fi
# $mark must be last because of the "-"
if [[ -z $opts[(r)-m] ]]; then
dont_escape+=$mark
fi
dont_escape+="]"
# Implemented to use a single printf call and avoid subshells in the loop,
# for performance (primarily on Windows).
local url_str=""
for (( i = 1; i <= ${#str}; ++i )); do
byte="$str[i]"
if [[ "$byte" =~ "$dont_escape" ]]; then
url_str+="$byte"
else
if [[ "$byte" == " " && -n $spaces_as_plus ]]; then
url_str+="+"
else
ord=$(( [##16] #byte ))
url_str+="%$ord"
fi
fi
done
echo -E "$url_str"
}
if [[ -z "${ARC_PROMPT_RUN-}" ]]; then
chpwd_functions+=(term_dir)
precmd_functions+=(__arc_update_precmd)
preexec_functions+=(__arc_update_preexec)
term_dir
fi

View file

@ -1,5 +0,0 @@
{ lib, ... }:
{
deploy.profile.laptop = true;
}

View file

@ -1,7 +0,0 @@
{ lib, ... }:
{
imports = [ ./home ];
deploy.profile.sway = true;
}

View file

@ -1,8 +0,0 @@
{ config, ... }:
{
services.konawall = {
enable = true;
interval = "20m";
};
}

View file

@ -1,36 +0,0 @@
{ config, pkgs, lib, ... }:
{
systemd.user.services.swayidle = {
Unit = {
Description = "swayidle";
Documentation = [ "man:swayidle(1)" ];
PartOf = [ "graphical-session.target" ];
};
Service = {
Type = "simple";
ExecStart = ''
${pkgs.swayidle}/bin/swayidle -w \
timeout 300 '${pkgs.swaylock}/bin/swaylock -f -i LVDS-1:${
../../../private/files/wallpapers/main.png
} -i eDP-1:${
../../../private/files/wallpapers/main.png
} -i HDMI-A-1:${../../../private/files/wallpapers/main.png} -i DP-1:${
../../../private/files/wallpapers/left.jpg
} -i DVI-D-1:${../../../private/files/wallpapers/right.jpg}' \
#timeout 600 'swaymsg "output * dpms off"' \
# resume 'swaymsg "output * dpms on"' \
before-sleep '${pkgs.swaylock}/bin/swaylock -f -i LVDS-1:${
../../../private/files/wallpapers/main.png
} -p eDP-1:${
../../../private/files/wallpapers/main.png
} -i HDMI-A-1:${../../../private/files/wallpapers/main.png} -i DP-1:${
../../../private/files/wallpapers/left.jpg
} -i DVI-D-1:${../../../private/files/wallpapers/right.jpg}'
'';
RestartSec = 3;
Restart = "always";
};
Install = { WantedBy = [ "sway-session.target" ]; };
};
}

View file

@ -3,7 +3,5 @@
{ {
imports = [ ./nixos ]; imports = [ ./nixos ];
home-manager.users.kat = { imports = [ ./home.nix ]; };
deploy.profile.sway = true; deploy.profile.sway = true;
} }

View file

@ -1,5 +0,0 @@
{ ... }:
{
imports = [ ./arc ];
}

11
users/kat/default.nix Normal file
View file

@ -0,0 +1,11 @@
rec {
base = ./nixos/base.nix;
gui = ./nixos/gui.nix;
sway = ./nixos/sway.nix;
dev = ./nixos/dev.nix;
media = ./nixos/media.nix;
personal = ./nixos/personal.nix;
server = { imports = [ personal ]; };
guiFull = { imports = [ gui sway dev media personal ]; };
}

View file

@ -2,12 +2,11 @@
{ {
imports = [ imports = [
./zsh
./vim ./vim
./zsh.nix
./git.nix ./git.nix
./kitty.nix ./kitty.nix
./tmux.nix ./tmux.nix
./secrets.nix
./base16.nix ./base16.nix
./xdg.nix ./xdg.nix
./ssh.nix ./ssh.nix

View file

@ -0,0 +1,28 @@
{ config, lib, pkgs, ... }:
{
home.packages = with pkgs; [
htop
fd
sd
duc
bat
exa
fd
socat
rsync
wget
ripgrep
nixfmt
pv
progress
zstd
file
whois
niv
dnsutils
rink
borgbackup
neofetch
];
}

View file

@ -15,6 +15,7 @@
lla = "exa -lga"; lla = "exa -lga";
}; };
initExtra = '' initExtra = ''
genmac() { nix run nixpkgs.openssl -c openssl rand -hex 6 | sed 's/\(..\)\(..\)\(..\)\(..\)\(..\)\(..\)/\1:\2:\3:\4:\5:\6/' }
nano() { echo "baps you for being naughty, use vim" } nano() { echo "baps you for being naughty, use vim" }
''; '';
localVariables = { localVariables = {

View file

@ -0,0 +1,5 @@
rec {
base = ./base;
sway = ./sway;
gui = ./gui;
}

View file

@ -0,0 +1,5 @@
{ config, lib, pkgs, ... }:
{
imports = [ ./packages.nix ];
}

View file

@ -0,0 +1,5 @@
{ config, pkgs, ... }:
{
home.packages = with pkgs; [ hyperfine hexyl tokei horizon-eda ];
}

View file

@ -0,0 +1,7 @@
{ ... }:
{
deploy.profile.gui = true;
imports = [ ./firefox ./kitty.nix ./packages.nix ./weechat.nix ./gtk.nix ];
}

View file

@ -0,0 +1,25 @@
{ config, lib, pkgs, ... }:
{
home.packages = with pkgs; [
_1password
bitwarden
wire-desktop
element-desktop
exiftool
thunderbird
google-chrome
transmission-remote-gtk
lm_sensors
p7zip
zip
unzip
baresip
discord
tdesktop
yubikey-manager
vegur
gparted
cryptsetup
];
}

View file

@ -3,7 +3,7 @@
{ {
home.file = { home.file = {
".local/share/weechat/sec.conf" = lib.mkIf config.deploy.profile.private { ".local/share/weechat/sec.conf" = lib.mkIf config.deploy.profile.private {
source = ../../../private/files/weechat/sec.conf; source = ../../../../private/files/weechat/sec.conf;
}; };
}; };
programs.weechat = { programs.weechat = {

View file

@ -0,0 +1,18 @@
{ config, pkgs, lib, ... }:
{
programs.beets = {
enable = true;
package = pkgs.beets;
settings = {
directory = "~/media-share/music";
library = "~/.local/share/beets.db";
plugins = lib.concatStringsSep " " [
"mpdstats"
"mpdupdate"
"duplicates"
"chroma"
];
};
};
}

View file

@ -0,0 +1,13 @@
{ ... }:
{
imports = [
./mpv.nix
./obs.nix
./syncplay.nix
./beets.nix
./mpd.nix
./ncmpcpp.nix
./packages.nix
];
}

View file

@ -0,0 +1,38 @@
{ config, pkgs, ... }:
{
services.mpd = {
enable = true;
package = pkgs.mpd-youtube-dl;
network.startWhenNeeded = true;
musicDirectory = "/home/kat/media-share/music";
extraConfig = ''
max_output_buffer_size "32768"
audio_output {
type "fifo"
name "my_fifo"
path "/tmp/mpd.fifo"
format "44100:16:2"
}
audio_output {
type "pulse"
name "speaker"
}
audio_output {
type "httpd"
name "httpd-high"
encoder "opus"
bitrate "96000"
port "32101"
max_clients "4"
format "48000:16:2"
always_on "yes"
tags "yes"
}
'';
};
}

View file

@ -1,4 +1,4 @@
{ config, lib, pkgs, ... }: { config, ... }:
{ {
programs.ncmpcpp = { programs.ncmpcpp = {
@ -49,52 +49,4 @@
} }
]; ];
}; };
programs.beets = {
enable = true;
package = pkgs.beets;
settings = {
directory = "~/media-share/music";
library = "~/.local/share/beets.db";
plugins = lib.concatStringsSep " " [
"mpdstats"
"mpdupdate"
"duplicates"
"chroma"
];
};
};
services.mpd = {
enable = true;
package = pkgs.mpd-youtube-dl;
network.startWhenNeeded = true;
musicDirectory = "/home/kat/media-share/music";
extraConfig = ''
max_output_buffer_size "32768"
audio_output {
type "fifo"
name "my_fifo"
path "/tmp/mpd.fifo"
format "44100:16:2"
}
audio_output {
type "pulse"
name "speaker"
}
audio_output {
type "httpd"
name "httpd-high"
encoder "opus"
bitrate "96000"
port "32101"
max_clients "4"
format "48000:16:2"
always_on "yes"
tags "yes"
}
'';
};
} }

View file

@ -0,0 +1,21 @@
{ config, pkgs, ... }:
{
home.packages = with pkgs; [
audacity
avidemux
gst_all_1.gstreamer.dev
gst_all_1.gstreamer
gst_all_1.gst-plugins-base
gst_all_1.gst-plugins-good
gst_all_1.gst-plugins-bad
gst_all_1.gst-plugins-ugly
vlc
ffmpeg-full
youtube-dl
mkchromecast
v4l-utils
gimp-with-plugins
wf-recorder
];
}

View file

@ -0,0 +1,5 @@
{ ... }:
{
imports = [ ./secrets.nix ./bitw.nix ./gpg.nix ./packages.nix ];
}

View file

@ -0,0 +1,5 @@
{ config, pkgs, ... }:
{
home.packages = with pkgs; [ pinentry.gtk2 ];
}

View file

@ -1,6 +1,8 @@
{ config, pkgs, ... }: { config, pkgs, ... }:
{ {
deploy.profile.sway = true;
imports = [ imports = [
./waybar ./waybar
./mako.nix ./mako.nix
@ -8,5 +10,6 @@
./swayidle.nix ./swayidle.nix
./gammastep.nix ./gammastep.nix
./konawall.nix ./konawall.nix
./packages.nix
]; ];
} }

View file

@ -0,0 +1,5 @@
{ config, ... }:
{
services.konawall = { enable = true; };
}

View file

@ -0,0 +1,5 @@
{ config, pkgs, ... }:
{
home.packages = with pkgs; [ kat-scrot ];
}

View file

@ -77,13 +77,11 @@ in {
config = let config = let
dmenu = dmenu =
"${pkgs.bemenu}/bin/bemenu --fn '${witch.style.font.name} ${witch.style.font.size}' --nb '${witch.style.base16.base00}' --nf '${witch.style.base16.base07}' --sb '${witch.style.base16.base01}' --sf '${witch.style.base16.base07}' -l 5 -m -1 -i"; "${pkgs.bemenu}/bin/bemenu --fn '${witch.style.font.name} ${witch.style.font.size}' --nb '${witch.style.base16.base00}' --nf '${witch.style.base16.base07}' --sb '${witch.style.base16.base01}' --sf '${witch.style.base16.base07}' -l 5 -m -1 -i";
lockCommand = "swaylock -i LVDS-1:${ lockCommand = "swaylock -i LVDS-1:${./wallpapers/main.png}-i eDP-1:${
../../../private/files/wallpapers/main.png ./wallpapers/main.png
}-i eDP-1:${../../../private/files/wallpapers/main.png} -i HDMI-A-1:${ } -i HDMI-A-1:${./wallpapers/main.png} -i DP-1:${
../../../private/files/wallpapers/main.png ./wallpapers/left.jpg
} -i DP-1:${../../../private/files/wallpapers/left.jpg} -i DVI-D-1:${ } -i DVI-D-1:${./wallpapers/right.jpg} -s fill";
../../../private/files/wallpapers/right.jpg
} -s fill";
in { in {
bars = [{ command = "${pkgs.waybar}/bin/waybar"; }]; bars = [{ command = "${pkgs.waybar}/bin/waybar"; }];

View file

@ -0,0 +1,36 @@
{ config, pkgs, lib, ... }:
{
systemd.user.services.swayidle = {
Unit = {
Description = "swayidle";
Documentation = [ "man:swayidle(1)" ];
PartOf = [ "graphical-session.target" ];
};
Service = {
Type = "simple";
ExecStart = ''
${pkgs.swayidle}/bin/swayidle -w \
timeout 300 '${pkgs.swaylock}/bin/swaylock -f -i LVDS-1:${
./wallpapers/main.png
} -i eDP-1:${./wallpapers/main.png} -i HDMI-A-1:${
./wallpapers/main.png
} -i DP-1:${./wallpapers/left.jpg} -i DVI-D-1:${
./wallpapers/right.jpg
}' \
timeout 600 'swaymsg "output * dpms off"' \
resume 'swaymsg "output * dpms on"' \
before-sleep '${pkgs.swaylock}/bin/swaylock -f -i LVDS-1:${
./wallpapers/main.png
} -p eDP-1:${./wallpapers/main.png} -i HDMI-A-1:${
./wallpapers/main.png
} -i DP-1:${./wallpapers/left.jpg} -i DVI-D-1:${
./wallpapers/right.jpg
}'
'';
RestartSec = 3;
Restart = "always";
};
Install = { WantedBy = [ "sway-session.target" ]; };
};
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 451 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.2 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 MiB

View file

@ -1,11 +1,7 @@
{ config, pkgs, lib, ... }: { config, pkgs, lib, ... }:
{ {
home-manager.users.kat = { imports = [ ./home.nix ]; }; home-manager.users.kat = { imports = [ ../home/base ]; };
deploy.profile.kat = true;
users.groups = { uinput = { }; };
users.users.kat = { users.users.kat = {
uid = 1000; uid = 1000;

5
users/kat/nixos/dev.nix Normal file
View file

@ -0,0 +1,5 @@
{ ... }:
{
home-manager.users.kat = { imports = [ ../home/dev ]; };
}

5
users/kat/nixos/gui.nix Normal file
View file

@ -0,0 +1,5 @@
{ ... }:
{
home-manager.users.kat = { imports = [ ../home/gui ]; };
}

View file

@ -0,0 +1,5 @@
{ ... }:
{
home-manager.users.kat = { imports = [ ../home/media ]; };
}

View file

@ -0,0 +1,5 @@
{ ... }:
{
home-manager.users.kat = { imports = [ ../home/personal ]; };
}

5
users/kat/nixos/sway.nix Normal file
View file

@ -0,0 +1,5 @@
{ ... }:
{
home-manager.users.kat = { imports = [ ../home/sway ]; };
}