WIP
This commit is contained in:
49
flake.lock
generated
Normal file
49
flake.lock
generated
Normal file
@@ -0,0 +1,49 @@
|
|||||||
|
{
|
||||||
|
"nodes": {
|
||||||
|
"home-manager": {
|
||||||
|
"inputs": {
|
||||||
|
"nixpkgs": [
|
||||||
|
"nixpkgs"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1767910483,
|
||||||
|
"narHash": "sha256-MOU5YdVu4DVwuT5ztXgQpPuRRBjSjUGIdUzOQr9iQOY=",
|
||||||
|
"owner": "nix-community",
|
||||||
|
"repo": "home-manager",
|
||||||
|
"rev": "82fb7dedaad83e5e279127a38ef410bcfac6d77c",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nix-community",
|
||||||
|
"ref": "release-25.11",
|
||||||
|
"repo": "home-manager",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"nixpkgs": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1768028080,
|
||||||
|
"narHash": "sha256-50aDK+8eLvsLK39TzQhKNq50/HcXyP4hyxOYoPoVxjo=",
|
||||||
|
"owner": "nixos",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"rev": "d03088749a110d52a4739348f39a63f84bb0be14",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nixos",
|
||||||
|
"ref": "nixos-25.11",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"root": {
|
||||||
|
"inputs": {
|
||||||
|
"home-manager": "home-manager",
|
||||||
|
"nixpkgs": "nixpkgs"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"root": "root",
|
||||||
|
"version": 7
|
||||||
|
}
|
||||||
33
flake.nix
Normal file
33
flake.nix
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
{
|
||||||
|
description = "Weckyy702's (hopefully nice) NixOS config";
|
||||||
|
|
||||||
|
inputs = {
|
||||||
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-25.11";
|
||||||
|
home-manager.url = "github:nix-community/home-manager/release-25.11";
|
||||||
|
home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
#TODO: nixvim, etc
|
||||||
|
};
|
||||||
|
|
||||||
|
outputs = { self, nixpkgs, home-manager, ... }@inputs: {
|
||||||
|
nixosConfigurations.keith =
|
||||||
|
let
|
||||||
|
hostname = "keith";
|
||||||
|
username = "weckyy702";
|
||||||
|
specialArgs = { inherit inputs; inherit hostname; inherit username; };
|
||||||
|
in
|
||||||
|
nixpkgs.lib.nixosSystem {
|
||||||
|
inherit specialArgs;
|
||||||
|
modules = [
|
||||||
|
./hosts/keith
|
||||||
|
./users/${username}/nixos.nix
|
||||||
|
home-manager.nixosModules.home-manager {
|
||||||
|
home-manager.useGlobalPkgs = true;
|
||||||
|
home-manager.useUserPackages = true;
|
||||||
|
|
||||||
|
home-manager.extraSpecialArgs = specialArgs;
|
||||||
|
home-manager.users.${username} = import ./users/${username}/home.nix;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
10
home-manager/core.nix
Normal file
10
home-manager/core.nix
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
{username, ...}: {
|
||||||
|
home = {
|
||||||
|
inherit username;
|
||||||
|
homeDirectory = "/home/${username}";
|
||||||
|
|
||||||
|
stateVersion = "25.11";
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.home-manager.enable = true;
|
||||||
|
}
|
||||||
@@ -2,27 +2,22 @@
|
|||||||
# your system. Help is available in the configuration.nix(5) man page
|
# your system. Help is available in the configuration.nix(5) man page
|
||||||
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
||||||
|
|
||||||
{ config, pkgs, ... }:
|
{ config, pkgs, inputs, hostname, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
imports =
|
imports =
|
||||||
[ # Include the results of the hardware scan.
|
[ # Include the results of the hardware scan.
|
||||||
./hardware-configuration.nix
|
./hardware-configuration.nix
|
||||||
./../../nixos-modules/devtools.nix
|
];
|
||||||
./../../nixos-modules/desktop.nix
|
|
||||||
./../../nixos-modules/apps.nix
|
|
||||||
./../../homemanager-modules
|
|
||||||
];
|
|
||||||
|
|
||||||
# Bootloader.
|
# Bootloader.
|
||||||
boot.loader.grub.enable = true;
|
boot.loader.grub.enable = true;
|
||||||
boot.loader.grub.device = "/dev/nvme0n1";
|
boot.loader.grub.device = "/dev/nvme0n1";
|
||||||
boot.loader.grub.useOSProber = true;
|
|
||||||
|
|
||||||
# Use latest kernel.
|
# Use latest kernel.
|
||||||
boot.kernelPackages = pkgs.linuxPackages_latest;
|
boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||||
|
|
||||||
networking.hostName = "keith"; # Define your hostname.
|
networking.hostName = hostname; # Define your hostname.
|
||||||
# Enable networking
|
# Enable networking
|
||||||
networking.networkmanager.enable = true;
|
networking.networkmanager.enable = true;
|
||||||
|
|
||||||
@@ -53,7 +48,6 @@
|
|||||||
"nix-command"
|
"nix-command"
|
||||||
"flakes"
|
"flakes"
|
||||||
];
|
];
|
||||||
nix.settings.trusted-users = [ "weckyy702" ];
|
|
||||||
|
|
||||||
# Allow unfree packages
|
# Allow unfree packages
|
||||||
nixpkgs.config.allowUnfree = true;
|
nixpkgs.config.allowUnfree = true;
|
||||||
@@ -91,5 +85,4 @@
|
|||||||
# Before changing this value read the documentation for this option
|
# Before changing this value read the documentation for this option
|
||||||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
||||||
system.stateVersion = "25.11"; # Did you read the comment?
|
system.stateVersion = "25.11"; # Did you read the comment?
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
{config, pkgs, ... }: {
|
|
||||||
programs.steam = {
|
|
||||||
enable = true;
|
|
||||||
extest.enable = true;
|
|
||||||
protontricks.enable = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
{ config, pkgs, ...}: {
|
|
||||||
}
|
|
||||||
@@ -1,22 +0,0 @@
|
|||||||
{ config, pkgs, ...} : {
|
|
||||||
programs = {
|
|
||||||
neovim = {
|
|
||||||
enable = true;
|
|
||||||
defaultEditor = true;
|
|
||||||
};
|
|
||||||
git = {
|
|
||||||
enable = true;
|
|
||||||
config = {
|
|
||||||
init = {
|
|
||||||
defaultBranch = "main";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
ssh = {
|
|
||||||
enableAskPassword = true;
|
|
||||||
knownHosts = {
|
|
||||||
#TODO: gopher, ferris etc.
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
||||||
19
nixos/hypr.nix
Normal file
19
nixos/hypr.nix
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
{pkgs, username, ...}: {
|
||||||
|
|
||||||
|
# enable auto-login
|
||||||
|
#TODO: this should be optional
|
||||||
|
services.getty.autologinUser = username;
|
||||||
|
|
||||||
|
programs.hyprland = {
|
||||||
|
enable = true;
|
||||||
|
xwayland.enable = true;
|
||||||
|
withUWSM = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.hyprlock.enable = true;
|
||||||
|
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
kitty
|
||||||
|
hyprpaper
|
||||||
|
];
|
||||||
|
}
|
||||||
4
nixos/zsh.nix
Normal file
4
nixos/zsh.nix
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
{pkgs, username, ...}: {
|
||||||
|
programs.zsh.enable = true;
|
||||||
|
users.users.${username}.shell = pkgs.zsh;
|
||||||
|
}
|
||||||
24
users/weckyy702/home.nix
Normal file
24
users/weckyy702/home.nix
Normal file
@@ -0,0 +1,24 @@
|
|||||||
|
# home-manager config for weckyy702
|
||||||
|
{ pkgs, ...}: {
|
||||||
|
imports = [
|
||||||
|
../../home-manager/core.nix
|
||||||
|
|
||||||
|
#TODO: user programs
|
||||||
|
];
|
||||||
|
|
||||||
|
programs.zsh = {
|
||||||
|
enable = true;
|
||||||
|
|
||||||
|
# For autologin
|
||||||
|
profileExtra = ''
|
||||||
|
if [ -z "$WAYLAND_DISPLAY" ] && [ "$XDG_VTNR" = 1]; then
|
||||||
|
exec uwsm start -S hyprland-uwsm.desktop
|
||||||
|
fi
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.git.settings = {
|
||||||
|
name = "Weckyy702";
|
||||||
|
email = "konstvelt@gmail.com";
|
||||||
|
};
|
||||||
|
}
|
||||||
12
users/weckyy702/nixos.nix
Normal file
12
users/weckyy702/nixos.nix
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
{pkgs, ...}:
|
||||||
|
{
|
||||||
|
imports = [
|
||||||
|
../../nixos/zsh.nix
|
||||||
|
../../nixos/hypr.nix
|
||||||
|
];
|
||||||
|
|
||||||
|
users.users.weckyy702 = {
|
||||||
|
isNormalUser = true;
|
||||||
|
extraGroups = [ "networkmanager" "wheel" ];
|
||||||
|
};
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user