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