desktop
This commit is contained in:
parent
89028735fa
commit
9c2bf01196
12
flake.lock
12
flake.lock
|
@ -41,11 +41,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1719827439,
|
||||
"narHash": "sha256-tneHOIv1lEavZ0vQ+rgz67LPNCgOZVByYki3OkSshFU=",
|
||||
"lastModified": 1720045378,
|
||||
"narHash": "sha256-lmE7B+QXw7lWdBu5GQlUABSpzPk3YBb9VbV+IYK5djk=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "59ce796b2563e19821361abbe2067c3bb4143a7d",
|
||||
"rev": "0a30138c694ab3b048ac300794c2eb599dc40266",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -106,11 +106,11 @@
|
|||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1719915469,
|
||||
"narHash": "sha256-dNQPEges+os5o3SpV3gkIJk2wNX+eIzv6D48S3WxBRo=",
|
||||
"lastModified": 1720087678,
|
||||
"narHash": "sha256-uOhYJU3ldDKXYV+mFaXcPtyjq/UIMh/6SCuoVNU9rxM=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "88d829e52cfbeee71d81704ce28f5b439f6dea16",
|
||||
"rev": "1afc5440469f94e7ed26e8648820971b102afdc3",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
|
@ -14,10 +14,10 @@
|
|||
};
|
||||
|
||||
outputs = { nixpkgs, home-manager, ... }@inputs: {
|
||||
nixosConfigurations.pc = nixpkgs.lib.nixosSystem {
|
||||
nixosConfigurations.desktop = nixpkgs.lib.nixosSystem {
|
||||
specialArgs = {inherit inputs;};
|
||||
modules = [
|
||||
./hosts/pc
|
||||
./hosts/desktop
|
||||
];
|
||||
};
|
||||
nixosConfigurations.laptop = nixpkgs.lib.nixosSystem {
|
||||
|
|
|
@ -12,16 +12,14 @@
|
|||
pu = "bash ~/nix/home/zsh/push.sh";
|
||||
fr = "sudo systemctl reboot --firmware";
|
||||
ser = "ssh root@joygnu.org";
|
||||
rb = "bash ~/nix/home/zsh/pc-laptop.sh";
|
||||
rb = "bash ~/nix/home/zsh/desktop-laptop.sh";
|
||||
up = "sudo nix flake update ~/nix";
|
||||
del = "sudo nix-collect-garbage -d";
|
||||
gtk = "nvim ~/nix/home/gtk/default.nix";
|
||||
hy = "nvim ~/nix/home/hyprland/default.nix";
|
||||
zs = "nvim ~/nix/home/zsh/default.nix";
|
||||
ec = "nvim ~/nix/hosts/pc/default.nix";
|
||||
el = "nvim ~/nix/hosts/laptop/default.nix";
|
||||
ef = "nvim ~/nix/flake.nix";
|
||||
ep = "nvim ~/nix/hosts/pc/default.nix";
|
||||
ed = "nvim ~/nix/hosts/desktop/default.nix";
|
||||
eh = "nvim ~/nix/home/default.nix";
|
||||
em = "nvim ~/nix/modules/misc/default.nix";
|
||||
es = "nvim ~/nix/modules/stylix/default.nix";
|
||||
|
|
|
@ -2,11 +2,9 @@
|
|||
|
||||
hostname=$(hostname)
|
||||
|
||||
if [[ $hostname == *"pc"* ]]; then
|
||||
echo "This machine is identified as a Desktop PC."
|
||||
sudo nixos-rebuild switch --flake ~/nix/#pc
|
||||
if [[ $hostname == *"desktop"* ]]; then
|
||||
sudo nixos-rebuild switch --flake ~/nix/#desktop
|
||||
elif [[ $hostname == *"laptop"* ]]; then
|
||||
echo "This machine is identified as a Laptop."
|
||||
sudo nixos-rebuild switch --flake ~/nix/#laptop
|
||||
else
|
||||
echo "Unable to determine the type of machine."
|
|
@ -1,6 +1,6 @@
|
|||
{ config, lib, pkgs, modulesPath, inputs, ... }:
|
||||
{
|
||||
networking.hostName = "pc";
|
||||
networking.hostName = "desktop";
|
||||
networking.networkmanager.enable = true;
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
boot.loader.efi.canTouchEfiVariables = true;
|
Loading…
Reference in a new issue