feat: removed user1 and tidied up user0 home
|
|
@ -96,7 +96,6 @@
|
|||
mars = inputs.self.lib.mkLinuxSystem [
|
||||
./systems/mars
|
||||
./profiles/user0
|
||||
./profiles/user1
|
||||
config.nixosModules.mars
|
||||
config.nixosModules.core
|
||||
config.nixosModules.mantle
|
||||
|
|
@ -104,7 +103,7 @@
|
|||
inputs.nixos-cosmic.nixosModules.default
|
||||
inputs.home-manager.nixosModules.home-manager
|
||||
inputs.lix-module.nixosModules.default
|
||||
inputs.niri.nixosModules.niri
|
||||
# inputs.niri.nixosModules.niri
|
||||
inputs.nur.modules.nixos.default
|
||||
inputs.sops-nix.nixosModules.sops
|
||||
];
|
||||
|
|
|
|||
|
|
@ -225,9 +225,6 @@ in
|
|||
userIdForUser0 = [
|
||||
"uid=1000"
|
||||
];
|
||||
userIdForUser1 = [
|
||||
"uid=1002"
|
||||
];
|
||||
dummy = [
|
||||
];
|
||||
|
||||
|
|
@ -294,8 +291,6 @@ in
|
|||
usersFunctions = {
|
||||
user0 = "nick";
|
||||
user0Label = "Nick";
|
||||
user1 = "streaming";
|
||||
user1Label = "Streaming";
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -3,11 +3,10 @@ let
|
|||
inherit (moduleFunctions.devicesFunctions)
|
||||
sambaPermissions
|
||||
userIdForUser0
|
||||
userIdForUser1
|
||||
synologyIP
|
||||
deviceNames
|
||||
;
|
||||
inherit (moduleFunctions.usersFunctions) user0 user0Label user1;
|
||||
inherit (moduleFunctions.usersFunctions) user0 user0Label;
|
||||
synologyName = deviceNames.nas;
|
||||
in
|
||||
{
|
||||
|
|
@ -25,10 +24,4 @@ in
|
|||
device = "//${synologyIP}/homes/${user0Label}";
|
||||
options = sambaPermissions ++ userIdForUser0;
|
||||
};
|
||||
# Streaming Folder
|
||||
folder1 = {
|
||||
mount = "/mnt/media/${synologyName}/${user1}";
|
||||
device = "//${synologyIP}/homes/${user0Label}";
|
||||
options = sambaPermissions ++ userIdForUser1;
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@
|
|||
address2 = "nick@uprootnutrition.com";
|
||||
};
|
||||
paths = {
|
||||
path0 = "/home/${user0}/Files/Projects"; # Git path
|
||||
path0 = "/home/${user0}/projects"; # Git path
|
||||
};
|
||||
sshKeys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIBF9TmImDoYDpsW5VMFbOcuK3aH4TWRtx/xGxT3yUtEN nick@desktop"
|
||||
|
|
|
|||
|
|
@ -1,15 +0,0 @@
|
|||
{ user1 }:
|
||||
{
|
||||
name = "Streaming";
|
||||
aliases = {
|
||||
};
|
||||
email = {
|
||||
address0 = "nick@upRootNutrition.com";
|
||||
};
|
||||
paths = {
|
||||
path0 = "/home/${user1}/Files/Projects"; # Git path
|
||||
};
|
||||
sshKeys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIBF9TmImDoYDpsW5VMFbOcuK3aH4TWRtx/xGxT3yUtEN nick@desktop"
|
||||
];
|
||||
}
|
||||
|
|
@ -3,15 +3,12 @@ let
|
|||
inherit (moduleFunctions) usersFunctions;
|
||||
configPath = ./config;
|
||||
user0 = usersFunctions.user0;
|
||||
user1 = usersFunctions.user1;
|
||||
in
|
||||
{
|
||||
inherit
|
||||
user0
|
||||
user1
|
||||
;
|
||||
users = {
|
||||
"${user0}" = import (configPath + /user0.nix) { inherit user0; };
|
||||
"${user1}" = import (configPath + /user1.nix) { inherit user1; };
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -19,8 +19,6 @@
|
|||
|
||||
keys = {
|
||||
normal = {
|
||||
C-y = ":sh zellij run -n Yazi -c -f -x 10%% -y 10%% --width 80%% --height 80%% -- yazi-picker open .";
|
||||
C-v = ":sh zellij run -n Lazygit -c -f -x 10%% -y 10%% --width 80%% --height 80%% -- lazygit-root";
|
||||
f = ":format";
|
||||
tab = "indent";
|
||||
S-tab = "unindent";
|
||||
|
|
|
|||
|
|
@ -14,7 +14,6 @@ in
|
|||
;
|
||||
inherit (config.people)
|
||||
user0
|
||||
user1
|
||||
;
|
||||
in
|
||||
{
|
||||
|
|
@ -63,7 +62,7 @@ in
|
|||
zoom
|
||||
academic
|
||||
hypr
|
||||
niri
|
||||
# niri
|
||||
wayland
|
||||
theming
|
||||
printManager
|
||||
|
|
@ -76,32 +75,6 @@ in
|
|||
;
|
||||
};
|
||||
};
|
||||
"${mars.name}-${user1}" = {
|
||||
imports = builtins.attrValues {
|
||||
inherit (modules)
|
||||
cli
|
||||
floorp
|
||||
ghostty
|
||||
steam
|
||||
zed
|
||||
obsidian
|
||||
okular
|
||||
kolourPaint
|
||||
imageViewing
|
||||
obsStudio
|
||||
mpv
|
||||
freetube
|
||||
vesktop
|
||||
bitwarden
|
||||
emote
|
||||
flameshot
|
||||
gnomeCalculator
|
||||
theming
|
||||
hypr
|
||||
wayland
|
||||
;
|
||||
};
|
||||
};
|
||||
"${deimos.name}-${user0}" = {
|
||||
imports = builtins.attrValues {
|
||||
inherit (modules)
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@ in
|
|||
vaults = {
|
||||
"obsidian" = {
|
||||
enable = true;
|
||||
target = "/home/${user0}/Files/Projects/dotfiles/modules/home/gui/apps/media/docs/docEditing/obsidian/vault0/files";
|
||||
target = "/home/${user0}/projects/dotfiles/modules/home/gui/apps/media/docs/docEditing/obsidian/vault0/files";
|
||||
settings = vault0Settings;
|
||||
};
|
||||
};
|
||||
|
|
|
|||
|
|
@ -2,7 +2,6 @@
|
|||
let
|
||||
inherit (flake.config.people)
|
||||
user0
|
||||
user1
|
||||
;
|
||||
in
|
||||
{
|
||||
|
|
@ -15,7 +14,6 @@ in
|
|||
noPass = true;
|
||||
users = [
|
||||
user0
|
||||
user1
|
||||
];
|
||||
}
|
||||
];
|
||||
|
|
|
|||
|
|
@ -1,37 +1,11 @@
|
|||
{ pkgs, ... }:
|
||||
{ pkgs, flake, ... }:
|
||||
let
|
||||
inherit (flake.config.people) user0;
|
||||
in
|
||||
{
|
||||
environment = {
|
||||
enableAllTerminfo = true;
|
||||
systemPackages =
|
||||
let
|
||||
yazi-picker = pkgs.writeShellScriptBin "yazi-picker" ''
|
||||
#!/usr/bin/env bash
|
||||
|
||||
paths=$(yazi "$2" --chooser-file=/dev/stdout | while read -r; do printf "%q " "$REPLY"; done)
|
||||
|
||||
if [[ -n "$paths" ]]; then
|
||||
zellij action toggle-floating-panes
|
||||
zellij action write 27 # send <Escape> key
|
||||
zellij action write-chars ":$1 $paths"
|
||||
zellij action write 13 # send <Enter> key
|
||||
else
|
||||
zellij action toggle-floating-panes
|
||||
fi
|
||||
'';
|
||||
lazygit-root = pkgs.writeShellScriptBin "lazygit-root" ''
|
||||
#!/usr/bin/env bash
|
||||
|
||||
git_root=$(git rev-parse --show-toplevel 2>/dev/null)
|
||||
|
||||
if [[ -z "$git_root" ]]; then
|
||||
echo "Not in a git repository"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
cd "$git_root" && lazygit
|
||||
'';
|
||||
in
|
||||
builtins.attrValues {
|
||||
systemPackages = builtins.attrValues {
|
||||
inherit (pkgs)
|
||||
git
|
||||
grim
|
||||
|
|
@ -42,13 +16,12 @@
|
|||
virt-manager
|
||||
imagemagick
|
||||
;
|
||||
# Add your custom scripts to the attribute set
|
||||
inherit yazi-picker lazygit-root;
|
||||
};
|
||||
variables = {
|
||||
VIDEO_PLAYER = "mpv";
|
||||
EDITOR = "hx";
|
||||
TERM = "ghostty";
|
||||
XDG_DOWNLOAD_DIR = "/home/${user0}/downloads";
|
||||
NIXPKGS_ALLOW_INSECURE = "1";
|
||||
NIXPKGS_ALLOW_UNFREE = "1";
|
||||
GTK_THEME = "catppuccin-macchiato-mauve-compact";
|
||||
|
|
|
|||
|
|
@ -9,6 +9,6 @@ in
|
|||
enable = true;
|
||||
dates = "weekly";
|
||||
};
|
||||
flake = "/home/${user0}/Files/Projects/dotfiles";
|
||||
flake = "/home/${user0}/projects/dotfiles";
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4,38 +4,12 @@
|
|||
...
|
||||
}:
|
||||
let
|
||||
inherit (flake.config.people) user0 user1;
|
||||
inherit (flake.config.machines) devices;
|
||||
hostname = config.networking.hostName;
|
||||
mars = devices.mars.name;
|
||||
deimos = devices.deimos.name;
|
||||
ceres = devices.ceres.name;
|
||||
|
||||
getUserKeys = user: flake.config.people.users.${user}.sshKeys;
|
||||
|
||||
user0Key = {
|
||||
${user0} = {
|
||||
openssh.authorizedKeys.keys = getUserKeys user0;
|
||||
};
|
||||
};
|
||||
user1Key = {
|
||||
${user1} = {
|
||||
openssh.authorizedKeys.keys = getUserKeys user1;
|
||||
};
|
||||
};
|
||||
|
||||
inherit (flake.config.people) user0;
|
||||
in
|
||||
{
|
||||
users.users =
|
||||
if hostname == mars then
|
||||
user0Key // user1Key
|
||||
else if
|
||||
builtins.elem hostname [
|
||||
deimos
|
||||
ceres
|
||||
]
|
||||
then
|
||||
user0Key
|
||||
else
|
||||
{ };
|
||||
users.users = {
|
||||
${user0} = {
|
||||
openssh.authorizedKeys.keys = flake.config.people.users.${user0}.sshKeys;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,11 +9,11 @@ in
|
|||
inherit (modules)
|
||||
syncthing
|
||||
ollama
|
||||
cosmic
|
||||
# cosmic
|
||||
# plasma
|
||||
# hypr
|
||||
hypr
|
||||
# niri
|
||||
# wayland
|
||||
wayland
|
||||
network
|
||||
searx
|
||||
flatpak
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ let
|
|||
inherit (flake.config.machines.devices) ceres;
|
||||
in
|
||||
{
|
||||
assets-path = "/home/${user0}/Files/Projects/dotfiles/modules/nixos/services/glance/assets";
|
||||
assets-path = "/home/${user0}/projects/dotfiles/modules/nixos/services/glance/assets";
|
||||
# host = configHelpers.host;
|
||||
# host = configHelpers.localhost;
|
||||
host = ceres.wireguard.ip0;
|
||||
|
|
|
|||
|
|
@ -52,11 +52,11 @@ in
|
|||
homeDirectory = "/home/${user0}";
|
||||
file = {
|
||||
"./justfile" = import ./files/misc/justfile.nix { inherit flake config lib; };
|
||||
"./Files/Scripts/list.sh" = {
|
||||
"./.config/scripts/list.sh" = {
|
||||
source = ./files/scripts/list.sh;
|
||||
executable = true;
|
||||
};
|
||||
"./Files/Scripts/loop.sh" = {
|
||||
"./.config/scripts/loop.sh" = {
|
||||
source = ./files/scripts/loop.sh;
|
||||
executable = true;
|
||||
};
|
||||
|
|
@ -97,22 +97,13 @@ in
|
|||
"d ${paths.path0} 0755 ${user0} users -"
|
||||
]
|
||||
++ (map (path: "d /home/${user0}/${path} 0755 ${user0} users -") [
|
||||
"Downloads/Nicotine"
|
||||
"Downloads/Nicotine/Downloads"
|
||||
"Downloads/Nicotine/Incomplete"
|
||||
"Downloads/Nicotine/Received"
|
||||
"Downloads/Qbittorent"
|
||||
"Downloads/Qbittorent/Movies"
|
||||
"Downloads/Qbittorent/Music"
|
||||
"Downloads/Qbittorent/Shows"
|
||||
"Files"
|
||||
"Files/Scripts"
|
||||
"Files/Games"
|
||||
"Files/Screenshots"
|
||||
"projects"
|
||||
"downloads"
|
||||
])
|
||||
++ (map (path: "R /home/${user0}/${path} 0755 ${user0} users - -") [
|
||||
"Desktop"
|
||||
"Documents"
|
||||
"Downloads"
|
||||
"Music"
|
||||
"Pictures"
|
||||
"Public"
|
||||
|
|
|
|||
|
|
@ -33,16 +33,16 @@ in
|
|||
{
|
||||
text = ''
|
||||
rebuildBoot:
|
||||
nixos-rebuild boot --sudo --flake ~/Files/Projects/dotfiles#${hostname} --show-trace
|
||||
nixos-rebuild boot --sudo --flake ~/projects/dotfiles#${hostname} --show-trace
|
||||
|
||||
rebuild:
|
||||
nixos-rebuild switch --sudo --flake ~/Files/Projects/dotfiles#${hostname} --show-trace
|
||||
nixos-rebuild switch --sudo --flake ~/projects/dotfiles#${hostname} --show-trace
|
||||
|
||||
rebuild-server:
|
||||
nixos-rebuild switch --flake ~/Files/Projects/dotfiles#${ceres.name} --target-host ${ceres.ip.address0} --sudo --ask-sudo-password
|
||||
nixos-rebuild switch --flake ~/projects/dotfiles#${ceres.name} --target-host ${ceres.ip.address0} --sudo --ask-sudo-password
|
||||
|
||||
update:
|
||||
nix flake update --flake ~/Files/Projects/dotfiles
|
||||
nix flake update --flake ~/projects/dotfiles
|
||||
|
||||
remove-redundant:
|
||||
ls **/*.hs | each { |file| hlint --refactor --refactor-options="--inplace" $file.name }
|
||||
|
|
|
|||
|
|
@ -1,91 +0,0 @@
|
|||
{
|
||||
config,
|
||||
flake,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
let
|
||||
inherit (flake) self;
|
||||
inherit (flake.config.people) user1;
|
||||
inherit (flake.config.machines) devices;
|
||||
inherit (flake.config.people.users.${user1}) name paths;
|
||||
hostname = config.networking.hostName;
|
||||
in
|
||||
{
|
||||
users = {
|
||||
users.${user1} = {
|
||||
description = name;
|
||||
name = user1;
|
||||
isNormalUser = true;
|
||||
shell = pkgs.nushell;
|
||||
extraGroups = [
|
||||
"adbusers"
|
||||
"disk"
|
||||
"libvirtd"
|
||||
"netdev"
|
||||
"networkmanager"
|
||||
"plugdev"
|
||||
"samba"
|
||||
"vboxusers"
|
||||
"wheel"
|
||||
];
|
||||
};
|
||||
};
|
||||
home-manager.users = {
|
||||
${user1} = {
|
||||
home = {
|
||||
username = user1;
|
||||
homeDirectory = "/home/${user1}";
|
||||
file = {
|
||||
"./.config/scripts/get_weather.sh" = {
|
||||
source = ./files/scripts/get_weather.sh;
|
||||
executable = true;
|
||||
};
|
||||
".config/wallpaper" = {
|
||||
source = ./files/wallpaper;
|
||||
recursive = true;
|
||||
};
|
||||
"./.config/vesktop/themes/macchiato-theme.css" = {
|
||||
source = ./files/themes/vesktop/macchiato-theme.css;
|
||||
};
|
||||
};
|
||||
sessionVariables = {
|
||||
VISUAL = lib.getExe pkgs.zed-editor;
|
||||
GTK_THEME = "catppuccin-macchiato-mauve-compact";
|
||||
};
|
||||
};
|
||||
imports = [
|
||||
{
|
||||
home.stateVersion = config.system.stateVersion;
|
||||
}
|
||||
{
|
||||
imports = [
|
||||
self.homeModules."${devices.${hostname}.name}-${user1}"
|
||||
];
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
systemd.tmpfiles = {
|
||||
rules =
|
||||
[
|
||||
"d ${paths.path0} 0755 ${user1} users -"
|
||||
]
|
||||
++ (map (path: "d /home/${user1}/${path} 0755 ${user1} users -") [
|
||||
"Files"
|
||||
"Files/Scripts"
|
||||
"Files/Games"
|
||||
"Files/Screenshots"
|
||||
])
|
||||
++ (map (path: "R /home/${user1}/${path} 0755 ${user1} users - -") [
|
||||
"Desktop"
|
||||
"Documents"
|
||||
"Music"
|
||||
"Pictures"
|
||||
"Public"
|
||||
"Templates"
|
||||
"Videos"
|
||||
]);
|
||||
};
|
||||
}
|
||||
|
|
@ -1,19 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
for i in {1..5}
|
||||
do
|
||||
text=$(curl -s "https://wttr.in/$1?format=1")
|
||||
if [[ $? == 0 ]]
|
||||
then
|
||||
text=$(echo "$text" | sed -E "s/\s+/ /g")
|
||||
tooltip=$(curl -s "https://wttr.in/$1?format=4")
|
||||
if [[ $? == 0 ]]
|
||||
then
|
||||
tooltip=$(echo "$tooltip" | sed -E "s/\s+/ /g")
|
||||
echo "{\"text\":\"$text\", \"tooltip\":\"$tooltip\"}"
|
||||
exit
|
||||
fi
|
||||
fi
|
||||
sleep 2
|
||||
done
|
||||
echo "{\"text\":\"error\", \"tooltip\":\"error\"}"
|
||||
|
|
@ -1 +0,0 @@
|
|||
@import url("https://catppuccin.github.io/discord/dist/catppuccin-macchiato.theme.css");
|
||||
|
Before Width: | Height: | Size: 772 KiB |
|
Before Width: | Height: | Size: 578 KiB |
|
Before Width: | Height: | Size: 1.2 MiB |
|
Before Width: | Height: | Size: 886 KiB |
|
Before Width: | Height: | Size: 201 KiB |
|
Before Width: | Height: | Size: 808 KiB |
|
Before Width: | Height: | Size: 578 KiB |
|
Before Width: | Height: | Size: 1.7 MiB |
|
Before Width: | Height: | Size: 3.3 MiB |
|
Before Width: | Height: | Size: 5.1 MiB |
|
Before Width: | Height: | Size: 1.2 MiB |
|
Before Width: | Height: | Size: 3.5 MiB |
|
Before Width: | Height: | Size: 632 KiB |
|
Before Width: | Height: | Size: 460 KiB |
|
Before Width: | Height: | Size: 8.2 MiB |
|
Before Width: | Height: | Size: 1.1 MiB |
|
Before Width: | Height: | Size: 3.3 MiB |
|
Before Width: | Height: | Size: 833 KiB |
|
Before Width: | Height: | Size: 467 KiB |
|
Before Width: | Height: | Size: 2 MiB |
|
Before Width: | Height: | Size: 1.8 MiB |
|
Before Width: | Height: | Size: 1.6 MiB |
|
Before Width: | Height: | Size: 257 KiB |
|
Before Width: | Height: | Size: 261 KiB |
|
Before Width: | Height: | Size: 144 KiB |
|
Before Width: | Height: | Size: 501 KiB |
|
Before Width: | Height: | Size: 252 KiB |
|
Before Width: | Height: | Size: 646 KiB |
|
Before Width: | Height: | Size: 422 KiB |
|
Before Width: | Height: | Size: 552 KiB |
|
Before Width: | Height: | Size: 366 KiB |
|
Before Width: | Height: | Size: 1.2 MiB |
|
Before Width: | Height: | Size: 747 KiB |
|
Before Width: | Height: | Size: 1.3 MiB |
|
Before Width: | Height: | Size: 1.7 MiB |
|
Before Width: | Height: | Size: 665 KiB |
|
Before Width: | Height: | Size: 1.8 MiB |
|
Before Width: | Height: | Size: 869 KiB |
|
Before Width: | Height: | Size: 302 KiB |
|
Before Width: | Height: | Size: 457 KiB |
|
Before Width: | Height: | Size: 876 KiB |
|
Before Width: | Height: | Size: 529 KiB |
|
Before Width: | Height: | Size: 258 KiB |
|
Before Width: | Height: | Size: 568 KiB |
|
Before Width: | Height: | Size: 323 KiB |
|
Before Width: | Height: | Size: 720 KiB |
|
Before Width: | Height: | Size: 185 KiB |
|
Before Width: | Height: | Size: 289 KiB |
|
Before Width: | Height: | Size: 405 KiB |
|
Before Width: | Height: | Size: 1.6 MiB |
|
Before Width: | Height: | Size: 1.6 MiB |
|
Before Width: | Height: | Size: 1.6 MiB |
|
Before Width: | Height: | Size: 4.1 MiB |
|
Before Width: | Height: | Size: 787 KiB |
|
Before Width: | Height: | Size: 1.3 MiB |
|
Before Width: | Height: | Size: 1.7 MiB |
|
|
@ -4,7 +4,7 @@
|
|||
...
|
||||
}:
|
||||
let
|
||||
inherit (flake.config.people) user0 user1;
|
||||
inherit (flake.config.people) user0;
|
||||
inherit (flake.config.machines.devices) mars ceres synology;
|
||||
inherit (flake.config.services) instances;
|
||||
synologySecrets = config.sops.secrets."network/synology".path;
|
||||
|
|
@ -15,7 +15,6 @@ in
|
|||
let
|
||||
synologyDrives = [
|
||||
"folder0"
|
||||
"folder1"
|
||||
];
|
||||
|
||||
storageDrives = [
|
||||
|
|
@ -88,7 +87,6 @@ in
|
|||
|
||||
systemd.tmpfiles.rules = [
|
||||
"Z ${config.home-manager.users.${user0}.home.homeDirectory} 0755 ${user0} users -"
|
||||
"Z ${config.home-manager.users.${user1}.home.homeDirectory} 0755 ${user1} users -"
|
||||
"Z ${mars.storage0.mount} 0755 ${user0} users -"
|
||||
"Z ${mars.storage1.mount} 0755 ${user0} users -"
|
||||
];
|
||||
|
|
|
|||