mirror of
https://github.com/Gerg-L/nixos.git
synced 2025-12-10 00:43:56 -05:00
made username easily changable
switched from independant home-manager updating to unified updating updated disk parttion uuid's after resintalling
This commit is contained in:
parent
1c416dc728
commit
733eda4798
8 changed files with 44 additions and 57 deletions
|
|
@ -18,10 +18,6 @@ let
|
|||
nix-collect-garbage -d
|
||||
'';
|
||||
|
||||
apply-user = pkgs.writeShellScriptBin "apply-user" ''
|
||||
home-manager switch --flake /etc/nixos/#$(whoami)
|
||||
'';
|
||||
|
||||
apply-system = pkgs.writeShellScriptBin "apply-system" ''
|
||||
if ! [ $(id -u) = 0 ]; then
|
||||
echo "RUN AS ROOT"
|
||||
|
|
@ -37,8 +33,6 @@ let
|
|||
fi
|
||||
update-system
|
||||
apply-system
|
||||
apply-user
|
||||
sudo -u gerg apply-user
|
||||
'';
|
||||
|
||||
polybar-tray = pkgs.writeShellScriptBin "polybar-tray" ''
|
||||
|
|
@ -52,5 +46,5 @@ let
|
|||
curl -F 'clbin=<-' https://clbin.com
|
||||
'';
|
||||
in {
|
||||
environment.systemPackages = [ update-system clean-store apply-user apply-system polybar-tray full-upgrade pastebin];
|
||||
environment.systemPackages = [ update-system clean-store apply-system polybar-tray full-upgrade pastebin];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
{username, ...}:
|
||||
{
|
||||
services.samba-wsdd.enable = true; # make shares visible for windows 10 clients
|
||||
networking.firewall = {
|
||||
|
|
@ -10,11 +11,11 @@
|
|||
openFirewall = true;
|
||||
shares = {
|
||||
Share = {
|
||||
path = "/home/gerg/Share";
|
||||
path = "/home/${username}/Share";
|
||||
browseable = "no";
|
||||
"read only" = "no";
|
||||
"guest ok" = "no";
|
||||
"force user" = "gerg";
|
||||
"force user" = "${username}";
|
||||
"force group" = "users";
|
||||
};
|
||||
};
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
{ pkgs, ... }:
|
||||
{ pkgs, username, ... }:
|
||||
{
|
||||
boot = {
|
||||
kernelParams = [ "amd_iommu=on" "iommu=pt" "vfio_iommu_type1.allow_unsafe_interrupts=1" "kvm.ignore_msrs=1" ];
|
||||
|
|
@ -15,7 +15,7 @@
|
|||
runAsRoot = true;
|
||||
ovmf.enable = true;
|
||||
verbatimConfig = ''
|
||||
user = "gerg"
|
||||
user = "${username}"
|
||||
group = "kvm"
|
||||
namespaces = []
|
||||
'';
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
{config, pkgs, ... }:
|
||||
{config, pkgs, username, ... }:
|
||||
{
|
||||
services.xserver = {
|
||||
enable = true;
|
||||
|
|
@ -20,7 +20,7 @@
|
|||
enable = true;
|
||||
extraConfig = ''
|
||||
[greeter]
|
||||
user = gerg
|
||||
user = ${username}
|
||||
show-password-label = false
|
||||
password-label-text =
|
||||
invalid-password-text =
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue