mirror of
https://github.com/tomasriveral/nixos.git
synced 2026-08-12 10:30:44 +02:00
dendritic: rewrote entire config
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
{ ... }: {
|
||||
flake.nixosModules.IO = {pkgs, ...}: {
|
||||
# Configure keymap in X11
|
||||
services.xserver.xkb = {
|
||||
layout = "ch";
|
||||
variant = "fr";
|
||||
};
|
||||
|
||||
# Configure console keymap
|
||||
console.keyMap = "fr_CH";
|
||||
|
||||
# Enable touchpad support (enabled default in most desktopManager).
|
||||
# services.xserver.libinput.enable = true;
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
wl-clipboard
|
||||
cliphist
|
||||
hyprkeys # keybind helper
|
||||
hyprpicker
|
||||
];
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
{ ... }: {
|
||||
flake.homeModules.cursor = {pkgs, ...}: {
|
||||
home.pointerCursor = {
|
||||
hyprcursor.enable = true;
|
||||
enable = true;
|
||||
package = pkgs.capitaine-cursors-themed;
|
||||
name = "Capitaine Cursors (Gruvbox)";
|
||||
size = 32;
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,31 @@
|
||||
{ ... }: {
|
||||
flake.homeModules.desktopEntries = { ... }: {
|
||||
# for when the system lacks of a .desktop file
|
||||
home.file.".local/share/applications/org.quickshell.desktop" = {
|
||||
enable = true;
|
||||
text = ''
|
||||
[Desktop Entry]
|
||||
Name=QuickShell
|
||||
Comment=QuickShell application
|
||||
Exec=quickshell
|
||||
Icon=utilities-terminal
|
||||
Type=Application
|
||||
Categories=Utility;
|
||||
StartupNotify=true
|
||||
X-DBUS-ServiceName=org.quickshell
|
||||
'';
|
||||
};
|
||||
home.file.".local/share/applications/org.kde.PrintQueue.desktop" = {
|
||||
enable = true;
|
||||
text = ''
|
||||
[Desktop Entry]
|
||||
Type=Application
|
||||
Name=Print Queue
|
||||
Exec=print-queue
|
||||
Icon=printer
|
||||
Categories=Utility;
|
||||
StartupNotify=true
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
{ ... }: {
|
||||
flake.nixosModules.fonts = { pkgs, ... }: {
|
||||
# fonts
|
||||
fonts.packages = with pkgs; [
|
||||
nerd-fonts._0xproto
|
||||
cinzel
|
||||
times-newer-roman
|
||||
];
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
gnome-font-viewer
|
||||
];
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
{ ... }: {
|
||||
flake.nixosModules.printer = {pkgs, ...}: {
|
||||
#https://wiki.nixos.org/wiki/Printing
|
||||
services.avahi = {
|
||||
enable = true;
|
||||
nssmdns4 = true;
|
||||
openFirewall = true;
|
||||
};
|
||||
|
||||
# Enable CUPS to print documents.
|
||||
services.printing = {
|
||||
enable = true;
|
||||
drivers = with pkgs; [
|
||||
cups-filters
|
||||
#cups-browsed
|
||||
#gutenprint
|
||||
#gutenprintBin
|
||||
hplipWithPlugin
|
||||
hplip
|
||||
];
|
||||
};
|
||||
services.ipp-usb.enable = true;
|
||||
environment.systemPackages = with pkgs; [
|
||||
kdePackages.print-manager
|
||||
ghostscript
|
||||
hplipWithPlugin
|
||||
];
|
||||
hardware.printers = {
|
||||
ensurePrinters = [
|
||||
{
|
||||
name = "HP_OfficeJet_Pro_7740";
|
||||
location = "Home";
|
||||
deviceUri = "hp:/usb/OfficeJet_Pro_7740_series";
|
||||
model = "drv:///hp/hpcups.drv/hp-officejet_pro_7740_series.ppd";
|
||||
}
|
||||
];
|
||||
|
||||
ensureDefaultPrinter = "HP_OfficeJet_Pro_7740";
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,50 @@
|
||||
{ ... }: {
|
||||
flake.nixModules.user = {
|
||||
pkgs,
|
||||
pkgs-unstable,
|
||||
...
|
||||
}: {
|
||||
services.dbus.enable = true;
|
||||
security.polkit.enable = true;
|
||||
|
||||
# Set your time zone.
|
||||
time.timeZone = "Europe/Zurich";
|
||||
|
||||
# Select internationalisation properties.
|
||||
i18n.defaultLocale = "en_US.UTF-8";
|
||||
|
||||
# zsh dont want to work if it is not initialzed here.
|
||||
programs.zsh.enable = true;
|
||||
|
||||
# Define a user account. Don't forget to set a password with ‘passwd’.
|
||||
users.users.tomasr = {
|
||||
isNormalUser = true;
|
||||
description = "Tomas Rivera";
|
||||
extraGroups = ["networkmanager" "wheel" "fuse"]; #wheel allow to use sudo / fuse -> rclone
|
||||
shell = pkgs.zsh;
|
||||
};
|
||||
|
||||
services.upower.enable = true;
|
||||
|
||||
# removes need for password for nixos-rebuild
|
||||
security.sudo.extraRules = [
|
||||
{
|
||||
users = ["tomasr"];
|
||||
commands = [
|
||||
{
|
||||
command = "/run/current-system/sw/bin/nixos-rebuild";
|
||||
options = ["NOPASSWD"];
|
||||
}
|
||||
{
|
||||
command = "${pkgs.nixos-rebuild}/bin/nixos-rebuild";
|
||||
options = ["NOPASSWD"];
|
||||
}
|
||||
{
|
||||
command = "${pkgs-unstable.nixos-rebuild}/bin/nixos-rebuild";
|
||||
options = ["NOPASSWD"];
|
||||
}
|
||||
];
|
||||
}
|
||||
];
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user