nixos-config/modules/desktop.nix

211 lines
5.4 KiB
Nix
Raw Normal View History

2023-04-14 23:51:52 +03:00
# Window Manager and desktop programs
{ config, lib, pkgs, ... }:
let
2023-11-03 11:09:19 +03:00
# unstableTarball =
# fetchTarball
# https://github.com/NixOS/nixpkgs/archive/nixos-unstable.tar.gz;
2023-04-14 23:51:52 +03:00
in
{
sound.enable = true;
hardware.pulseaudio.enable = false;
security.rtkit.enable = true;
services = {
# sonarr = {
# enable = true;
# openFirewall = true; # http://locahost:8989
# };
# prowlarr = {
# enable = true;
# openFirewall = true; # http://locahost:9696
# };
#blueman.enable = true;
#openvpn.restartAfterSleep = false;
2023-06-19 15:52:25 +03:00
openvpn.servers = {
2023-11-03 11:09:19 +03:00
arn = {
config = '' config /home/mrflos/Nextcloud/vpn\ ARN/2023/vpn510.conf '';
autoStart = false;
};
2023-06-19 15:52:25 +03:00
};
2023-04-14 23:51:52 +03:00
pipewire = {
enable = true;
alsa.enable = true;
alsa.support32Bit = true;
pulse.enable = true;
# If you want to use JACK applications, uncomment this
#jack.enable = true;
# use the example session manager (no others are packaged yet so this is enabled by default,
# no need to redefine it in your config for now)
#media-session.enable = true;
};
printing.enable = true; # Enable CUPS to print documents.
2023-11-03 11:09:19 +03:00
printing.drivers = [ pkgs.brlaser ];
2023-04-14 23:51:52 +03:00
xserver = {
enable = true;
2023-11-03 11:09:19 +03:00
displayManager.defaultSession = "plasmawayland";
desktopManager.plasma5.enable = true;
displayManager.sddm.enable = true;
2023-11-03 11:09:19 +03:00
displayManager.sddm.enableHidpi = true;
2023-04-14 23:51:52 +03:00
};
2023-11-03 11:09:19 +03:00
dbus.enable = true;
2023-04-14 23:51:52 +03:00
};
programs = {
chromium = {
enable = true;
homepageLocation = "about:blank";
2023-04-14 23:51:52 +03:00
extensions = [
"pejkokffkapolfffcgbmdmhdelanoaih" # Unsplash instant
"cjpalhdlnbpafiamejdnhcphjbkeiagm" # uBlock Origin
"gfapcejdoghpoidkfodoiiffaaibpaem" # Dracula theme
"jbbplnpkjmmeebjpijfedlgcdilocofh" # wave a11y
];
extraOpts = {
SpellcheckEnabled = true;
SpellcheckLanguage = [
"fr-FR"
"en-GB"
"ru"
];
};
};
droidcam.enable = true;
firefox.enable = true;
2023-11-03 11:09:19 +03:00
firefox.languagePacks = ["fr"];
hyprland.enable = true;
ssh.askPassword = pkgs.lib.mkForce "${pkgs.ksshaskpass.out}/bin/ksshaskpass"; # conflict between kde and gnome cf. https://github.com/NixOS/nixpkgs/issues/75867
ssh.startAgent = true;
steam.enable = true;
2023-11-03 11:09:19 +03:00
sway = {
enable = true;
wrapperFeatures.gtk = true; # so that gtk works properly
extraPackages = with pkgs; [
swaylock
swayidle
wl-clipboard
wf-recorder
mako # notification daemon
grim
slurp
alacritty # Alacritty is the default terminal in the config
dmenu # Dmenu is the default in the config but i recommend wofi since its wayland native
];
extraSessionCommands = ''
export SDL_VIDEODRIVER=wayland
export QT_QPA_PLATFORM=wayland
export QT_WAYLAND_DISABLE_WINDOWDECORATION="1"
export _JAVA_AWT_WM_NONREPARENTING=1
export MOZ_ENABLE_WAYLAND=1
'';
};
};
2023-04-14 23:51:52 +03:00
# Allow unfree packages
nixpkgs.config.allowUnfree = true;
# access to unstable nixpkgs
2023-08-13 19:18:11 +03:00
# nixpkgs.config = {
# packageOverrides = pkgs: with pkgs; {
# unstable = import unstableTarball {
# config = config.nixpkgs.config;
# };
# };
# };
# no kde bloat
2023-06-19 15:52:25 +03:00
environment.plasma5.excludePackages = with pkgs.libsForQt5; [
baloo
2023-06-19 15:52:25 +03:00
elisa
gwenview
khelpcenter
oxygen
2023-06-19 15:52:25 +03:00
plasma-browser-integration
];
2023-04-14 23:51:52 +03:00
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
(vscode-with-extensions.override {
vscode = vscodium;
vscodeExtensions = with vscode-extensions; [
2023-08-13 19:18:11 +03:00
bmewburn.vscode-intelephense-client
2023-04-14 23:51:52 +03:00
dracula-theme.theme-dracula
mvllow.rose-pine
2023-11-03 11:09:19 +03:00
editorconfig.editorconfig
esbenp.prettier-vscode
github.github-vscode-theme
gruntfuggly.todo-tree
2023-08-13 19:18:11 +03:00
jnoortheen.nix-ide
2023-06-19 15:52:25 +03:00
mhutchie.git-graph
2023-08-13 19:18:11 +03:00
ms-ceintl.vscode-language-pack-fr
2023-11-03 11:09:19 +03:00
#junstyle.php-cs-fixer
#ms-vscode-remote.remote-ssh
2023-08-13 19:18:11 +03:00
]
++ pkgs.vscode-utils.extensionsFromVscodeMarketplace [
{
2023-11-03 11:09:19 +03:00
name = "vscode-twig-language-2";
2023-08-13 19:18:11 +03:00
publisher = "mblode";
2023-11-03 11:09:19 +03:00
version = "0.9.2";
2023-08-13 19:18:11 +03:00
sha256 = "113w2iis4zi4z3sqc3vd2apyrh52hbh2gvmxjr5yvjpmrsksclbd";
}
]
;
2023-04-14 23:51:52 +03:00
})
(chromium.override {
enableWideVine = true; # DRM support
})
2023-11-03 11:09:19 +03:00
audacious
2023-04-14 23:51:52 +03:00
bitwarden
calibre
2023-06-19 15:52:25 +03:00
digikam
dracula-theme
numix-cursor-theme
papirus-icon-theme
2023-04-14 23:51:52 +03:00
element-desktop
filezilla
gimp-with-plugins
2023-11-03 11:09:19 +03:00
hunspell
hunspellDicts.fr-moderne
hyprpaper
2023-04-14 23:51:52 +03:00
inkscape-with-extensions
2023-06-19 15:52:25 +03:00
joplin-desktop
kitty
kitty-themes
2023-08-13 19:18:11 +03:00
latte-dock
2023-11-03 11:09:19 +03:00
libreoffice-qt
librewolf
2023-04-14 23:51:52 +03:00
libsForQt5.ark
libsForQt5.bismuth
2023-11-03 11:09:19 +03:00
#mattermost-desktop
mixxx
2023-04-14 23:51:52 +03:00
nextcloud-client
2023-06-19 15:52:25 +03:00
obsidian
2023-04-14 23:51:52 +03:00
signal-desktop
2023-11-03 11:09:19 +03:00
tdesktop # strange name for telegram client
2023-08-13 19:18:11 +03:00
thunderbird
2023-11-03 11:09:19 +03:00
tor-browser-bundle-bin
2023-06-19 15:52:25 +03:00
transmission-qt
2023-04-14 23:51:52 +03:00
vlc
2023-11-03 11:09:19 +03:00
waybar
wl-clipboard
wofi
mako # notification system developed by swaywm maintainer
wdisplays # tool to configure displays
2023-04-14 23:51:52 +03:00
];
# Do not restart the display manager automatically
systemd.services.display-manager.restartIfChanged = lib.mkForce false;
# If something needs more than 20s to stop it should probably be
# killed.
systemd.extraConfig = ''
DefaultTimeoutStopSec=20s
'';
}