From e6efda0a5541988e255e71a3ae3c1e21f6d38c4d Mon Sep 17 00:00:00 2001 From: Manuel Thalmann Date: Sun, 3 Nov 2024 22:33:44 +0100 Subject: [PATCH] Create a separate config file for desktops --- profiles/machines/manuel/defaults.nix | 3 +- profiles/users/manuel/config.nix | 44 ----------------------- profiles/users/manuel/desktop.nix | 51 +++++++++++++++++++++++++++ 3 files changed, 52 insertions(+), 46 deletions(-) create mode 100644 profiles/users/manuel/desktop.nix diff --git a/profiles/machines/manuel/defaults.nix b/profiles/machines/manuel/defaults.nix index f1a04723..fe018dc5 100644 --- a/profiles/machines/manuel/defaults.nix +++ b/profiles/machines/manuel/defaults.nix @@ -1,6 +1,5 @@ { ... }: { imports = [ - ../../users/manuel/config.nix - ../../../lib/modules/valhalla.nix + ../../users/manuel/desktop.nix ]; } diff --git a/profiles/users/manuel/config.nix b/profiles/users/manuel/config.nix index 0e649fdb..96f7eae2 100644 --- a/profiles/users/manuel/config.nix +++ b/profiles/users/manuel/config.nix @@ -3,14 +3,6 @@ config = { valhalla = { - programs = { - nextcloud.enable = true; - }; - - linux.programs = { - rclone.enable = true; - }; - users.manuel = { displayName = "Manuel Thalmann"; mailAddress = "m@nuth.ch"; @@ -31,42 +23,6 @@ "wheel" "nix-users" ]; - - programs = { - rclone = { - configurations = { - nextcloud = { - dirName = "Nextcloud"; - }; - - proton = { - dirName = "Proton"; - cacheDuration = "2w"; - }; - }; - }; - }; - }; - - windows.users.manuel = { - programs = { - nextcloud = { - folderSyncs = let - localPath = "C:/tools/RetroArch-Win64"; - remotePath = "/Saved Games/RetroArch"; - in [ - { - remotePath = "${remotePath}/Saves"; - localPath = "${localPath}/saves"; - virtualFiles = false; - } - { - remotePath = "${remotePath}/System"; - localPath = "${localPath}/system"; - } - ]; - }; - }; }; }; }; diff --git a/profiles/users/manuel/desktop.nix b/profiles/users/manuel/desktop.nix new file mode 100644 index 00000000..73174d9b --- /dev/null +++ b/profiles/users/manuel/desktop.nix @@ -0,0 +1,51 @@ +{ ... }: { + imports = [ ./config.nix ]; + + config = { + valhalla = { + programs = { + nextcloud.enable = true; + }; + + linux.programs = { + rclone.enable = true; + }; + + linux.users.manuel.programs = { + rclone = { + configurations = { + nextcloud = { + dirName = "Nextcloud"; + }; + + proton = { + dirName = "Proton"; + cacheDuration = "2w"; + }; + }; + }; + }; + + windows.users.manuel = { + programs = { + nextcloud = { + folderSyncs = let + localPath = "C:/tools/RetroArch-Win64"; + remotePath = "/Saved Games/RetroArch"; + in [ + { + remotePath = "${remotePath}/Saves"; + localPath = "${localPath}/saves"; + virtualFiles = false; + } + { + remotePath = "${remotePath}/System"; + localPath = "${localPath}/system"; + } + ]; + }; + }; + }; + }; + }; +}