2023-10-29 21:50:52 +00:00
|
|
|
# Edit this configuration file to define what should be installed on
|
|
|
|
# your system. Help is available in the configuration.nix(5) man page
|
|
|
|
# and in the NixOS manual (accessible by running `nixos-help`).
|
|
|
|
|
|
|
|
{ config, pkgs, ... }:
|
|
|
|
|
|
|
|
{
|
|
|
|
imports =
|
|
|
|
[ # Include the results of the hardware scan.
|
|
|
|
./hardware-configuration.nix
|
|
|
|
./laptop.nix
|
|
|
|
./services.nix
|
|
|
|
./gnome.nix
|
|
|
|
./extra_hw.nix
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
|
|
# Use the systemd-boot EFI boot loader.
|
|
|
|
boot = {
|
|
|
|
loader.systemd-boot.enable = true;
|
|
|
|
loader.efi.canTouchEfiVariables = true;
|
|
|
|
loader.grub.efiSupport = true;
|
|
|
|
loader.grub.efiInstallAsRemovable = true;
|
|
|
|
loader.grub.device = "nodev";
|
|
|
|
plymouth.enable = true;
|
|
|
|
tmp.cleanOnBoot = true ;
|
|
|
|
kernelParams = [ "i915.enable_fbc=1" ];
|
|
|
|
};
|
|
|
|
|
|
|
|
networking = {
|
|
|
|
hostName = "lap2nix";
|
|
|
|
networkmanager.enable = true;
|
|
|
|
firewall.enable = true;
|
|
|
|
};
|
|
|
|
|
|
|
|
time.timeZone = "Europe/Paris";
|
|
|
|
|
|
|
|
|
|
|
|
# Select internationalisation properties.
|
|
|
|
i18n.defaultLocale = "fr_FR.UTF-8";
|
|
|
|
console = {
|
|
|
|
font = "Lat2-Terminus16";
|
|
|
|
keyMap = "fr";
|
|
|
|
};
|
|
|
|
|
|
|
|
fonts = {
|
|
|
|
fontDir.enable = true;
|
|
|
|
enableGhostscriptFonts = true;
|
|
|
|
fonts = with pkgs; [
|
|
|
|
corefonts
|
|
|
|
vistafonts
|
|
|
|
powerline-fonts
|
|
|
|
inconsolata
|
|
|
|
terminus_font
|
|
|
|
proggyfonts
|
|
|
|
dejavu_fonts
|
|
|
|
font-awesome
|
|
|
|
nerdfonts
|
|
|
|
source-code-pro
|
|
|
|
source-sans-pro
|
|
|
|
source-serif-pro
|
|
|
|
iosevka
|
|
|
|
roboto-mono
|
|
|
|
fira-code
|
|
|
|
];
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
# Enable the X11 windowing system.
|
|
|
|
services.xserver.enable = true;
|
|
|
|
|
|
|
|
|
|
|
|
# Enable the GNOME Desktop Environment.
|
|
|
|
services.xserver.displayManager.gdm.enable = true;
|
|
|
|
services.xserver.desktopManager.gnome.enable = true;
|
|
|
|
|
|
|
|
users = {
|
|
|
|
groups.ntp = {};
|
|
|
|
defaultUserShell = "/run/current-system/sw/bin/fish";
|
|
|
|
extraUsers.alexandre = {
|
|
|
|
isNormalUser = true;
|
|
|
|
home = "/home/alexandre";
|
|
|
|
description = "alexandre";
|
|
|
|
extraGroups = [ "wheel" "networkmanager" "docker" "libvirtd" "scanner" "plocate" "lp" ];
|
|
|
|
packages = with pkgs; [
|
|
|
|
firefox
|
|
|
|
gitAndTools.gitFull
|
|
|
|
];
|
|
|
|
};
|
|
|
|
extraUsers.oem = {
|
|
|
|
isNormalUser = true;
|
|
|
|
home = "/home/oem";
|
|
|
|
description = "oem";
|
|
|
|
extraGroups = [ "wheel" "networkmanager" ];
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
environment.variables = {
|
|
|
|
EDITOR = "nvim";
|
|
|
|
BROWSER = "firefox";
|
|
|
|
LESS = "--quit-if-one-screen --RAW-CONTROL-CHARS";
|
|
|
|
TERMINAL = "xfce4-terminal";
|
|
|
|
PRIVATE_BROWSER = "firefox -private";
|
|
|
|
};
|
|
|
|
|
|
|
|
security = {
|
|
|
|
rtkit.enable = true; # for pipewire
|
|
|
|
apparmor.enable = true;
|
|
|
|
pam = {
|
|
|
|
u2f = {
|
|
|
|
enable = true;
|
|
|
|
control = "requisite";
|
|
|
|
};
|
|
|
|
services = {
|
|
|
|
login.u2fAuth = true;
|
|
|
|
lightdm.u2fAuth = true;
|
|
|
|
gdm.u2fAuth = true;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
|
|
|
|
|
|
|
nixpkgs.config = {
|
|
|
|
allowUnfree = true;
|
|
|
|
};
|
|
|
|
|
|
|
|
environment.systemPackages = with pkgs; [
|
|
|
|
neovim
|
|
|
|
bat
|
|
|
|
lsd
|
|
|
|
pam_u2f
|
|
|
|
gsmartcontrol
|
|
|
|
lm_sensors
|
|
|
|
];
|
|
|
|
|
|
|
|
nix.settings.auto-optimise-store = true;
|
|
|
|
nix.gc = {
|
|
|
|
automatic = true;
|
|
|
|
dates = "weekly";
|
|
|
|
persistent = true;
|
|
|
|
options = "--delete-older-than 10d";
|
|
|
|
};
|
|
|
|
|
2023-10-31 14:50:40 +00:00
|
|
|
programs.hyprland.enable = true;
|
2023-10-29 21:50:52 +00:00
|
|
|
programs = {
|
|
|
|
htop = {
|
|
|
|
enable = true;
|
|
|
|
settings.show_cpu_temperature = 1;
|
|
|
|
};
|
|
|
|
fish = {
|
|
|
|
enable = true;
|
|
|
|
interactiveShellInit = ''
|
|
|
|
set -gx EDITOR nvim
|
|
|
|
'';
|
|
|
|
shellAliases = {
|
|
|
|
ll = "ls -l";
|
|
|
|
ls = "lsd";
|
|
|
|
cat = "bat";
|
|
|
|
sysrs = "sudo nixos-rebuild switch";
|
|
|
|
sysup = "sudo nixos-rebuild switch --upgrade";
|
|
|
|
sysclean = "sudo nix-collect-garbage -d; and sudo nix-store --optimise";
|
|
|
|
# nvim = "nvim -u ~/.config/nvim/init.lua";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
system.stateVersion = "23.05"; # Did you read the comment?
|
|
|
|
|
|
|
|
nixpkgs.config.packageOverrides = pkgs: {
|
|
|
|
nur = import (builtins.fetchTarball "https://github.com/nix-community/NUR/archive/master.tar.gz") {
|
|
|
|
inherit pkgs;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|
|
|
|
|