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-09-05 09:14:06 +04:00
|
|
|
|
outputs.nixosModules.work
|
2023-08-31 13:35:16 +04:00
|
|
|
|
outputs.nixosModules.security
|
2023-08-07 17:28:33 +04:00
|
|
|
|
];
|
2023-08-08 11:21:47 +04:00
|
|
|
|
|
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;
|
|
|
|
|
|
2023-08-25 21:21:17 +04:00
|
|
|
|
time.timeZone = "Asia/Dubai";
|
2023-08-07 17:28:33 +04:00
|
|
|
|
|
|
|
|
|
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-10-18 15:13:54 +04:00
|
|
|
|
services.xserver.xkbOptions = "grp:alt_shift_toggle, ctrl:swapcaps";
|
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.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;
|
2023-12-24 14:44:12 +04:00
|
|
|
|
pinentryFlavor = "gtk2";
|
2023-08-07 17:28:33 +04:00
|
|
|
|
# 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
|
|
|
|
};
|
|
|
|
|
|
2023-09-13 15:24:53 +04:00
|
|
|
|
# read stable version patch notes and fix any issues
|
|
|
|
|
# then you can change this
|
2023-12-03 14:16:32 +04:00
|
|
|
|
#system.stateVersion = "23.05";
|
2023-08-07 17:28:33 +04:00
|
|
|
|
# read comment you read the comment?
|
|
|
|
|
}
|