Regenerated
This commit is contained in:
+282
-343
File diff suppressed because it is too large
Load Diff
+2
-56
@@ -118,11 +118,8 @@ The Nix flake definition for Droidnix.
|
|||||||
})
|
})
|
||||||
flatpak.nixosModules."nix-flatpak"
|
flatpak.nixosModules."nix-flatpak"
|
||||||
./generated/hosts/traveldroid/host.nix
|
./generated/hosts/traveldroid/host.nix
|
||||||
|
./generated/users/henrov.nix
|
||||||
|
|
||||||
|
|
||||||
];
|
];
|
||||||
|
|
||||||
specialArgs = {
|
specialArgs = {
|
||||||
inherit flakeRoot;
|
inherit flakeRoot;
|
||||||
inherit home-manager import-tree stylix hyprland zen-browser;
|
inherit home-manager import-tree stylix hyprland zen-browser;
|
||||||
@@ -141,12 +138,8 @@ let
|
|||||||
hostname = "traveldroid";
|
hostname = "traveldroid";
|
||||||
|
|
||||||
modulesPath = "${flakeRoot}/generated/modules/${hostname}";
|
modulesPath = "${flakeRoot}/generated/modules/${hostname}";
|
||||||
usersPath = "${flakeRoot}/generated/users";
|
|
||||||
|
|
||||||
hostModules = import-tree modulesPath;
|
hostModules = import-tree modulesPath;
|
||||||
globalUsers = import-tree usersPath;
|
allModules = hostModules.imports ;
|
||||||
|
|
||||||
allModules = hostModules.imports ++ globalUsers.imports;
|
|
||||||
|
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
@@ -3311,53 +3304,6 @@ This sets the networking.
|
|||||||
|
|
||||||
* generated/users
|
* generated/users
|
||||||
|
|
||||||
** =generated/parked/users/copy_config_2_config.nix=
|
|
||||||
This copies stuff to the user home-folder
|
|
||||||
#+BEGIN_SRC nix :tangle generated/parked/users/copy_config_2_config.nix :noweb yes :mkdirp yes :eval never
|
|
||||||
{ config, pkgs, lib, flakeRoot, ... }:
|
|
||||||
|
|
||||||
let
|
|
||||||
username = config.users.users.defaultUser or "henrov";
|
|
||||||
configDir = "/home/${username}/.config";
|
|
||||||
assetPath = "${flakeRoot}/.config";
|
|
||||||
in
|
|
||||||
{
|
|
||||||
environment.systemPackages = [ pkgs.rsync ];
|
|
||||||
|
|
||||||
systemd.services.copyAssets = {
|
|
||||||
description = "Copy assets to ${username}'s .config directory";
|
|
||||||
wantedBy = [ "multi-user.target" ];
|
|
||||||
|
|
||||||
# oneshot service runs once at boot
|
|
||||||
serviceConfig.Type = "oneshot";
|
|
||||||
|
|
||||||
# Always use /bin/sh -c for multi-line commands
|
|
||||||
serviceConfig.ExecStart = ''
|
|
||||||
/bin/sh -c '
|
|
||||||
echo "Copying assets from ${assetPath} to ${configDir} ..."
|
|
||||||
|
|
||||||
if [ ! -d "${assetPath}" ]; then
|
|
||||||
echo "ERROR: ${assetPath} does not exist"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
mkdir -p "${configDir}"
|
|
||||||
chown -R u+rwx ${username}:${username} "${configDir}"
|
|
||||||
|
|
||||||
${pkgs.rsync}/bin/rsync -a --no-owner --no-group "${assetPath}/" "${configDir}/"
|
|
||||||
|
|
||||||
# Fix .config permissions
|
|
||||||
mkdir -p "${configDir}"
|
|
||||||
chown -R ${username}:${username} "${configDir}"
|
|
||||||
chmod -R u+rwx "${configDir}"
|
|
||||||
|
|
||||||
echo "Done copying config files."
|
|
||||||
'
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
}
|
|
||||||
#+END_SRC
|
|
||||||
|
|
||||||
** =generated/users/henrov.nix=
|
** =generated/users/henrov.nix=
|
||||||
This is the default user, just search and replace henrov another name if you want to change
|
This is the default user, just search and replace henrov another name if you want to change
|
||||||
#+BEGIN_SRC nix :tangle generated/users/henrov.nix :noweb yes :mkdirp yes :eval never
|
#+BEGIN_SRC nix :tangle generated/users/henrov.nix :noweb yes :mkdirp yes :eval never
|
||||||
|
|||||||
+1
-4
@@ -48,11 +48,8 @@
|
|||||||
})
|
})
|
||||||
flatpak.nixosModules."nix-flatpak"
|
flatpak.nixosModules."nix-flatpak"
|
||||||
./generated/hosts/traveldroid/host.nix
|
./generated/hosts/traveldroid/host.nix
|
||||||
|
./generated/users/henrov.nix
|
||||||
|
|
||||||
|
|
||||||
];
|
];
|
||||||
|
|
||||||
specialArgs = {
|
specialArgs = {
|
||||||
inherit flakeRoot;
|
inherit flakeRoot;
|
||||||
inherit home-manager import-tree stylix hyprland zen-browser;
|
inherit home-manager import-tree stylix hyprland zen-browser;
|
||||||
|
|||||||
@@ -4,12 +4,8 @@ let
|
|||||||
hostname = "traveldroid";
|
hostname = "traveldroid";
|
||||||
|
|
||||||
modulesPath = "${flakeRoot}/generated/modules/${hostname}";
|
modulesPath = "${flakeRoot}/generated/modules/${hostname}";
|
||||||
usersPath = "${flakeRoot}/generated/users";
|
|
||||||
|
|
||||||
hostModules = import-tree modulesPath;
|
hostModules = import-tree modulesPath;
|
||||||
globalUsers = import-tree usersPath;
|
allModules = hostModules.imports ;
|
||||||
|
|
||||||
allModules = hostModules.imports ++ globalUsers.imports;
|
|
||||||
|
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user