Compare commits

...

12 Commits

Author SHA1 Message Date
6e8f81ee07 reduce pad 2026-05-08 15:02:29 +09:00
f01857a017 bootloader 2026-05-08 15:00:07 +09:00
7d1436ac54 1 2026-05-08 14:40:12 +09:00
e81e3be023 add hyprland 2026-05-08 11:41:28 +09:00
441351bc5f 1 2026-05-08 00:11:30 +09:00
d7d6d6009e generated 2026-05-08 00:06:14 +09:00
b6f68807c0 update hyprland plugins 2026-05-08 00:01:14 +09:00
af6d69f9b8 add split monitor 2026-05-07 22:03:24 +09:00
c64cfb5e83 1 2026-05-07 22:02:02 +09:00
c9a3fe28fb Merge remote-tracking branch 'refs/remotes/origin/main' 2026-05-07 21:43:05 +09:00
6ca3a89910 add openmodelica 2026-05-07 21:42:20 +09:00
69b88803eb update hyprland 2026-05-07 21:41:52 +09:00
10 changed files with 829 additions and 91 deletions

View File

@@ -6,8 +6,7 @@
let let
myRizin = pkgs.rizin.passthru.withPlugins myRizin = pkgs.rizin.passthru.withPlugins
(plugins: [ plugins.jsdec plugins.rz-ghidra ]); (plugins: [ plugins.jsdec plugins.rz-ghidra ]);
in in {
{
imports = [ imports = [
./hardware-configuration.nix ./hardware-configuration.nix
./services/virtual.nix ./services/virtual.nix
@@ -16,26 +15,55 @@ in
./programs/hyprland.nix ./programs/hyprland.nix
]; ];
services.logind.lidSwitch = "suspend"; services.logind = {
lidSwitch = "suspend-then-hibernate";
lidSwitchExternalPower = "suspend";
lidSwitchDocked = "ignore";
powerKey = "poweroff";
powerKeyLongPress = "poweroff";
};
systemd.sleep.extraConfig = ''
HibernateDelaySec=30min
SuspendState=mem
'';
services.tlp = {
enable = true;
settings = {
CPU_SCALING_GOVERNOR_ON_AC = "performance";
CPU_SCALING_GOVERNOR_ON_BAT = "powersave";
CPU_ENERGY_PERF_POLICY_ON_BAT = "power";
CPU_ENERGY_PERF_POLICY_ON_AC = "performance";
CPU_BOOST_ON_BAT = 0;
CPU_BOOST_ON_AC = 1;
PLATFORM_PROFILE_ON_AC = "performance";
PLATFORM_PROFILE_ON_BAT = "low-power";
START_CHARGE_THRESH_BAT0 = 75;
STOP_CHARGE_THRESH_BAT0 =
80; # remove these two if your laptop doesn't support charge thresholds
};
};
powerManagement.enable = true;
services.power-profiles-daemon.enable = false;
nixpkgs.config.allowUnfree = true; nixpkgs.config.allowUnfree = true;
boot.kernel.sysctl = { boot.kernel.sysctl = { "net.ipv4.ip_forward" = 1; };
"net.ipv4.ip_forward" = 1;
};
#boot.loader.grub.device = "/dev/nvme1n1p1"; #boot.loader.grub.device = "/dev/nvme1n1p1";
boot.loader = { boot.loader = {
systemd-boot.enable = false; systemd-boot.enable = false;
efi = { efi = {
canTouchEfiVariables = true; canTouchEfiVariables = true;
efiSysMountPoint = "/boot/efi"; efiSysMountPoint = "/boot";
}; };
grub = { grub = {
enable = true; enable = true;
device = "nodev"; device = "nodev";
efiSupport = true; efiSupport = true;
useOSProber = true; useOSProber = true;
}; };
}; };
@@ -113,9 +141,20 @@ in
myRizin myRizin
libgit2 libgit2
inputs.helix.packages."${pkgs.system}".helix inputs.helix.packages."${pkgs.system}".helix
openmodelica
]; ];
nix.settings.experimental-features = [ "nix-command" "flakes" ]; nix.settings.experimental-features = [ "nix-command" "flakes" ];
nix.settings.trusted-users = [ "root" "allen" ];
nix.settings = {
substituters =
[ "https://allen-nixpkgs.cachix.org" "https://cache.nixos.org" ];
trusted-public-keys = [
"allen-nixpkgs.cachix.org-1:GS5qDYVloEiC6oeJQNijR3hsMKPqDSGbYUz35qtbMpg="
"cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY="
];
};
environment.variables = { environment.variables = {
LD_LIBRARY_PATH = lib.makeLibraryPath [ LD_LIBRARY_PATH = lib.makeLibraryPath [

556
flake.lock generated
View File

@@ -1,16 +1,87 @@
{ {
"nodes": { "nodes": {
"aquamarine": {
"inputs": {
"hyprutils": [
"hyprland",
"hyprutils"
],
"hyprwayland-scanner": [
"hyprland",
"hyprwayland-scanner"
],
"nixpkgs": [
"hyprland",
"nixpkgs"
],
"systems": [
"hyprland",
"systems"
]
},
"locked": {
"lastModified": 1777499565,
"narHash": "sha256-nU55VWk99Pn1QzQDDjFISocC4SgDZ3Xp+zb6ji3JclM=",
"owner": "hyprwm",
"repo": "aquamarine",
"rev": "813c1e8981893c11e118b19c125d6bc282f51765",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "aquamarine",
"type": "github"
}
},
"flake-compat": {
"flake": false,
"locked": {
"lastModified": 1767039857,
"narHash": "sha256-vNpUSpF5Nuw8xvDLj2KCwwksIbjua2LZCqhV1LNRDns=",
"owner": "NixOS",
"repo": "flake-compat",
"rev": "5edf11c44bc78a0d334f6334cdaf7d60d732daab",
"type": "github"
},
"original": {
"owner": "NixOS",
"repo": "flake-compat",
"type": "github"
}
},
"gitignore": {
"inputs": {
"nixpkgs": [
"hyprland",
"pre-commit-hooks",
"nixpkgs"
]
},
"locked": {
"lastModified": 1709087332,
"narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=",
"owner": "hercules-ci",
"repo": "gitignore.nix",
"rev": "637db329424fd7e46cf4185293b9cc8c88c95394",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "gitignore.nix",
"type": "github"
}
},
"helix": { "helix": {
"inputs": { "inputs": {
"nixpkgs": "nixpkgs", "nixpkgs": "nixpkgs",
"rust-overlay": "rust-overlay" "rust-overlay": "rust-overlay"
}, },
"locked": { "locked": {
"lastModified": 1759850138, "lastModified": 1777776915,
"narHash": "sha256-fYHIxjTvVIAEDWzenUROuzDPxy1rBCXZNPgh4b1dfgo=", "narHash": "sha256-okg6j5wIwTZmdrNhB1TOxpyLtJN9/fV6qXobWGpp+Y8=",
"owner": "helix-editor", "owner": "helix-editor",
"repo": "helix", "repo": "helix",
"rev": "5b0563419eeeaf0595c848865c46be4abad246a7", "rev": "87d5c05c4432a079d3b7aaa10cda1cfe1803c18c",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -27,11 +98,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1758463745, "lastModified": 1763992789,
"narHash": "sha256-uhzsV0Q0I9j2y/rfweWeGif5AWe0MGrgZ/3TjpDYdGA=", "narHash": "sha256-WHkdBlw6oyxXIra/vQPYLtqY+3G8dUVZM8bEXk0t8x4=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "3b955f5f0a942f9f60cdc9cacb7844335d0f21c3", "rev": "44831a7eaba4360fb81f2acc5ea6de5fde90aaa3",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -41,13 +112,347 @@
"type": "github" "type": "github"
} }
}, },
"hyprcursor": {
"inputs": {
"hyprlang": [
"hyprland",
"hyprlang"
],
"nixpkgs": [
"hyprland",
"nixpkgs"
],
"systems": [
"hyprland",
"systems"
]
},
"locked": {
"lastModified": 1776511930,
"narHash": "sha256-fCpwFiTW0rT7oKJqr3cqHMnkwypSwQKpbtUEtxdkgrM=",
"owner": "hyprwm",
"repo": "hyprcursor",
"rev": "39435900785d0c560c6ae8777d29f28617d031ef",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "hyprcursor",
"type": "github"
}
},
"hyprgraphics": {
"inputs": {
"hyprutils": [
"hyprland",
"hyprutils"
],
"nixpkgs": [
"hyprland",
"nixpkgs"
],
"systems": [
"hyprland",
"systems"
]
},
"locked": {
"lastModified": 1776426399,
"narHash": "sha256-RUESLKNikIeEq9ymGJ6nmcDXiSFQpUW1IhJ245nL3xM=",
"owner": "hyprwm",
"repo": "hyprgraphics",
"rev": "68d064434787cf1ed4a2fe257c03c5f52f33cf84",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "hyprgraphics",
"type": "github"
}
},
"hyprland": {
"inputs": {
"aquamarine": "aquamarine",
"hyprcursor": "hyprcursor",
"hyprgraphics": "hyprgraphics",
"hyprland-guiutils": "hyprland-guiutils",
"hyprland-protocols": "hyprland-protocols",
"hyprlang": "hyprlang",
"hyprutils": "hyprutils",
"hyprwayland-scanner": "hyprwayland-scanner",
"hyprwire": "hyprwire",
"nixpkgs": "nixpkgs_2",
"pre-commit-hooks": "pre-commit-hooks",
"systems": "systems",
"xdph": "xdph"
},
"locked": {
"lastModified": 1778199997,
"narHash": "sha256-vmCYnK7/iRQGWj+s0l3+cf/IVoUcCTrlFtgUCTwRdjU=",
"owner": "hyprwm",
"repo": "Hyprland",
"rev": "de9f8dc9831d921cd1ee30d5d14f45f0e345a8ca",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "Hyprland",
"type": "github"
}
},
"hyprland-guiutils": {
"inputs": {
"aquamarine": [
"hyprland",
"aquamarine"
],
"hyprgraphics": [
"hyprland",
"hyprgraphics"
],
"hyprlang": [
"hyprland",
"hyprlang"
],
"hyprtoolkit": "hyprtoolkit",
"hyprutils": [
"hyprland",
"hyprutils"
],
"hyprwayland-scanner": [
"hyprland",
"hyprwayland-scanner"
],
"nixpkgs": [
"hyprland",
"nixpkgs"
],
"systems": [
"hyprland",
"systems"
]
},
"locked": {
"lastModified": 1776426575,
"narHash": "sha256-KI6nIfVihn/DPaeB5Et46Xg3dkNHrrEtUd5LBBVomB0=",
"owner": "hyprwm",
"repo": "hyprland-guiutils",
"rev": "a968d211048e3ed538e47b84cb3649299578f19d",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "hyprland-guiutils",
"type": "github"
}
},
"hyprland-protocols": {
"inputs": {
"nixpkgs": [
"hyprland",
"nixpkgs"
],
"systems": [
"hyprland",
"systems"
]
},
"locked": {
"lastModified": 1772460177,
"narHash": "sha256-/6G/MsPvtn7bc4Y32pserBT/Z4SUUdBd4XYJpOEKVR4=",
"owner": "hyprwm",
"repo": "hyprland-protocols",
"rev": "1cb6db5fd6bb8aee419f4457402fa18293ace917",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "hyprland-protocols",
"type": "github"
}
},
"hyprlang": {
"inputs": {
"hyprutils": [
"hyprland",
"hyprutils"
],
"nixpkgs": [
"hyprland",
"nixpkgs"
],
"systems": [
"hyprland",
"systems"
]
},
"locked": {
"lastModified": 1777320127,
"narHash": "sha256-Qu+Wf2Bp5qUjyn2YpZNq8a7JyzTGowhT1knrwE38a9U=",
"owner": "hyprwm",
"repo": "hyprlang",
"rev": "090117506ddc3d7f26e650ff344d378c2ec329cc",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "hyprlang",
"type": "github"
}
},
"hyprtoolkit": {
"inputs": {
"aquamarine": [
"hyprland",
"hyprland-guiutils",
"aquamarine"
],
"hyprgraphics": [
"hyprland",
"hyprland-guiutils",
"hyprgraphics"
],
"hyprlang": [
"hyprland",
"hyprland-guiutils",
"hyprlang"
],
"hyprutils": [
"hyprland",
"hyprland-guiutils",
"hyprutils"
],
"hyprwayland-scanner": [
"hyprland",
"hyprland-guiutils",
"hyprwayland-scanner"
],
"nixpkgs": [
"hyprland",
"hyprland-guiutils",
"nixpkgs"
],
"systems": [
"hyprland",
"hyprland-guiutils",
"systems"
]
},
"locked": {
"lastModified": 1772462885,
"narHash": "sha256-5pHXrQK9zasMnIo6yME6EOXmWGFMSnCITcfKshhKJ9I=",
"owner": "hyprwm",
"repo": "hyprtoolkit",
"rev": "9af245a69fa6b286b88ddfc340afd288e00a6998",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "hyprtoolkit",
"type": "github"
}
},
"hyprutils": {
"inputs": {
"nixpkgs": [
"hyprland",
"nixpkgs"
],
"systems": [
"hyprland",
"systems"
]
},
"locked": {
"lastModified": 1778179779,
"narHash": "sha256-Ri6rVf54CRD3aISHLhSY6H4tBScVjm9ebkv7rF2lcZM=",
"owner": "hyprwm",
"repo": "hyprutils",
"rev": "3e170e5ad010602671f5f25b327e8bdb8fdd532c",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "hyprutils",
"type": "github"
}
},
"hyprwayland-scanner": {
"inputs": {
"nixpkgs": [
"hyprland",
"nixpkgs"
],
"systems": [
"hyprland",
"systems"
]
},
"locked": {
"lastModified": 1777159683,
"narHash": "sha256-Jxixw6wZphUp+nHYxOKUYSckL17QMBx2d5Zp0rJHr1g=",
"owner": "hyprwm",
"repo": "hyprwayland-scanner",
"rev": "b8632713a6beaf28b56f2a7b0ab2fb7088dbb404",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "hyprwayland-scanner",
"type": "github"
}
},
"hyprwire": {
"inputs": {
"hyprutils": [
"hyprland",
"hyprutils"
],
"nixpkgs": [
"hyprland",
"nixpkgs"
],
"systems": [
"hyprland",
"systems"
]
},
"locked": {
"lastModified": 1777388329,
"narHash": "sha256-40YxVGF2rA9iH3D7am5fy4EOSBbMgpJtJ9yhl0Cx+qI=",
"owner": "hyprwm",
"repo": "hyprwire",
"rev": "04be2897e05f9b271d532b5ae56ca088d2eeac02",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "hyprwire",
"type": "github"
}
},
"nix-filter": {
"locked": {
"lastModified": 1693833173,
"narHash": "sha256-hlMABKrGbEiJD5dwUSfnw1CQ3bG7KKwDV+Nx3bEZd7U=",
"owner": "numtide",
"repo": "nix-filter",
"rev": "ac030bd9ba98e318e1f4c4328d60766ade8ebe8b",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "nix-filter",
"type": "github"
}
},
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1759381078, "lastModified": 1775036866,
"narHash": "sha256-gTrEEp5gEspIcCOx9PD8kMaF1iEmfBcTbO0Jag2QhQs=", "narHash": "sha256-ZojAnPuCdy657PbTq5V0Y+AHKhZAIwSIT2cb8UgAz/U=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "7df7ff7d8e00218376575f0acdcc5d66741351ee", "rev": "6201e203d09599479a3b3450ed24fa81537ebc4e",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -59,11 +464,27 @@
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1759994382, "lastModified": 1777954456,
"narHash": "sha256-wSK+3UkalDZRVHGCRikZ//CyZUJWDJkBDTQX1+G77Ow=", "narHash": "sha256-hGdgeU2Nk87RAuZyYjyDjFL6LK7dAZN5RE9+hrDTkDU=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "5da4a26309e796daa7ffca72df93dbe53b8164c7", "rev": "549bd84d6279f9852cae6225e372cc67fb91a4c1",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_3": {
"locked": {
"lastModified": 1767313136,
"narHash": "sha256-16KkgfdYqjaeRGBaYsNrhPRRENs0qzkQVUooNHtoy2w=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "ac62194c3917d5f474c1a844b6fd6da2db95077d",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -73,11 +494,36 @@
"type": "github" "type": "github"
} }
}, },
"pre-commit-hooks": {
"inputs": {
"flake-compat": "flake-compat",
"gitignore": "gitignore",
"nixpkgs": [
"hyprland",
"nixpkgs"
]
},
"locked": {
"lastModified": 1776796298,
"narHash": "sha256-PcRvlWayisPSjd0UcRQbhG8Oqw78AcPE6x872cPRHN8=",
"owner": "cachix",
"repo": "git-hooks.nix",
"rev": "3cfd774b0a530725a077e17354fbdb87ea1c4aad",
"type": "github"
},
"original": {
"owner": "cachix",
"repo": "git-hooks.nix",
"type": "github"
}
},
"root": { "root": {
"inputs": { "inputs": {
"helix": "helix", "helix": "helix",
"home-manager": "home-manager", "home-manager": "home-manager",
"nixpkgs": "nixpkgs_2" "hyprland": "hyprland",
"nixpkgs": "nixpkgs_3",
"split-monitor-workspaces": "split-monitor-workspaces"
} }
}, },
"rust-overlay": { "rust-overlay": {
@@ -88,11 +534,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1759631821, "lastModified": 1775358767,
"narHash": "sha256-V8A1L0FaU/aSXZ1QNJScxC12uP4hANeRBgI4YdhHeRM=", "narHash": "sha256-f2eC+WIfhjevCPQILuV08i/kmKZzYZpUvkom/33VxCA=",
"owner": "oxalica", "owner": "oxalica",
"repo": "rust-overlay", "repo": "rust-overlay",
"rev": "1d7cbdaad90f8a5255a89a6eddd8af24dc89cafe", "rev": "20fd44bc663daa53a2575e01293e24e681d62244",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -100,6 +546,84 @@
"repo": "rust-overlay", "repo": "rust-overlay",
"type": "github" "type": "github"
} }
},
"split-monitor-workspaces": {
"inputs": {
"hyprland": [
"hyprland"
],
"nix-filter": "nix-filter"
},
"locked": {
"lastModified": 1778019879,
"narHash": "sha256-E4P1ieHBhshPBWn5/OZvsPLsTbXfjUOQ/9/M1IbYYwk=",
"owner": "zjeffer",
"repo": "split-monitor-workspaces",
"rev": "d55750b18d9cc9b8b8a10e650d29950578471398",
"type": "github"
},
"original": {
"owner": "zjeffer",
"ref": "feat/zjeffer/lua",
"repo": "split-monitor-workspaces",
"type": "github"
}
},
"systems": {
"locked": {
"lastModified": 1689347949,
"narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=",
"owner": "nix-systems",
"repo": "default-linux",
"rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default-linux",
"type": "github"
}
},
"xdph": {
"inputs": {
"hyprland-protocols": [
"hyprland",
"hyprland-protocols"
],
"hyprlang": [
"hyprland",
"hyprlang"
],
"hyprutils": [
"hyprland",
"hyprutils"
],
"hyprwayland-scanner": [
"hyprland",
"hyprwayland-scanner"
],
"nixpkgs": [
"hyprland",
"nixpkgs"
],
"systems": [
"hyprland",
"systems"
]
},
"locked": {
"lastModified": 1777585783,
"narHash": "sha256-JTeWRy42VElroJ0rVdZuVXSoTLsx+NzQfGPKMbtn3SU=",
"owner": "hyprwm",
"repo": "xdg-desktop-portal-hyprland",
"rev": "fa50d6fbaff8f42c61071b87b034a90d82a33558",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "xdg-desktop-portal-hyprland",
"type": "github"
}
} }
}, },
"root": "root", "root": "root",

View File

@@ -4,26 +4,66 @@
inputs = { inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-25.05"; nixpkgs.url = "github:NixOS/nixpkgs/nixos-25.05";
helix.url = "github:helix-editor/helix/master"; helix.url = "github:helix-editor/helix/master";
hyprland.url = "github:hyprwm/Hyprland";
home-manager = { home-manager = {
url = "github:nix-community/home-manager/release-25.05"; url = "github:nix-community/home-manager/release-25.05";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
}; split-monitor-workspaces = {
type = "github";
outputs = { self, nixpkgs, home-manager, ... }@inputs: { owner = "zjeffer";
nixosConfigurations.haskell = nixpkgs.lib.nixosSystem { repo = "split-monitor-workspaces";
system = "x86_64-linux"; ref = "feat/zjeffer/lua";
specialArgs = { inherit inputs; }; inputs.hyprland.follows = "hyprland";
modules = [
./configuration.nix
home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.allen = import ./home.nix;
}
];
}; };
}; };
outputs =
{
self,
nixpkgs,
home-manager,
split-monitor-workspaces,
...
}@inputs:
let
system = "x86_64-linux";
pkgs = import nixpkgs {
inherit system;
config.allowUnfree = true;
};
in
{
nixosConfigurations.haskell = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
specialArgs = { inherit inputs; };
modules = [
./configuration.nix
(
{ pkgs, ... }:
{
# Define the overlay inline or in a separate file
nixpkgs.overlays = [
(final: prev: {
openmodelica = final.callPackage ./nixpkgs/openmodelica.nix { };
})
];
}
)
home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.allen = import ./home.nix {
inherit split-monitor-workspaces;
inherit inputs;
inherit pkgs;
};
}
];
};
};
} }

View File

@@ -4,11 +4,10 @@
{ config, lib, pkgs, modulesPath, ... }: { config, lib, pkgs, modulesPath, ... }:
{ {
imports = imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
[ (modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [ "xhci_pci" "thunderbolt" "nvme" "usb_storage" "sd_mod" ]; boot.initrd.availableKernelModules =
[ "xhci_pci" "thunderbolt" "nvme" "usb_storage" "sd_mod" ];
boot.initrd.kernelModules = [ ]; boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" ]; boot.kernelModules = [ "kvm-intel" ];
boot.kernelParams = [ "quiet" "modprobe.blacklist=dvb_usb_rtl28xxu" ]; boot.kernelParams = [ "quiet" "modprobe.blacklist=dvb_usb_rtl28xxu" ];
@@ -20,26 +19,28 @@
options = [ "size=8G" "mode=1777" ]; options = [ "size=8G" "mode=1777" ];
}; };
fileSystems."/" = fileSystems."/" = {
{ device = "/dev/disk/by-uuid/f4bf5b26-3959-4087-ad60-b5eaaf9c7cd5"; device = "/dev/disk/by-uuid/f4bf5b26-3959-4087-ad60-b5eaaf9c7cd5";
fsType = "ext4"; fsType = "ext4";
}; };
boot.initrd.luks.devices."luks-28e5a617-073a-4385-9fc2-f0620a8ead08".device = "/dev/disk/by-uuid/28e5a617-073a-4385-9fc2-f0620a8ead08"; boot.initrd.luks.devices."luks-28e5a617-073a-4385-9fc2-f0620a8ead08".device =
"/dev/disk/by-uuid/28e5a617-073a-4385-9fc2-f0620a8ead08";
fileSystems."/boot" = fileSystems."/boot" = {
{ device = "/dev/disk/by-uuid/40B6-4877"; device = "/dev/disk/by-uuid/40B6-4877";
fsType = "vfat"; fsType = "vfat";
options = [ "fmask=0077" "dmask=0077" ]; options = [ "fmask=0077" "dmask=0077" ];
}; };
fileSystems."/mnt/share" = fileSystems."/mnt/share" = {
{ device = "/dev/disk/by-uuid/0D608CA53E06CE7A"; device = "/dev/disk/by-uuid/0D608CA53E06CE7A";
fsType = "ntfs-3g"; fsType = "ntfs-3g";
options = [ "rw" "uid=1000" "gid=100" "umask=022" ]; options = [ "rw" "uid=1000" "gid=100" "umask=022" ];
}; };
swapDevices = [ ]; swapDevices = [{ device = "/dev/disk/by-label/nix-swap"; }];
boot.resumeDevice = "/dev/disk/by-label/nix-swap";
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking # Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's # (the default) this is the recommended approach. When using systemd-networkd it's
@@ -51,5 +52,6 @@
services.udev.packages = [ pkgs.rtl-sdr ]; services.udev.packages = [ pkgs.rtl-sdr ];
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; hardware.cpu.intel.updateMicrocode =
lib.mkDefault config.hardware.enableRedistributableFirmware;
} }

View File

@@ -1,4 +1,9 @@
{ config, pkgs, ... }: {
inputs,
split-monitor-workspaces,
pkgs,
...
}:
{ {
imports = [ imports = [
@@ -19,20 +24,37 @@
"Xft.dpi" = 172; "Xft.dpi" = 172;
}; };
home.packages = let home.packages =
fonts = import ./pkgs/fonts.nix { inherit pkgs; }; let
minecraft = import ./pkgs/minecraft.nix { inherit pkgs; }; fonts = import ./pkgs/fonts.nix { inherit pkgs; };
misc = import ./pkgs/misc.nix { inherit pkgs; }; minecraft = import ./pkgs/minecraft.nix { inherit pkgs; };
network = import ./pkgs/network.nix { inherit pkgs; }; misc = import ./pkgs/misc.nix { inherit pkgs; };
programming = import ./pkgs/programming.nix { inherit pkgs; }; network = import ./pkgs/network.nix { inherit pkgs; };
tools = import ./pkgs/tools.nix { inherit pkgs; }; programming = import ./pkgs/programming.nix { inherit pkgs; };
util = import ./pkgs/util.nix { inherit pkgs; }; tools = import ./pkgs/tools.nix { inherit pkgs; };
games = import ./pkgs/games.nix { inherit pkgs; }; util = import ./pkgs/util.nix { inherit pkgs; };
in fonts ++ minecraft ++ misc ++ network ++ programming ++ tools ++ util games = import ./pkgs/games.nix { inherit pkgs; };
++ games; in
fonts ++ minecraft ++ misc ++ network ++ programming ++ tools ++ util ++ games;
programs.direnv.enable = true; programs.direnv.enable = true;
programs.direnv.nix-direnv.enable = true; programs.direnv.nix-direnv.enable = true;
xdg.configFile."hypr/generated.lua".text =
let
smw =
inputs.split-monitor-workspaces.packages.${pkgs.stdenv.hostPlatform.system}.split-monitor-workspaces;
in
''
hl.plugin.load("${smw}/lib/libsplit-monitor-workspaces.so")
require("device.laptop")
'';
wayland.windowManager.hyprland = {
enable = true;
xwayland.enable = true;
package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland;
};
home.stateVersion = "25.05"; home.stateVersion = "25.05";
} }

View File

@@ -7,14 +7,10 @@
font = { size = 14; }; font = { size = 14; };
window = { window = {
opacity = 1.0; opacity = 1.0;
padding.x = 50; padding.x = 7;
padding.y = 50; padding.y = 7;
};
colors = {
primary = {
background = "#040404";
};
}; };
colors = { primary = { background = "#040404"; }; };
scrolling.multiplier = 5; scrolling.multiplier = 5;
selection.save_to_clipboard = true; selection.save_to_clipboard = true;
}; };

95
nixpkgs/openmodelica.nix Normal file
View File

@@ -0,0 +1,95 @@
{
pkgs ? import <nixpkgs> { },
}:
let
desktopItem = pkgs.makeDesktopItem {
name = "openmodelica";
desktopName = "OpenModelica Connection Editor";
exec = "OMEdit";
icon = "openmodelica";
categories = [
"Development"
"Science"
"Education"
];
comment = "Modelica-based modeling and simulation environment";
};
in
with pkgs;
stdenv.mkDerivation {
name = "openmodelica-bin";
version = "custom";
src = pkgs.fetchgit {
url = "https://github.com/OpenModelica/OpenModelica.git";
rev = "959f964dadf1b928f03e3c2f74b8f816f95df1ef";
fetchSubmodules = true;
sha256 = "sha256-3rFIrg7+t/eX2mq21v9AcYhV3Adloa8Sae9uRGtbyrY=";
};
nativeBuildInputs = with pkgs; [
cmake
gfortran
pkg-config
qt6.wrapQtAppsHook
autoPatchelfHook
flex
autoconf
automake
libtool
ninja
];
configurePhase = ''
cmake -S . -B build_cmake -GNinja -DOM_USE_CCACHE=OFF -DCMAKE_INSTALL_LIBDIR=lib -DCMAKE_INSTALL_PREFIX=$out
'';
buildPhase = ''
cmake --build build_cmake --parallel $NIX_BUILD_CORES --target install
'';
installPhase = ''
cmake --install build_cmake --prefix $out
runHook postInstall
'';
postInstall = ''
if [ -d "$out/lib64" ]; then
mkdir -p $out/lib
cp -rn $out/lib64/* $out/lib/
rm -rf $out/lib64
fi
mkdir -p $out/share/applications
cp ${desktopItem}/share/applications/* $out/share/applications/
# If you have an icon file in your source, install it too
# mkdir -p $out/share/icons/hicolor/scalable/apps
# cp $src/path/to/icon.svg $out/share/icons/hicolor/scalable/apps/openmodelica.svg
'';
buildInputs = with pkgs; [
# Compilers and Build Tools
# Dependencies
boost
hwloc
jdk
lapack
blas
hdf5
expat
omniorb
curl
ncurses
readline
openscenegraph
qt6.qt5compat
qt6.qtbase
qt6.qtwebengine
qt6.qtdeclarative
qt6.qttools
lapack-reference
];
}

View File

@@ -72,4 +72,9 @@ with pkgs; [
gptfdisk gptfdisk
openocd openocd
probe-rs-tools probe-rs-tools
cachix
hyprpolkitagent
mako
parted
efibootmgr
] ]

View File

@@ -1 +1,7 @@
{ inputs, pkgs, ... }: { programs.hyprland = { enable = true; }; } { inputs, pkgs, ... }:
{
programs.hyprland = {
enable = true;
package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland;
};
}

View File

@@ -1,6 +1,6 @@
# X display system config # X display system config
{ ... }: { { pkgs, ... }: {
hardware.graphics.enable = true; hardware.graphics.enable = true;
services.xserver.enable = true; services.xserver.enable = true;
services.xserver.wacom.enable = true; services.xserver.wacom.enable = true;
@@ -11,6 +11,15 @@
user = "allen"; user = "allen";
}; };
xdg.portal = {
enable = true;
extraPortals = with pkgs; [
xdg-desktop-portal-gtk
xdg-desktop-portal-gnome
];
config.common.default = "*";
};
services.xserver.desktopManager.gnome.enable = true; services.xserver.desktopManager.gnome.enable = true;
services.xserver.xkb.layout = "us"; services.xserver.xkb.layout = "us";
} }