nixos/default.nix

139 lines
3.3 KiB
Nix
Raw Normal View History

2023-08-07 17:28:33 +04:00
{
2023-08-08 11:21:47 +04:00
config,
inputs,
outputs,
pkgs,
lib,
home-manager,
...
}: {
2023-08-07 17:28:33 +04:00
imports = [
# home manager
inputs.home-manager.nixosModules.default
# modules
# import for each folder
# modules/desktop IMPORT
2023-08-08 11:21:47 +04:00
# modules/desktop/example DO NOT IMPORT,
2023-08-07 17:28:33 +04:00
# add entry to module's default.nix
outputs.nixosModules.desktop
outputs.nixosModules.shell
outputs.nixosModules.hardware
outputs.nixosModules.dev
outputs.nixosModules.media
];
2023-08-08 11:21:47 +04:00
2023-08-18 16:26:55 +04:00
# just incase
nixpkgs.config.allowUnfree = true;
2023-08-07 17:28:33 +04:00
# flakes
2023-08-08 11:21:47 +04:00
nix.settings.experimental-features = ["nix-command" "flakes"];
2023-08-07 17:28:33 +04:00
# import the overlays
nixpkgs = {
2023-08-08 11:21:47 +04:00
overlays = [
outputs.overlays.additions
outputs.overlays.modifications
outputs.overlays.unstable-packages
];
};
2023-08-07 17:28:33 +04:00
# grub (mount efi partition to /boot/efi)
# why /boot/efi? instead of /efi?
# 1. when dualbooting, windows makes the efi partition 100mb instead of 512mb+ (we need this for generations
# and intel microcode)
# 2. nixos does not like /efi :(
# 3. i dont like systemd boot D:
2023-08-08 11:21:47 +04:00
# TODO(sako):: add shim secure boot
2023-08-07 17:28:33 +04:00
# because window and riot games devs :(
boot.loader = {
efi = {
canTouchEfiVariables = true;
efiSysMountPoint = "/boot/efi";
};
grub = {
2023-08-08 11:21:47 +04:00
devices = ["nodev"];
2023-08-07 17:28:33 +04:00
efiSupport = true;
enable = true;
useOSProber = true;
configurationLimit = 10;
};
};
# this shouldnt cause any issues right?
networking.networkmanager.enable = true;
time.timeZone = "Africa/Cairo";
i18n.defaultLocale = "en_US.UTF-8";
console = {
font = "Lat2-Terminus16";
# keyMap = "us";
2023-08-08 11:21:47 +04:00
# use xorg layout option
2023-08-07 17:28:33 +04:00
# TODO(sako):: add arabic locale
useXkbConfig = true;
};
# xorg layout
# change to needed
2023-08-08 11:21:47 +04:00
services.xserver.layout = "us,ar";
2023-08-08 11:26:02 +04:00
services.xserver.xkbOptions = "grp:alt_shift_toggle";
2023-08-07 17:28:33 +04:00
# already sold soul to corporations \_o_/
nixpkgs.config.allowUnfree = true;
2023-08-09 23:02:37 +04:00
users.users.sako = {
isNormalUser = true;
extraGroups = ["wheel" "networkmanager"]; # Enable sudo for the user.
};
2023-08-07 17:28:33 +04:00
home-manager.useUserPackages = true;
2023-08-08 11:21:47 +04:00
home-manager.users.sako = {pkgs, ...}: {
# CHANGE THIS WHEN THE SYSTEM VERSION CHANGES TOO!!!
home.stateVersion = "23.05";
home.packages = [];
home.username = "sako";
home.homeDirectory = "/home/sako";
programs.bash.enable = true;
programs.home-manager.enable = true;
xdg.configFile.git = {
source = ./config/git;
};
2023-08-07 17:28:33 +04:00
};
# bare minimum
environment.systemPackages = with pkgs; [
vim # backup
wget #double u get
killall # die processes
alsa-utils # unsupported application
pulseaudio # unsupported application
pamixer # unsupported application
feh # im different
unzip # zip file
gh # github
htop # htop
tree # trees
2023-08-08 11:21:47 +04:00
];
2023-08-07 17:28:33 +04:00
# you phisiclally cannot live without this
2023-08-08 11:21:47 +04:00
# litearlly! ! ! ! ! !
2023-08-07 17:28:33 +04:00
programs.gnupg.agent = {
enable = true;
pinentryFlavor = "gtk2";
# enableSSHSupport = true;
};
programs.git = {
2023-08-08 11:21:47 +04:00
enable = true;
package = pkgs.gitFull;
2023-08-07 17:28:33 +04:00
};
# something nixos release
# something use ful in for mat ion
# blah blah blah
# nixos packages type shit
# change this on every update idiot
# dont name it to string beans or some shit
# you idiot
2023-08-08 11:21:47 +04:00
system.stateVersion = "23.05";
2023-08-07 17:28:33 +04:00
# read comment you read the comment?
}