chore(module): remove installPackage parameter
This commit is contained in:
parent
e2e5c9c75e
commit
691e01e22c
7 changed files with 30 additions and 60 deletions
|
@ -1,13 +1,10 @@
|
||||||
{ ... }: {
|
{ pkgs, ... }: {
|
||||||
config.modules = {
|
config.modules = {
|
||||||
application = {
|
application = {
|
||||||
gnupg.enable = true;
|
gnupg.enable = false;
|
||||||
zathura.enable = true;
|
zathura.enable = true;
|
||||||
foot.enable = true;
|
foot.enable = false;
|
||||||
imv = {
|
imv.enable = false;
|
||||||
enable = true;
|
|
||||||
installPackage = false;
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
cli = {
|
cli = {
|
||||||
direnv.enable = true;
|
direnv.enable = true;
|
||||||
|
@ -21,7 +18,7 @@
|
||||||
};
|
};
|
||||||
video = {
|
video = {
|
||||||
kdenlive.enable = false;
|
kdenlive.enable = false;
|
||||||
mpv.enable = true;
|
mpv.enable = false;
|
||||||
};
|
};
|
||||||
web.firefox = {
|
web.firefox = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -34,8 +31,7 @@
|
||||||
web.webcord.enable = false;
|
web.webcord.enable = false;
|
||||||
gaming.lutris.enable = false;
|
gaming.lutris.enable = false;
|
||||||
desktop.sway = {
|
desktop.sway = {
|
||||||
enable = true;
|
enable = false;
|
||||||
installPackage = false;
|
|
||||||
kanshi = false;
|
kanshi = false;
|
||||||
wallpapers.lockscreen = "${./files/lockscreen.png}";
|
wallpapers.lockscreen = "${./files/lockscreen.png}";
|
||||||
wallpapers.desktop = "${./files/background.png} fill #000000";
|
wallpapers.desktop = "${./files/background.png} fill #000000";
|
||||||
|
|
|
@ -1,8 +1,20 @@
|
||||||
_:
|
_:
|
||||||
{
|
{
|
||||||
wayland.windowManager.sway.config.output = {
|
programs.zsh.loginExtra = ''
|
||||||
"eDP-1" = {
|
#notmutch
|
||||||
scale = "1.3";
|
export NOTMUCH_CONFIG="$HOME/.config/notmuch/config"
|
||||||
};
|
export PATH=~/.local/bin:$PATH
|
||||||
};
|
# export XDG_DATA_HOME=$HOME/.local/share
|
||||||
}
|
unset DEBUGINFOD_URLS
|
||||||
|
if [[ ! $DISPLAY && $XDG_VTNR -eq 1 ]]; then
|
||||||
|
export QT_QPA_PLATFORM="wayland-egl"
|
||||||
|
export QT_WAYLAND_DISABLE_WINDOWDECORATION=1
|
||||||
|
export MOZ_ENABLE_WAYLAND=1
|
||||||
|
export QT_QPA_PLATFORMTHEME=qt5ct
|
||||||
|
export NO_AT_BRIDGE=1
|
||||||
|
export XDG_SESSION_TYPE=wayland
|
||||||
|
export XDG_CURRENT_DESKTOP=sway
|
||||||
|
exec ~/.local/bin/sway.sh
|
||||||
|
fi
|
||||||
|
'';
|
||||||
|
}
|
||||||
|
|
|
@ -17,11 +17,6 @@ in
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
programs.imv = {
|
programs.imv = {
|
||||||
enable = true;
|
enable = true;
|
||||||
package =
|
|
||||||
if cfg.installPackage
|
|
||||||
then pkgs.imv
|
|
||||||
else pkgs.emptyDirectory;
|
|
||||||
|
|
||||||
};
|
};
|
||||||
xdg.mimeApps.defaultApplications = {
|
xdg.mimeApps.defaultApplications = {
|
||||||
"image/*" = "imv-dir.desktop";
|
"image/*" = "imv-dir.desktop";
|
||||||
|
|
|
@ -7,12 +7,6 @@ in
|
||||||
options.modules.desktop.sway = {
|
options.modules.desktop.sway = {
|
||||||
enable = mkEnableOption "enable Sway Windows Manager";
|
enable = mkEnableOption "enable Sway Windows Manager";
|
||||||
|
|
||||||
installPackage = mkOption {
|
|
||||||
type = types.bool;
|
|
||||||
default = true;
|
|
||||||
description = "install Package, if false relies on distribution packages";
|
|
||||||
};
|
|
||||||
|
|
||||||
kanshi = mkOption {
|
kanshi = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
|
|
|
@ -7,14 +7,6 @@ in
|
||||||
config = mkIf config.modules.desktop.sway.enable {
|
config = mkIf config.modules.desktop.sway.enable {
|
||||||
wayland.windowManager.sway = {
|
wayland.windowManager.sway = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
||||||
# Do not install sway package on other system that NixOS
|
|
||||||
# because performance issue
|
|
||||||
package =
|
|
||||||
if cfg.installPackage
|
|
||||||
then pkgs.sway
|
|
||||||
else null;
|
|
||||||
|
|
||||||
wrapperFeatures.gtk = true;
|
wrapperFeatures.gtk = true;
|
||||||
systemd.enable = true;
|
systemd.enable = true;
|
||||||
config = {
|
config = {
|
||||||
|
@ -69,10 +61,7 @@ in
|
||||||
"${mod}+Shift+q" = "kill";
|
"${mod}+Shift+q" = "kill";
|
||||||
"${mod}+d" = "exec ${pkgs.fuzzel}/bin/fuzzel";
|
"${mod}+d" = "exec ${pkgs.fuzzel}/bin/fuzzel";
|
||||||
"${mod}+Shift+c" = "reload";
|
"${mod}+Shift+c" = "reload";
|
||||||
"${mod}+Alt+l" =
|
"${mod}+Alt+l" = "exec ${pkgs.swaylock}/bin/swaylock";
|
||||||
if cfg.installPackage
|
|
||||||
then "exec ${pkgs.swaylock}/bin/swaylock"
|
|
||||||
else "exec swaylock";
|
|
||||||
"${mod}+${left} focus" = "left";
|
"${mod}+${left} focus" = "left";
|
||||||
"${mod}+${down} focus" = "down";
|
"${mod}+${down} focus" = "down";
|
||||||
"${mod}+${up} focus" = "up";
|
"${mod}+${up} focus" = "up";
|
||||||
|
|
|
@ -10,34 +10,22 @@ in
|
||||||
timeouts = [
|
timeouts = [
|
||||||
{
|
{
|
||||||
timeout = 300;
|
timeout = 300;
|
||||||
command =
|
command = "${pkgs.swaylock}/bin/swaylock -f";
|
||||||
if cfg.installPackage
|
|
||||||
then "${pkgs.swaylock}/bin/swaylock -f"
|
|
||||||
else "swaylock -f";
|
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
timeout = 600;
|
timeout = 600;
|
||||||
command = ''${pkgs.sway}/bin/swaymsg "output * power off"'';
|
command = ''${pkgs.sway}/bin/swaymsg "output * power off"'';
|
||||||
resumeCommand =
|
resumeCommand =''${pkgs.sway}/bin/swaymsg "output * power on"'';
|
||||||
if cfg.installPackage
|
|
||||||
then ''${pkgs.sway}/bin/swaymsg "output * power on"''
|
|
||||||
else ''swaymsg "output * power on"'';
|
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
events = [
|
events = [
|
||||||
{
|
{
|
||||||
event = "before-sleep";
|
event = "before-sleep";
|
||||||
command =
|
command = "${pkgs.swaylock}/bin/swaylock -f";
|
||||||
if cfg.installPackage
|
|
||||||
then "${pkgs.swaylock}/bin/swaylock -f"
|
|
||||||
else "swaylock -f";
|
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
event = "lock";
|
event = "lock";
|
||||||
command =
|
command = "${pkgs.swaylock}/bin/swaylock -f";
|
||||||
if cfg.installPackage
|
|
||||||
then "${pkgs.swaylock}/bin/swaylock -f"
|
|
||||||
else "swaylock -f";
|
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
|
@ -7,10 +7,6 @@ in
|
||||||
config = mkIf config.modules.desktop.sway.enable {
|
config = mkIf config.modules.desktop.sway.enable {
|
||||||
programs.swaylock = {
|
programs.swaylock = {
|
||||||
enable = true;
|
enable = true;
|
||||||
package =
|
|
||||||
if cfg.installPackage
|
|
||||||
then pkgs.swaylock
|
|
||||||
else pkgs.emptyDirectory;
|
|
||||||
settings = {
|
settings = {
|
||||||
image = "${cfg.wallpapers.lockscreen}";
|
image = "${cfg.wallpapers.lockscreen}";
|
||||||
scaling = "center";
|
scaling = "center";
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue