users: Add system.singleUser
This commit is contained in:
parent
3bf532866b
commit
97c6fece4c
@ -8,6 +8,7 @@ in {
|
|||||||
./generic.nix
|
./generic.nix
|
||||||
./modules/hardware/generic.nix ./modules/hardware/bluetooth.nix ./modules/hardware/wifi.nix ./modules/hardware/video.nix ./modules/hardware/mobile.nix
|
./modules/hardware/generic.nix ./modules/hardware/bluetooth.nix ./modules/hardware/wifi.nix ./modules/hardware/video.nix ./modules/hardware/mobile.nix
|
||||||
./modules/fonts.nix
|
./modules/fonts.nix
|
||||||
|
./modules/users
|
||||||
./modules/users/alexander.nix
|
./modules/users/alexander.nix
|
||||||
./modules/programs/zsh ./modules/programs/mpv ./modules/programs/git ./modules/programs/tmux ./modules/programs/firefox ./modules/programs/gnome-terminal ./modules/programs/gnome ./modules/programs/nonvm
|
./modules/programs/zsh ./modules/programs/mpv ./modules/programs/git ./modules/programs/tmux ./modules/programs/firefox ./modules/programs/gnome-terminal ./modules/programs/gnome ./modules/programs/nonvm
|
||||||
./modules/programs/distributed-build/offload.nix
|
./modules/programs/distributed-build/offload.nix
|
||||||
|
@ -11,6 +11,7 @@ in
|
|||||||
# Install home-manager
|
# Install home-manager
|
||||||
imports = [
|
imports = [
|
||||||
"${home-manager}/nixos"
|
"${home-manager}/nixos"
|
||||||
|
./modules/users # For system.singleUser
|
||||||
];
|
];
|
||||||
home-manager.useGlobalPkgs = true;
|
home-manager.useGlobalPkgs = true;
|
||||||
|
|
||||||
@ -67,8 +68,6 @@ in
|
|||||||
printing.enable = lib.mkDefault false;
|
printing.enable = lib.mkDefault false;
|
||||||
avahi.enable = false;
|
avahi.enable = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
documentation.nixos.enable = false;
|
|
||||||
|
|
||||||
security.sudo.extraConfig = ''
|
security.sudo.extraConfig = ''
|
||||||
Defaults env_keep += "NIXOS_CONFIG"
|
Defaults env_keep += "NIXOS_CONFIG"
|
||||||
|
2
miku.nix
2
miku.nix
@ -28,7 +28,7 @@ in {
|
|||||||
nur = (import ./modules/nur.nix pkgs);
|
nur = (import ./modules/nur.nix pkgs);
|
||||||
unstable = unstable;
|
unstable = unstable;
|
||||||
};
|
};
|
||||||
|
|
||||||
environment = {
|
environment = {
|
||||||
systemPackages = with pkgs; [
|
systemPackages = with pkgs; [
|
||||||
emacsPgtkGcc
|
emacsPgtkGcc
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
{ ... }:
|
{ config, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
home-manager.users.alexander.home.file = {
|
config.home-manager.users."${config.system.singleUser}".home.file = {
|
||||||
".emacs".source = ./dotemacs;
|
".emacs".source = ./dotemacs;
|
||||||
".emacs.d/early-init.el".source = ./early-init.el;
|
".emacs.d/early-init.el".source = ./early-init.el;
|
||||||
".emacs.d/mu4e.el".source = ./mu4e.el;
|
".emacs.d/mu4e.el".source = ./mu4e.el;
|
||||||
|
@ -1,134 +1,136 @@
|
|||||||
{ pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
environment = {
|
config = {
|
||||||
systemPackages = with pkgs; [ firefox-wayland tor-browser-bundle-bin ];
|
environment = {
|
||||||
|
systemPackages = with pkgs; [ firefox-wayland tor-browser-bundle-bin ];
|
||||||
|
|
||||||
# Deploy a Firefox policy to set the search engine and do some other things
|
# Deploy a Firefox policy to set the search engine and do some other things
|
||||||
etc."firefox/policies/policies.json".source = ./policies.json;
|
etc."firefox/policies/policies.json".source = ./policies.json;
|
||||||
|
|
||||||
variables = {
|
variables = {
|
||||||
# TODO: Use pam_environment once I figure out how to enable it.
|
# TODO: Use pam_environment once I figure out how to enable it.
|
||||||
# Enable multi-touch...
|
# Enable multi-touch...
|
||||||
"MOZ_USE_XINPUT2" = "1";
|
"MOZ_USE_XINPUT2" = "1";
|
||||||
# ... and Wayland
|
# ... and Wayland
|
||||||
"MOZ_USE_WAYLAND" = "1";
|
"MOZ_USE_WAYLAND" = "1";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
|
||||||
|
home-manager.users."${config.system.singleUser}".programs.firefox = {
|
||||||
home-manager.users.alexander.programs.firefox = {
|
enable = true;
|
||||||
enable = true;
|
extensions = with pkgs.nur.repos.rycee.firefox-addons; [
|
||||||
extensions = with pkgs.nur.repos.rycee.firefox-addons; [
|
https-everywhere
|
||||||
https-everywhere
|
ublock-origin
|
||||||
ublock-origin
|
umatrix
|
||||||
umatrix
|
decentraleyes
|
||||||
decentraleyes
|
privacy-redirect
|
||||||
privacy-redirect
|
];
|
||||||
];
|
profiles.default = {
|
||||||
profiles.default = {
|
id = 0; # NOTE: This is important
|
||||||
id = 0; # NOTE: This is important
|
isDefault = true;
|
||||||
isDefault = true;
|
name = "Default Profile";
|
||||||
name = "Default Profile";
|
settings = {
|
||||||
settings = {
|
"browser.search.suggest.enabled" = false;
|
||||||
"browser.search.suggest.enabled" = false;
|
"browser.tabs.drawInTitlebar" = true;
|
||||||
"browser.tabs.drawInTitlebar" = true;
|
"browser.aboutConfig.showWarning" = false;
|
||||||
"browser.aboutConfig.showWarning" = false;
|
"browser.crashReports.unsubmittedCheck.autoSubmit" = false;
|
||||||
"browser.crashReports.unsubmittedCheck.autoSubmit" = false;
|
"browser.crashReports.unsubmittedCheck.autoSubmit2" = false;
|
||||||
"browser.crashReports.unsubmittedCheck.autoSubmit2" = false;
|
"browser.crashReports.unsubmittedCheck.enabled" = false;
|
||||||
"browser.crashReports.unsubmittedCheck.enabled" = false;
|
"browser.newtabpage.activity-stream.section.highlights.includePocket" = false;
|
||||||
"browser.newtabpage.activity-stream.section.highlights.includePocket" = false;
|
"browser.newtabpage.activity-stream.feeds.topsites" = false;
|
||||||
"browser.newtabpage.activity-stream.feeds.topsites" = false;
|
"browser.newtabpage.activity-stream.improvesearch.topSiteSearchShortcuts" = false;
|
||||||
"browser.newtabpage.activity-stream.improvesearch.topSiteSearchShortcuts" = false;
|
"browser.newtabpage.enabled" = false;
|
||||||
"browser.newtabpage.enabled" = false;
|
"browser.newtabpage.enhanced" = false;
|
||||||
"browser.newtabpage.enhanced" = false;
|
"browser.newtabpage.introShown" = true;
|
||||||
"browser.newtabpage.introShown" = true;
|
"browser.send_pings" = false;
|
||||||
"browser.send_pings" = false;
|
"browser.shell.checkDefaultBrowser" = false; # NixOS is a bit wonky here
|
||||||
"browser.shell.checkDefaultBrowser" = false; # NixOS is a bit wonky here
|
"app.shield.optoutstudies.enabled" = false;
|
||||||
"app.shield.optoutstudies.enabled" = false;
|
"app.normandy.api_url" = "";
|
||||||
"app.normandy.api_url" = "";
|
"app.normandy.enabled" = false;
|
||||||
"app.normandy.enabled" = false;
|
"breakpad.reportURL" = "";
|
||||||
"breakpad.reportURL" = "";
|
"services.sync.prefs.sync.browser.newtabpage.activity-stream.showSponsoredTopSite" = false;
|
||||||
"services.sync.prefs.sync.browser.newtabpage.activity-stream.showSponsoredTopSite" = false;
|
"signon.autofillForms" = false;
|
||||||
"signon.autofillForms" = false;
|
"signon.rememberSignons" = false;
|
||||||
"signon.rememberSignons" = false;
|
"signon.management.page.breach-alerts.enabled" = false;
|
||||||
"signon.management.page.breach-alerts.enabled" = false;
|
"toolkit.telemetry.archive.enabled" = false;
|
||||||
"toolkit.telemetry.archive.enabled" = false;
|
"toolkit.telemetry.bhrPing.enabled" = false;
|
||||||
"toolkit.telemetry.bhrPing.enabled" = false;
|
"toolkit.telemetry.cachedClientID" = "";
|
||||||
"toolkit.telemetry.cachedClientID" = "";
|
"toolkit.telemetry.enabled" = false;
|
||||||
"toolkit.telemetry.enabled" = false;
|
"toolkit.telemetry.firstShutdownPing.enabled" = false;
|
||||||
"toolkit.telemetry.firstShutdownPing.enabled" = false;
|
"toolkit.telemetry.hybridContent.enabled" = false;
|
||||||
"toolkit.telemetry.hybridContent.enabled" = false;
|
"toolkit.telemetry.newProfilePing.enabled" = false;
|
||||||
"toolkit.telemetry.newProfilePing.enabled" = false;
|
"toolkit.telemetry.prompted" = 2;
|
||||||
"toolkit.telemetry.prompted" = 2;
|
"toolkit.telemetry.rejected" = true;
|
||||||
"toolkit.telemetry.rejected" = true;
|
"toolkit.telemetry.reportingpolicy.firstRun" = false;
|
||||||
"toolkit.telemetry.reportingpolicy.firstRun" = false;
|
"toolkit.telemetry.server" = "";
|
||||||
"toolkit.telemetry.server" = "";
|
"toolkit.telemetry.shutdownPingSender.enabled" = false;
|
||||||
"toolkit.telemetry.shutdownPingSender.enabled" = false;
|
"toolkit.telemetry.unified" = false;
|
||||||
"toolkit.telemetry.unified" = false;
|
"toolkit.telemetry.unifiedIsOptIn" = false;
|
||||||
"toolkit.telemetry.unifiedIsOptIn" = false;
|
"toolkit.telemetry.updatePing.enabled" = false;
|
||||||
"toolkit.telemetry.updatePing.enabled" = false;
|
"webgl.disabled" = true;
|
||||||
"webgl.disabled" = true;
|
"webgl.renderer-string-override" = " ";
|
||||||
"webgl.renderer-string-override" = " ";
|
"webgl.vendor-string-override" = " ";
|
||||||
"webgl.vendor-string-override" = " ";
|
"experiments.activeExperiment" = false;
|
||||||
"experiments.activeExperiment" = false;
|
"experiments.enabled" = false;
|
||||||
"experiments.enabled" = false;
|
"experiments.manifest.uri" = "";
|
||||||
"experiments.manifest.uri" = "";
|
"experiments.supported" = false;
|
||||||
"experiments.supported" = false;
|
"extensions.getAddons.cache.enabled" = false;
|
||||||
"extensions.getAddons.cache.enabled" = false;
|
"extensions.getAddons.showPane" = false;
|
||||||
"extensions.getAddons.showPane" = false;
|
"extensions.pocket.enabled" = false;
|
||||||
"extensions.pocket.enabled" = false;
|
"extensions.screenshots.upload-disabled" = true;
|
||||||
"extensions.screenshots.upload-disabled" = true;
|
"extensions.shield-recipe-client.api_url" = "";
|
||||||
"extensions.shield-recipe-client.api_url" = "";
|
"extensions.shield-recipe-client.enabled" = false;
|
||||||
"extensions.shield-recipe-client.enabled" = false;
|
"extensions.webservice.discoverURL" = "";
|
||||||
"extensions.webservice.discoverURL" = "";
|
"extensions.htmlaboutaddons.recommendations.enabled" = false;
|
||||||
"extensions.htmlaboutaddons.recommendations.enabled" = false;
|
"media.autoplay.default" = 2;
|
||||||
"media.autoplay.default" = 2;
|
"media.eme.enabled" = false;
|
||||||
"media.eme.enabled" = false;
|
"media.gmp-widevinecdm.enabled" = false;
|
||||||
"media.gmp-widevinecdm.enabled" = false;
|
"media.navigator.enabled" = false;
|
||||||
"media.navigator.enabled" = false;
|
"media.peerconnection.enabled" = false;
|
||||||
"media.peerconnection.enabled" = false;
|
"media.video_stats.enabled" = false;
|
||||||
"media.video_stats.enabled" = false;
|
"network.IDN_show_punycode" = true;
|
||||||
"network.IDN_show_punycode" = true;
|
"network.allow-experiments" = false;
|
||||||
"network.allow-experiments" = false;
|
"network.captive-portal-service.enabled" = false;
|
||||||
"network.captive-portal-service.enabled" = false;
|
"network.cookie.cookieBehavior" = 1;
|
||||||
"network.cookie.cookieBehavior" = 1;
|
"network.dns.disablePrefetch" = true;
|
||||||
"network.dns.disablePrefetch" = true;
|
"network.dns.disablePrefetchFromHTTPS" = true;
|
||||||
"network.dns.disablePrefetchFromHTTPS" = true;
|
"network.http.referer.spoofSource" = true;
|
||||||
"network.http.referer.spoofSource" = true;
|
"network.http.speculative-parallel-limit" = 0;
|
||||||
"network.http.speculative-parallel-limit" = 0;
|
"network.predictor.enable-prefetch" = false;
|
||||||
"network.predictor.enable-prefetch" = false;
|
"network.predictor.enabled" = false;
|
||||||
"network.predictor.enabled" = false;
|
"network.prefetch-next" = false;
|
||||||
"network.prefetch-next" = false;
|
"network.trr.mode" = 5;
|
||||||
"network.trr.mode" = 5;
|
"privacy.donottrackheader.enabled" = true;
|
||||||
"privacy.donottrackheader.enabled" = true;
|
"privacy.donottrackheader.value" = 1;
|
||||||
"privacy.donottrackheader.value" = 1;
|
"privacy.trackingprotection.cryptomining.enabled" = true;
|
||||||
"privacy.trackingprotection.cryptomining.enabled" = true;
|
"privacy.trackingprotection.enabled" = true;
|
||||||
"privacy.trackingprotection.enabled" = true;
|
"privacy.trackingprotection.fingerprinting.enabled" = true;
|
||||||
"privacy.trackingprotection.fingerprinting.enabled" = true;
|
"privacy.trackingprotection.pbmode.enabled" = true;
|
||||||
"privacy.trackingprotection.pbmode.enabled" = true;
|
"privacy.usercontext.about_newtab_segregation.enabled" = true;
|
||||||
"privacy.usercontext.about_newtab_segregation.enabled" = true;
|
"security.ssl.disable_session_identifiers" = true;
|
||||||
"security.ssl.disable_session_identifiers" = true;
|
# Hardware Video Acceleration
|
||||||
# Hardware Video Acceleration
|
"media.ffmpeg.vaapi.enabled" = true;
|
||||||
"media.ffmpeg.vaapi.enabled" = true;
|
"media.ffvpx.enabled" = false;
|
||||||
"media.ffvpx.enabled" = false;
|
"media.rdd-vpx.enabled" = false;
|
||||||
"media.rdd-vpx.enabled" = false;
|
"media.navigator.mediadataencoder_vpx_enabled" = true;
|
||||||
"media.navigator.mediadataencoder_vpx_enabled" = true;
|
# WebRender
|
||||||
# WebRender
|
"gfx.webrender.all" = true;
|
||||||
"gfx.webrender.all" = true;
|
# Better smooth scrolling
|
||||||
# Better smooth scrolling
|
"general.smoothScroll.msdPhysics.continuousMotionMaxDeltaMS" = 250;
|
||||||
"general.smoothScroll.msdPhysics.continuousMotionMaxDeltaMS" = 250;
|
"general.smoothScroll.msdPhysics.enabled" = true;
|
||||||
"general.smoothScroll.msdPhysics.enabled" = true;
|
"general.smoothScroll.msdPhysics.motionBeginSpringConstant" = 450;
|
||||||
"general.smoothScroll.msdPhysics.motionBeginSpringConstant" = 450;
|
"general.smoothScroll.msdPhysics.regularSpringConstant" = 450;
|
||||||
"general.smoothScroll.msdPhysics.regularSpringConstant" = 450;
|
"general.smoothScroll.msdPhysics.slowdownMinDeltaMS" = 50;
|
||||||
"general.smoothScroll.msdPhysics.slowdownMinDeltaMS" = 50;
|
"general.smoothScroll.msdPhysics.slowdownMinDeltaRatio;0" = 4;
|
||||||
"general.smoothScroll.msdPhysics.slowdownMinDeltaRatio;0" = 4;
|
"general.smoothScroll.msdPhysics.slowdownSpringConstant" = 5000;
|
||||||
"general.smoothScroll.msdPhysics.slowdownSpringConstant" = 5000;
|
"mousewheel.min_line_scroll_amount" = 22;
|
||||||
"mousewheel.min_line_scroll_amount" = 22;
|
"toolkit.scrollbox.horizontalScrollDistance" = 4;
|
||||||
"toolkit.scrollbox.horizontalScrollDistance" = 4;
|
"toolkit.scrollbox.verticalScrollDistance" = 5;
|
||||||
"toolkit.scrollbox.verticalScrollDistance" = 5;
|
# Misc
|
||||||
# Misc
|
"layout.spellcheckDefault" = 0; # I don't use spellcheck
|
||||||
"layout.spellcheckDefault" = 0; # I don't use spellcheck
|
"extensions.activeThemeID" = "firefox-alpenglow@mozilla.org"; # It's a nice theme
|
||||||
"extensions.activeThemeID" = "firefox-alpenglow@mozilla.org"; # It's a nice theme
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
@ -1,24 +1,26 @@
|
|||||||
{ pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
environment.systemPackages = [ pkgs.diff-so-fancy ];
|
config = {
|
||||||
home-manager.users.alexander.programs.git = {
|
environment.systemPackages = [ pkgs.diff-so-fancy ];
|
||||||
enable = true;
|
home-manager.users."${config.system.singleUser}".programs.git = {
|
||||||
userEmail = "papatutuwawa@polynom.me";
|
enable = true;
|
||||||
userName = "Alexander \"PapaTutuWawa\"";
|
userEmail = "papatutuwawa@polynom.me";
|
||||||
extraConfig = {
|
userName = "Alexander \"PapaTutuWawa\"";
|
||||||
init = {
|
extraConfig = {
|
||||||
defaultBranch = "master";
|
init = {
|
||||||
};
|
defaultBranch = "master";
|
||||||
|
};
|
||||||
|
|
||||||
pull = {
|
pull = {
|
||||||
rebase = true;
|
rebase = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
core = {
|
core = {
|
||||||
editor = "rvim";
|
editor = "rvim";
|
||||||
filemode = "false";
|
filemode = "false";
|
||||||
pager = "diff-so-fancy | less --tabs=4 -RFX";
|
pager = "diff-so-fancy | less --tabs=4 -RFX";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
@ -1,16 +1,18 @@
|
|||||||
{ pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
environment.systemPackages = [ pkgs.gnome.gnome-terminal ];
|
config = {
|
||||||
home-manager.users.alexander.programs.gnome-terminal = {
|
environment.systemPackages = [ pkgs.gnome.gnome-terminal ];
|
||||||
enable = true;
|
home-manager.users."${config.system.singleUser}".programs.gnome-terminal = {
|
||||||
profile.default = {
|
enable = true;
|
||||||
visibleName = "default";
|
profile.default = {
|
||||||
audibleBell = false;
|
visibleName = "default";
|
||||||
#boldIsBright = true;
|
audibleBell = false;
|
||||||
default = true;
|
#boldIsBright = true;
|
||||||
# TODO: Make this configurable
|
default = true;
|
||||||
font = "Source Code Pro 12";
|
# TODO: Make this configurable
|
||||||
|
font = "Source Code Pro 12";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@ -3,64 +3,115 @@
|
|||||||
let
|
let
|
||||||
unstable = (import ../../unstable.nix config);
|
unstable = (import ../../unstable.nix config);
|
||||||
in {
|
in {
|
||||||
environment = {
|
config = {
|
||||||
systemPackages = with pkgs; [
|
environment = {
|
||||||
arc-theme
|
systemPackages = with pkgs; [
|
||||||
gnomeExtensions.appindicator
|
arc-theme
|
||||||
gnomeExtensions.caffeine
|
gnomeExtensions.appindicator
|
||||||
gnomeExtensions.gnome-40-ui-improvements
|
gnomeExtensions.caffeine
|
||||||
gnomeExtensionsCustom.notification-timeout # Custom package
|
gnomeExtensions.gnome-40-ui-improvements
|
||||||
gnomeExtensions.application-volume-mixer
|
gnomeExtensionsCustom.notification-timeout # Custom package
|
||||||
gnome.eog
|
gnomeExtensions.application-volume-mixer
|
||||||
gnome.nautilus
|
gnome.eog
|
||||||
unstable.gnome.gnome-shell
|
gnome.nautilus
|
||||||
gnome.gnome-terminal
|
unstable.gnome.gnome-shell
|
||||||
pinentry-gnome
|
gnome.gnome-terminal
|
||||||
dconf # For home-manager
|
pinentry-gnome
|
||||||
];
|
dconf # For home-manager
|
||||||
gnome.excludePackages = pkgs.gnome.optionalPackages;
|
];
|
||||||
};
|
gnome.excludePackages = pkgs.gnome.optionalPackages;
|
||||||
|
|
||||||
services = {
|
|
||||||
accounts-daemon.enable = true;
|
|
||||||
colord.enable = false;
|
|
||||||
geoclue2.enable = false;
|
|
||||||
dleyna-renderer.enable = false;
|
|
||||||
dleyna-server.enable = false;
|
|
||||||
gvfs.enable = lib.mkForce false;
|
|
||||||
telepathy.enable = false;
|
|
||||||
gnome = {
|
|
||||||
chrome-gnome-shell.enable = false;
|
|
||||||
gnome-initial-setup.enable = false;
|
|
||||||
gnome-remote-desktop.enable = false;
|
|
||||||
rygel.enable = false;
|
|
||||||
gnome-online-accounts.enable = false;
|
|
||||||
evolution-data-server.enable = lib.mkForce false;
|
|
||||||
tracker.enable = false;
|
|
||||||
tracker-miners.enable = false;
|
|
||||||
core-utilities.enable = false;
|
|
||||||
games.enable = false;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
udev.packages = with pkgs; [ gnome.gnome-settings-daemon ];
|
services = {
|
||||||
|
accounts-daemon.enable = true;
|
||||||
xserver = {
|
colord.enable = false;
|
||||||
enable = true;
|
geoclue2.enable = false;
|
||||||
layout = "de";
|
dleyna-renderer.enable = false;
|
||||||
|
dleyna-server.enable = false;
|
||||||
|
gvfs.enable = lib.mkForce false;
|
||||||
|
telepathy.enable = false;
|
||||||
|
gnome = {
|
||||||
|
chrome-gnome-shell.enable = false;
|
||||||
|
gnome-initial-setup.enable = false;
|
||||||
|
gnome-remote-desktop.enable = false;
|
||||||
|
rygel.enable = false;
|
||||||
|
gnome-online-accounts.enable = false;
|
||||||
|
evolution-data-server.enable = lib.mkForce false;
|
||||||
|
tracker.enable = false;
|
||||||
|
tracker-miners.enable = false;
|
||||||
|
core-utilities.enable = false;
|
||||||
|
games.enable = false;
|
||||||
|
};
|
||||||
|
|
||||||
libinput.enable = true;
|
udev.packages = with pkgs; [ gnome.gnome-settings-daemon ];
|
||||||
|
|
||||||
desktopManager.gnome.enable = true;
|
xserver = {
|
||||||
displayManager = {
|
enable = true;
|
||||||
gdm.enable = true;
|
layout = "de";
|
||||||
gdm.wayland = true;
|
|
||||||
|
libinput.enable = true;
|
||||||
|
|
||||||
|
desktopManager.gnome.enable = true;
|
||||||
|
displayManager = {
|
||||||
|
gdm.enable = true;
|
||||||
|
gdm.wayland = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
xdg.portal = {
|
||||||
|
enable = true;
|
||||||
|
extraPortals = [ pkgs.xdg-desktop-portal-gtk ];
|
||||||
|
gtkUsePortal = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
home-manager.users."${config.system.singleUser}" = {
|
||||||
|
dconf.settings = {
|
||||||
|
# The packages come in from modules/programs/gnome
|
||||||
|
# Theme
|
||||||
|
"org/gnome/desktop/interface" = {
|
||||||
|
gtk-theme = "Arc-Dark";
|
||||||
|
};
|
||||||
|
|
||||||
|
# Nightlight (TODO: ?)
|
||||||
|
"org/gnome/settings-daemon/plugins/color" = {
|
||||||
|
night-light-enabled = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
# Extensions
|
||||||
|
"org/gnome/shell" = {
|
||||||
|
enabled-extensions = [
|
||||||
|
"caffeine@patapon.info"
|
||||||
|
"notification-timeout@chlumskyvaclav.gmail.com"
|
||||||
|
"gnome-ui-tune@itstime.tech"
|
||||||
|
"volume-mixer@evermiss.net"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
"org/gnome/shell/extensions/caffeine" = {
|
||||||
|
show-notifications = false;
|
||||||
|
inhibit-apps = [ "mpv.desktop" ];
|
||||||
|
};
|
||||||
|
"org/gnome/shell/extensions/notification-timeout" = {
|
||||||
|
timeout = 3000;
|
||||||
|
};
|
||||||
|
|
||||||
|
"org/gnome/shell/extensions/gnome-ui-tune" = {
|
||||||
|
hide-search = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
# Shortcuts
|
||||||
|
"org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0" = {
|
||||||
|
binding = "<Alt>Return";
|
||||||
|
command = "gnome-terminal";
|
||||||
|
name = "Terminal";
|
||||||
|
};
|
||||||
|
"org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom1" = {
|
||||||
|
binding = "<Super>s";
|
||||||
|
command = "systemctl suspend";
|
||||||
|
name = "Suspend";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
xdg.portal = {
|
|
||||||
enable = true;
|
|
||||||
extraPortals = [ pkgs.xdg-desktop-portal-gtk ];
|
|
||||||
gtkUsePortal = true;
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
{ pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
let
|
let
|
||||||
makeMpvProfile = { shader, additional ? {} }: {
|
makeMpvProfile = { shader, additional ? {} }: {
|
||||||
@ -14,30 +14,32 @@ let
|
|||||||
tscale = "oversample";
|
tscale = "oversample";
|
||||||
} // additional;
|
} // additional;
|
||||||
in {
|
in {
|
||||||
environment.systemPackages = [ pkgs.mpv ];
|
config = {
|
||||||
|
environment.systemPackages = [ pkgs.mpv ];
|
||||||
|
|
||||||
home-manager.users.alexander = {
|
home-manager.users."${config.system.singleUser}" = {
|
||||||
xdg.configFile = {
|
xdg.configFile = {
|
||||||
"mpv/shaders/Anime4K_Upscale_CNN_UL_x2_Deblur.glsl".source = ./shaders/Anime4K_Upscale_CNN_UL_x2_Deblur.glsl;
|
"mpv/shaders/Anime4K_Upscale_CNN_UL_x2_Deblur.glsl".source = ./shaders/Anime4K_Upscale_CNN_UL_x2_Deblur.glsl;
|
||||||
"mpv/shaders/Anime4K_Upscale_CNN_UL_x2_Denoise.glsl".source = ./shaders/Anime4K_Upscale_CNN_UL_x2_Denoise.glsl;
|
"mpv/shaders/Anime4K_Upscale_CNN_UL_x2_Denoise.glsl".source = ./shaders/Anime4K_Upscale_CNN_UL_x2_Denoise.glsl;
|
||||||
};
|
|
||||||
|
|
||||||
programs.mpv = {
|
|
||||||
enable = true;
|
|
||||||
config = {
|
|
||||||
script-opts = "try_ytdl_first=no";
|
|
||||||
};
|
};
|
||||||
defaultProfiles = [ "anime" ];
|
|
||||||
profiles = {
|
programs.mpv = {
|
||||||
anime = (makeMpvProfile {
|
enable = true;
|
||||||
shader = "Anime4K_Upscale_CNN_UL_x2_Deblur.glsl";
|
config = {
|
||||||
additional = {
|
script-opts = "try_ytdl_first=no";
|
||||||
fullscreen = "";
|
};
|
||||||
};
|
defaultProfiles = [ "anime" ];
|
||||||
});
|
profiles = {
|
||||||
"anime-denoise" = (makeMpvProfile {
|
anime = (makeMpvProfile {
|
||||||
shader = "Anime4K_Upscale_CNN_UL_x2_Denoise.glsl";
|
shader = "Anime4K_Upscale_CNN_UL_x2_Deblur.glsl";
|
||||||
});
|
additional = {
|
||||||
|
fullscreen = "";
|
||||||
|
};
|
||||||
|
});
|
||||||
|
"anime-denoise" = (makeMpvProfile {
|
||||||
|
shader = "Anime4K_Upscale_CNN_UL_x2_Denoise.glsl";
|
||||||
|
});
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
@ -1,56 +1,58 @@
|
|||||||
{ pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
environment.systemPackages = [ pkgs.tmux ];
|
config = {
|
||||||
home-manager.users.alexander.programs.tmux = {
|
environment.systemPackages = [ pkgs.tmux ];
|
||||||
enable = true;
|
home-manager.users."${config.system.singleUser}".programs.tmux = {
|
||||||
extraConfig = ''
|
enable = true;
|
||||||
set -g mouse on
|
extraConfig = ''
|
||||||
set -g history-limit 1000
|
set -g mouse on
|
||||||
setw -g monitor-activity on
|
set -g history-limit 1000
|
||||||
set -g visual-activity on
|
setw -g monitor-activity on
|
||||||
|
set -g visual-activity on
|
||||||
|
|
||||||
bind r source-file ~/.config/tmux/config
|
bind r source-file ~/.config/tmux/config
|
||||||
|
|
||||||
## Status bar design
|
## Status bar design
|
||||||
# status line
|
# status line
|
||||||
set -g status-justify left
|
set -g status-justify left
|
||||||
set -g status-interval 2
|
set -g status-interval 2
|
||||||
|
|
||||||
# window status
|
# window status
|
||||||
setw -g window-status-format " #F#I:#W#F "
|
setw -g window-status-format " #F#I:#W#F "
|
||||||
setw -g window-status-current-format " #F#I:#W#F "
|
setw -g window-status-current-format " #F#I:#W#F "
|
||||||
setw -g window-status-format "#[fg=magenta]#[bg=black] #I #[bg=cyan]#[fg=colour8] #W "
|
setw -g window-status-format "#[fg=magenta]#[bg=black] #I #[bg=cyan]#[fg=colour8] #W "
|
||||||
setw -g window-status-current-format "#[bg=brightmagenta]#[fg=colour8] #I #[fg=colour8]#[bg=colour14] #W "
|
setw -g window-status-current-format "#[bg=brightmagenta]#[fg=colour8] #I #[fg=colour8]#[bg=colour14] #W "
|
||||||
|
|
||||||
# Info on left (I don't have a session display for now)
|
# Info on left (I don't have a session display for now)
|
||||||
set -g status-left ""
|
set -g status-left ""
|
||||||
|
|
||||||
# loud or quiet?
|
# loud or quiet?
|
||||||
set-option -g visual-activity off
|
set-option -g visual-activity off
|
||||||
set-option -g visual-bell off
|
set-option -g visual-bell off
|
||||||
set-option -g visual-silence off
|
set-option -g visual-silence off
|
||||||
set-window-option -g monitor-activity off
|
set-window-option -g monitor-activity off
|
||||||
set-option -g bell-action none
|
set-option -g bell-action none
|
||||||
|
|
||||||
set -g default-terminal "screen-256color"
|
set -g default-terminal "screen-256color"
|
||||||
|
|
||||||
# The modes {
|
# The modes {
|
||||||
setw -g clock-mode-colour colour135
|
setw -g clock-mode-colour colour135
|
||||||
|
|
||||||
# }
|
# }
|
||||||
|
|
||||||
# The statusbar {
|
# The statusbar {
|
||||||
set -g status-position bottom
|
set -g status-position bottom
|
||||||
set -g status-left ""
|
set -g status-left ""
|
||||||
set -g status-right '#[fg=colour233,bg=colour241,bold] %d/%m #[fg=colour233,bg=colour245,bold] %H:%M:%S '
|
set -g status-right '#[fg=colour233,bg=colour241,bold] %d/%m #[fg=colour233,bg=colour245,bold] %H:%M:%S '
|
||||||
set -g status-right-length 50
|
set -g status-right-length 50
|
||||||
set -g status-left-length 20
|
set -g status-left-length 20
|
||||||
|
|
||||||
setw -g window-status-current-format ' #I#[fg=colour250]:#[fg=colour255]#W#[fg=colour50]#F '
|
setw -g window-status-current-format ' #I#[fg=colour250]:#[fg=colour255]#W#[fg=colour50]#F '
|
||||||
|
|
||||||
setw -g window-status-format ' #I#[fg=colour237]:#[fg=colour250]#W#[fg=colour244]#F '
|
setw -g window-status-format ' #I#[fg=colour237]:#[fg=colour250]#W#[fg=colour244]#F '
|
||||||
# }
|
# }
|
||||||
'';
|
'';
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
{ pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
environment = {
|
environment = {
|
||||||
@ -11,7 +11,7 @@
|
|||||||
# Otherwise the user won't appear on the GDM login screen
|
# Otherwise the user won't appear on the GDM login screen
|
||||||
programs.zsh.enable = true;
|
programs.zsh.enable = true;
|
||||||
|
|
||||||
home-manager.users.alexander.programs.zsh = {
|
home-manager.users."${config.system.singleUser}".programs.zsh = {
|
||||||
enable = true;
|
enable = true;
|
||||||
history.ignoreSpace = true;
|
history.ignoreSpace = true;
|
||||||
shellAliases = {
|
shellAliases = {
|
||||||
|
@ -12,10 +12,14 @@
|
|||||||
isSystemUser = false;
|
isSystemUser = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
system.singleUser = "alexander";
|
||||||
|
|
||||||
# Activate gpg
|
# Activate gpg
|
||||||
programs.gnupg.agent.enable = true;
|
programs.gnupg.agent.enable = true;
|
||||||
|
|
||||||
|
# No need to use users."${system.singleUser}" as we already know it
|
||||||
home-manager.users.alexander = {
|
home-manager.users.alexander = {
|
||||||
|
# TODO: Move into a generic
|
||||||
pam.sessionVariables = {
|
pam.sessionVariables = {
|
||||||
NIXOS_CONFIG = "\${HOME}/Development/Personal/nixos-config/${config.networking.hostName}.nix";
|
NIXOS_CONFIG = "\${HOME}/Development/Personal/nixos-config/${config.networking.hostName}.nix";
|
||||||
};
|
};
|
||||||
@ -37,53 +41,6 @@
|
|||||||
enable = true;
|
enable = true;
|
||||||
pinentryFlavor = "gnome3";
|
pinentryFlavor = "gnome3";
|
||||||
};
|
};
|
||||||
|
|
||||||
dconf.settings = {
|
|
||||||
# The packages come in from modules/programs/gnome
|
|
||||||
# Theme
|
|
||||||
"org/gnome/desktop/interface" = {
|
|
||||||
gtk-theme = "Arc-Dark";
|
|
||||||
};
|
|
||||||
|
|
||||||
# Nightlight (TODO: ?)
|
|
||||||
"org/gnome/settings-daemon/plugins/color" = {
|
|
||||||
night-light-enabled = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
# Extensions
|
|
||||||
"org/gnome/shell" = {
|
|
||||||
enabled-extensions = [
|
|
||||||
"caffeine@patapon.info"
|
|
||||||
"notification-timeout@chlumskyvaclav.gmail.com"
|
|
||||||
"gnome-ui-tune@itstime.tech"
|
|
||||||
"volume-mixer@evermiss.net"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
"org/gnome/shell/extensions/caffeine" = {
|
|
||||||
show-notifications = false;
|
|
||||||
inhibit-apps = [ "mpv.desktop" ];
|
|
||||||
};
|
|
||||||
"org/gnome/shell/extensions/notification-timeout" = {
|
|
||||||
timeout = 3000;
|
|
||||||
};
|
|
||||||
|
|
||||||
"org/gnome/shell/extensions/gnome-ui-tune" = {
|
|
||||||
hide-search = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
# Shortcuts
|
|
||||||
"org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0" = {
|
|
||||||
binding = "<Alt>Return";
|
|
||||||
command = "gnome-terminal";
|
|
||||||
name = "Terminal";
|
|
||||||
};
|
|
||||||
"org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom1" = {
|
|
||||||
binding = "<Super>s";
|
|
||||||
command = "systemctl suspend";
|
|
||||||
name = "Suspend";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
11
modules/users/default.nix
Normal file
11
modules/users/default.nix
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
{ lib, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
options.system = {
|
||||||
|
singleUser = lib.options.mkOption {
|
||||||
|
example = "PapaTutuWawa";
|
||||||
|
readOnly = true;
|
||||||
|
description = "The username of this single-user system";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
@ -1,5 +1,18 @@
|
|||||||
{ pkgs, ... }:
|
{ pkgs, lib, config, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
# TODO
|
config = {
|
||||||
|
users.users.fuck-xi = {
|
||||||
|
isNormalUser = true;
|
||||||
|
extraGroups = [ "wheel" "audio" "video" "kvm" "input" ];
|
||||||
|
# -> abc123
|
||||||
|
hashedPassword = "$5$etg0.qVfujgh8JZu$HxGwG.aTZIT1vVo/E2wNdgVLr6dtg.XEPxvAro.iJ29";
|
||||||
|
shell = pkgs.zsh;
|
||||||
|
useDefaultShell = false;
|
||||||
|
uid = 1000;
|
||||||
|
isSystemUser = false;
|
||||||
|
};
|
||||||
|
|
||||||
|
system.singleUser = "fuck-xi";
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user