mirror of
https://github.com/foo-dogsquared/nixos-config.git
synced 2025-02-25 00:19:00 +00:00
Update library and custom modules
- Add custom GNOME configurations with dconf keyfiles. - Refactoring in certain parts of files especially with handling merging and importing of modules.
This commit is contained in:
parent
e3344541a6
commit
40cca61bbe
@ -114,15 +114,15 @@ in rec {
|
|||||||
attrs@{ system ? sys, ... }:
|
attrs@{ system ? sys, ... }:
|
||||||
lib.nixosSystem {
|
lib.nixosSystem {
|
||||||
inherit system;
|
inherit system;
|
||||||
|
|
||||||
|
# Additional attributes to be referred to our modules.
|
||||||
specialArgs = { inherit lib system inputs; };
|
specialArgs = { inherit lib system inputs; };
|
||||||
|
|
||||||
# We also set the following in order for priority.
|
# We also set the following in order for priority.
|
||||||
# Later modules will override previously imported modules.
|
# Later modules will override previously imported modules.
|
||||||
modules = [
|
modules = [
|
||||||
# Set the hostname.
|
# Set the hostname.
|
||||||
{
|
{ networking.hostName = builtins.baseNameOf file; }
|
||||||
networking.hostName = builtins.baseNameOf file;
|
|
||||||
}
|
|
||||||
|
|
||||||
# Put the given attribute set (except for the system).
|
# Put the given attribute set (except for the system).
|
||||||
(lib.filterAttrs (n: v: !lib.elem n [ "system" ]) attrs)
|
(lib.filterAttrs (n: v: !lib.elem n [ "system" ]) attrs)
|
||||||
@ -131,7 +131,7 @@ in rec {
|
|||||||
file
|
file
|
||||||
]
|
]
|
||||||
# Append with our custom modules from the modules folder.
|
# Append with our custom modules from the modules folder.
|
||||||
++ (lib.mapAttrsToList (n: v: import v) (filesToAttr ../modules));
|
++ (lib.modulesToList (filesToAttr ../modules));
|
||||||
};
|
};
|
||||||
|
|
||||||
/* Return an attribute set of valid users from a given list of users.
|
/* Return an attribute set of valid users from a given list of users.
|
||||||
|
@ -11,6 +11,11 @@ in
|
|||||||
services.xserver.displayManager.gdm.enable = true;
|
services.xserver.displayManager.gdm.enable = true;
|
||||||
services.xserver.desktopManager.gnome.enable = true;
|
services.xserver.desktopManager.gnome.enable = true;
|
||||||
|
|
||||||
|
# Import the configuration with dconf.
|
||||||
|
programs.dconf.enable = true;
|
||||||
|
environment.etc."dconf/profile/gnome".text = "user-db:user";
|
||||||
|
environment.etc."dconf/db/gnome".source = ./schemas;
|
||||||
|
|
||||||
# I'm pretty sure this is already done but just to make sure.
|
# I'm pretty sure this is already done but just to make sure.
|
||||||
services.gnome.chrome-gnome-shell.enable = true;
|
services.gnome.chrome-gnome-shell.enable = true;
|
||||||
|
|
||||||
@ -18,8 +23,15 @@ in
|
|||||||
# It is required for custom menus in extensions.
|
# It is required for custom menus in extensions.
|
||||||
gnome-menus
|
gnome-menus
|
||||||
|
|
||||||
|
# My preferred extensions.
|
||||||
gnomeExtensions.arcmenu
|
gnomeExtensions.arcmenu
|
||||||
|
gnomeExtensions.gsconnect
|
||||||
gnomeExtensions.x11-gestures
|
gnomeExtensions.x11-gestures
|
||||||
|
|
||||||
|
# Setting up Pop shell.
|
||||||
|
gnome-shell-extension-pop-shell
|
||||||
|
pop-launcher
|
||||||
|
pop-launcher-plugin-duckduckgo-bangs
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
30
modules/themes/a-happy-gnome/schemas/desktop.conf
Normal file
30
modules/themes/a-happy-gnome/schemas/desktop.conf
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
[org/gnome/desktop/interface]
|
||||||
|
enable-animations=true
|
||||||
|
enable-hot-corners=false
|
||||||
|
gtk-im-module='gtk-im-context-simple'
|
||||||
|
show-battery-percentage=true
|
||||||
|
|
||||||
|
[org/gnome/desktop/notifications]
|
||||||
|
show-banners=true
|
||||||
|
|
||||||
|
[org/gnome/desktop/privacy]
|
||||||
|
disable-microphone=false
|
||||||
|
|
||||||
|
[org/gnome/shell]
|
||||||
|
disable-user-extensions=false
|
||||||
|
enabled-extensions=['arcmenu@arcmenu/com', 'just-perfection-desktop@just-perfection', 'gsconnect@andyholmes/github/io', 'pop-shell@system76/com', 'flypie@schneegans/github/com']
|
||||||
|
|
||||||
|
[org/gnome/mutter]
|
||||||
|
attach-modal-dialogs=true
|
||||||
|
dynamic-workspaces=true
|
||||||
|
edge-tiling=true
|
||||||
|
focus-change-on-pointer-rest=true
|
||||||
|
overlay-key='Super_L'
|
||||||
|
workspaces-only-on-primary=true
|
||||||
|
|
||||||
|
[org/gnome/shell/world-clocks]
|
||||||
|
locations=[<(uint32 2, <('New York', 'KNYC', true, [(0/71180344078725644, -1/2909618758762367)], [(0/71059804659265924, -1/2916478949920254)])>)>, <(uint32 2, <('Coordinated Universal Time (UTC)', '@UTC', false, @a(dd) [], @a(dd) [])>)>, <(uint32 2, <('Cairo', 'HECA', true, [(0/52592587544986047, 0/54803338512621935)], [(0/52447144022429604, 0/54541539124822791)])>)>]
|
||||||
|
|
||||||
|
[org/gnome/system/location]
|
||||||
|
enabled=false
|
||||||
|
|
24
modules/themes/a-happy-gnome/schemas/keybindings.conf
Normal file
24
modules/themes/a-happy-gnome/schemas/keybindings.conf
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
[org/gnome/desktop/wm/keybindings]
|
||||||
|
begin-resize=['<Super>r']
|
||||||
|
close=['<Super>q']
|
||||||
|
maximize=@as []
|
||||||
|
minimize=@as []
|
||||||
|
panel-main-menu=@as []
|
||||||
|
switch-input-source=['<Super>i']
|
||||||
|
switch-input-source-backward=['<Shift><Super>i']
|
||||||
|
toggle-fullscreen=['<Super>f']
|
||||||
|
toggle-maximized=['<Shift><Super>f']
|
||||||
|
toggle-overview=['<Shift><Super>s']
|
||||||
|
toggle-tiled-left=@as []
|
||||||
|
toggle-tiled-right=@as []
|
||||||
|
|
||||||
|
[org/gnome/shell/keybindings]
|
||||||
|
toggle-message-tray=['<Super>v']
|
||||||
|
|
||||||
|
[org/gnome/mutter/wayland/keybindings]
|
||||||
|
restore-shortcuts=@as []
|
||||||
|
|
||||||
|
[org/gnome/settings-daemon/plugins/media-keys]
|
||||||
|
screensaver=['<Super>Escape']
|
||||||
|
logout=['<Shift><Super>Escape']
|
||||||
|
help=@as []
|
30
modules/themes/a-happy-gnome/schemas/shell-extensions.conf
Normal file
30
modules/themes/a-happy-gnome/schemas/shell-extensions.conf
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
[org/gnome/shell/extensions/arcmenu]
|
||||||
|
arc-menu-icon=64
|
||||||
|
arc-menu-placement='Panel'
|
||||||
|
available-placement=[true, false, false]
|
||||||
|
disable-recently-installed-apps=false
|
||||||
|
menu-button-icon='Arc_Menu_Icon'
|
||||||
|
menu-height=550
|
||||||
|
menu-hotkey='Super_L'
|
||||||
|
menu-layout='Runner'
|
||||||
|
runner-position='Centered'
|
||||||
|
runner-show-frequent-apps=true
|
||||||
|
search-provider-open-windows=true
|
||||||
|
show-activities-button=false
|
||||||
|
show-search-result-details=true
|
||||||
|
|
||||||
|
[org/gnome/shell/extensions/just-perfection]
|
||||||
|
activities-button=false
|
||||||
|
workspace-wrap-around=true
|
||||||
|
window-demands-attention-focus=true
|
||||||
|
ripple-box=false
|
||||||
|
|
||||||
|
# The default keybindings for this extension are enough but we'll have to adjust the shell keybindings.
|
||||||
|
[org/gnome/shell/extensions/pop-shell]
|
||||||
|
active-hint=true
|
||||||
|
smart-gaps=true
|
||||||
|
tile-by-default=true
|
||||||
|
hint-color-rgba='rgba(223, 147, 122, 1)'
|
||||||
|
|
||||||
|
[org/gnome/shell/extensions/flypie]
|
||||||
|
menu-configuration='[{"name":"Global palette","icon":"🐶️","shortcut":"<Super>space","centered":false,"id":0,"children":[{"name":"Close window","type":"Shortcut","icon":"window-close","data":{"shortcut":"<Super>q"},"angle":-1},{"name":"Next Workspace","icon":"go-next","type":"Shortcut","data":{"shortcut":"<Control><Super>l"},"angle":90},{"name":"Favorites","icon":"emblem-favorite","type":"Favorites","data":{},"angle":-1},{"name":"Fly-Pie Settings","icon":"applications-system","type":"Command","data":"gnome-extensions prefs flypie@schneegans.github.com","angle":-1},{"name":"Previous Workspace","icon":"go-previous","type":"Shortcut","data":{"shortcut":"<Control><Super>h"},"angle":270},{"name":"Running Apps","icon":"flypie-menu-running-apps-symbolic-#74a","type":"RunningApps","data":{"activeWorkspaceOnly":false,"appGrouping":true,"hoverPeeking":true,"nameRegex":""},"angle":-1}],"type":"CustomMenu","data":{}}]'
|
@ -4,8 +4,7 @@
|
|||||||
let
|
let
|
||||||
cfg = config.modules.users;
|
cfg = config.modules.users;
|
||||||
invalidUsernames = [ "config" "modules" ];
|
invalidUsernames = [ "config" "modules" ];
|
||||||
userModules = lib.filterAttrs (n: _: !lib.elem n invalidUsernames)
|
userModules = lib.getUsers cfg.users;
|
||||||
(lib.filesToAttr ../users);
|
|
||||||
homeManagerModules =
|
homeManagerModules =
|
||||||
lib.filterAttrs (n: _: n == "modules") (lib.filesToAttr ../users);
|
lib.filterAttrs (n: _: n == "modules") (lib.filesToAttr ../users);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user