mirror of
https://github.com/nix-community/home-manager.git
synced 2025-11-08 11:36:05 +01:00
treewide: format with latest stable formatter
Signed-off-by: Austin Horstman <khaneliman12@gmail.com>
This commit is contained in:
parent
56ee5d0670
commit
b4752b0eda
56 changed files with 816 additions and 832 deletions
|
|
@ -32,7 +32,8 @@ let
|
|||
class = "homeManager";
|
||||
specialArgs = {
|
||||
modulesPath = builtins.toString ./.;
|
||||
} // extraSpecialArgs;
|
||||
}
|
||||
// extraSpecialArgs;
|
||||
};
|
||||
|
||||
moduleChecks =
|
||||
|
|
|
|||
|
|
@ -615,8 +615,7 @@ in
|
|||
home.sessionVariablesPackage = pkgs.writeTextFile {
|
||||
name = "hm-session-vars.sh";
|
||||
destination = "/etc/profile.d/hm-session-vars.sh";
|
||||
text =
|
||||
''
|
||||
text = ''
|
||||
# Only source this once.
|
||||
if [ -n "$__HM_SESS_VARS_SOURCED" ]; then return; fi
|
||||
export __HM_SESS_VARS_SOURCED=1
|
||||
|
|
|
|||
|
|
@ -199,8 +199,7 @@ in
|
|||
};
|
||||
|
||||
home = {
|
||||
sessionVariables =
|
||||
{
|
||||
sessionVariables = {
|
||||
GLFW_IM_MODULE = "ibus"; # IME support in kitty
|
||||
SDL_IM_MODULE = "fcitx";
|
||||
XMODIFIERS = "@im=fcitx";
|
||||
|
|
|
|||
|
|
@ -18,8 +18,7 @@ rec {
|
|||
# All characters that are considered safe. Note "-" is not
|
||||
# included to avoid "-" followed by digit being interpreted as a
|
||||
# version.
|
||||
safeChars =
|
||||
[
|
||||
safeChars = [
|
||||
"+"
|
||||
"."
|
||||
"_"
|
||||
|
|
|
|||
|
|
@ -20,14 +20,12 @@ in
|
|||
nameExample ? "Adwaita",
|
||||
}:
|
||||
types.submodule {
|
||||
options =
|
||||
{
|
||||
options = {
|
||||
package = mkOption {
|
||||
type = types.nullOr types.package;
|
||||
default = null;
|
||||
example = literalExpression packageExample;
|
||||
description =
|
||||
''
|
||||
description = ''
|
||||
Package providing the ${typeName}. This package will be installed
|
||||
to your profile. If `null` then the ${typeName}
|
||||
is assumed to already be available in your profile.
|
||||
|
|
|
|||
|
|
@ -190,8 +190,7 @@ in
|
|||
"DRI_PRIME" = "${cfg.prime.card}";
|
||||
};
|
||||
|
||||
nvOffloadEnv =
|
||||
{
|
||||
nvOffloadEnv = {
|
||||
"DRI_PRIME" = "${cfg.prime.card}";
|
||||
"__NV_PRIME_RENDER_OFFLOAD" = "1";
|
||||
"__GLX_VENDOR_LIBRARY_NAME" = "nvidia";
|
||||
|
|
|
|||
|
|
@ -386,8 +386,7 @@ in
|
|||
)
|
||||
++ (lib.optionals (cfg.style.package != null) (lib.toList cfg.style.package));
|
||||
|
||||
xsession.importedVariables =
|
||||
[
|
||||
xsession.importedVariables = [
|
||||
"QT_PLUGIN_PATH"
|
||||
"QML2_IMPORT_PATH"
|
||||
]
|
||||
|
|
|
|||
|
|
@ -229,7 +229,8 @@ in
|
|||
config = lib.mkIf (config.xdg.desktopEntries != { }) {
|
||||
assertions = [
|
||||
(lib.hm.assertions.assertPlatform "xdg.desktopEntries" pkgs lib.platforms.linux)
|
||||
] ++ lib.flatten (lib.catAttrs "assertions" (lib.attrValues config.xdg.desktopEntries));
|
||||
]
|
||||
++ lib.flatten (lib.catAttrs "assertions" (lib.attrValues config.xdg.desktopEntries));
|
||||
|
||||
home.packages = (
|
||||
map lib.hiPrio # we need hiPrio to override existing entries
|
||||
|
|
|
|||
|
|
@ -13,8 +13,7 @@
|
|||
|
||||
let
|
||||
|
||||
modules =
|
||||
[
|
||||
modules = [
|
||||
# keep-sorted start case=no numeric=yes
|
||||
./accounts/calendar.nix
|
||||
./accounts/contacts.nix
|
||||
|
|
@ -96,8 +95,7 @@ let
|
|||
pkgsModule =
|
||||
{ config, ... }:
|
||||
{
|
||||
config =
|
||||
{
|
||||
config = {
|
||||
_module.args.baseModules = modules;
|
||||
_module.args.pkgsPath = lib.mkDefault (
|
||||
if lib.versionAtLeast config.home.stateVersion "20.09" then pkgs.path else <nixpkgs>
|
||||
|
|
|
|||
|
|
@ -254,8 +254,7 @@ in
|
|||
|
||||
home.packages = lib.mkIf (cfg.package != null) [ cfg.package ];
|
||||
|
||||
home.file =
|
||||
{
|
||||
home.file = {
|
||||
"${configDir}/accounts.conf" = mkIf genAccountsConf {
|
||||
text = joinCfg [
|
||||
header
|
||||
|
|
|
|||
|
|
@ -281,8 +281,7 @@ in
|
|||
xdg.configFile."alot/config".text = configFile;
|
||||
|
||||
xdg.configFile."alot/hooks.py" = lib.mkIf (cfg.hooks != "") {
|
||||
text =
|
||||
''
|
||||
text = ''
|
||||
# Generated by Home Manager.
|
||||
''
|
||||
+ cfg.hooks;
|
||||
|
|
|
|||
|
|
@ -53,8 +53,7 @@ in
|
|||
(pkgs.eclipses.eclipseWithPlugins {
|
||||
eclipse = cfg.package;
|
||||
jvmArgs =
|
||||
cfg.jvmArgs
|
||||
++ lib.optional cfg.enableLombok "-javaagent:${pkgs.lombok}/share/java/lombok.jar";
|
||||
cfg.jvmArgs ++ lib.optional cfg.enableLombok "-javaagent:${pkgs.lombok}/share/java/lombok.jar";
|
||||
plugins = cfg.plugins;
|
||||
})
|
||||
];
|
||||
|
|
|
|||
|
|
@ -63,8 +63,7 @@ let
|
|||
}
|
||||
)
|
||||
// {
|
||||
General =
|
||||
{
|
||||
General = {
|
||||
StartWithLastProfile = 1;
|
||||
}
|
||||
// lib.optionalAttrs (cfg.profileVersion != null) {
|
||||
|
|
@ -168,8 +167,7 @@ let
|
|||
in
|
||||
{
|
||||
assertion = duplicates == { };
|
||||
message =
|
||||
''
|
||||
message = ''
|
||||
Must not have a ${appName} ${entityKind} with an existing ID but
|
||||
''
|
||||
+ concatStringsSep "\n" (mapAttrsToList mkMsg duplicates);
|
||||
|
|
@ -784,8 +782,7 @@ in
|
|||
};
|
||||
|
||||
config = {
|
||||
assertions =
|
||||
[
|
||||
assertions = [
|
||||
(mkNoDuplicateAssertion config.containers "container")
|
||||
{
|
||||
assertion = !(extensionSettingsNeedForce config.extensions.settings) || config.extensions.force;
|
||||
|
|
@ -902,7 +899,8 @@ in
|
|||
}
|
||||
|
||||
(mkNoDuplicateAssertion cfg.profiles "profile")
|
||||
] ++ (lib.concatMap (profile: profile.assertions) (attrValues cfg.profiles));
|
||||
]
|
||||
++ (lib.concatMap (profile: profile.assertions) (attrValues cfg.profiles));
|
||||
|
||||
warnings =
|
||||
optional (cfg.enableGnomeExtensions or false) ''
|
||||
|
|
|
|||
|
|
@ -566,8 +566,9 @@ in
|
|||
package:
|
||||
pkgs.runCommand "${getName package}-fish-completions"
|
||||
{
|
||||
srcs =
|
||||
[ package ]
|
||||
srcs = [
|
||||
package
|
||||
]
|
||||
++ lib.filter (p: p != null) (
|
||||
builtins.map (outName: package.${outName} or null) config.home.extraOutputsToInstall
|
||||
);
|
||||
|
|
|
|||
|
|
@ -203,8 +203,7 @@ in
|
|||
FZF_CTRL_T_OPTS = cfg.fileWidgetOptions;
|
||||
FZF_DEFAULT_COMMAND = cfg.defaultCommand;
|
||||
FZF_DEFAULT_OPTS =
|
||||
cfg.defaultOptions
|
||||
++ lib.optionals (cfg.colors != { }) [ "--color ${renderedColors cfg.colors}" ];
|
||||
cfg.defaultOptions ++ lib.optionals (cfg.colors != { }) [ "--color ${renderedColors cfg.colors}" ];
|
||||
FZF_TMUX = if cfg.tmux.enableShellIntegration then "1" else null;
|
||||
FZF_TMUX_OPTS = cfg.tmux.shellIntegrationOptions;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -120,7 +120,8 @@ in
|
|||
"bezier"
|
||||
"monitor"
|
||||
"size"
|
||||
] ++ lib.optionals cfg.sourceFirst [ "source" ];
|
||||
]
|
||||
++ lib.optionals cfg.sourceFirst [ "source" ];
|
||||
example = [
|
||||
"$"
|
||||
"bezier"
|
||||
|
|
|
|||
|
|
@ -28,8 +28,7 @@ in
|
|||
# Errors out if the symlink already exists
|
||||
"${ide}/bin/${ide.meta.mainProgram}-remote-dev-server registerBackendLocationForGateway || true";
|
||||
lines = map mkLine cfg.ides;
|
||||
linesStr =
|
||||
''
|
||||
linesStr = ''
|
||||
rm $HOME/.cache/JetBrains/RemoteDev/userProvidedDist/_nix_store* || true
|
||||
''
|
||||
+ lib.concatStringsSep "\n" lines;
|
||||
|
|
|
|||
|
|
@ -301,8 +301,7 @@ in
|
|||
(mkOrder 570 (toKittyEnv cfg.environment))
|
||||
];
|
||||
|
||||
xdg.configFile."kitty/kitty.conf" =
|
||||
{
|
||||
xdg.configFile."kitty/kitty.conf" = {
|
||||
text = ''
|
||||
# Generated by Home Manager.
|
||||
# See https://sw.kovidgoyal.net/kitty/conf.html
|
||||
|
|
|
|||
|
|
@ -106,8 +106,7 @@ in
|
|||
MANGOHUD_DLSYM = 1;
|
||||
};
|
||||
|
||||
xdg.configFile =
|
||||
{
|
||||
xdg.configFile = {
|
||||
"MangoHud/MangoHud.conf" = mkIf (cfg.settings != { }) { text = renderSettings cfg.settings; };
|
||||
}
|
||||
// lib.mapAttrs' (
|
||||
|
|
|
|||
|
|
@ -22,8 +22,7 @@ let
|
|||
# See: https://github.com/nix-community/home-manager/issues/6663
|
||||
# and https://github.com/bnprks/mcfly-fzf/issues/10
|
||||
|
||||
bashIntegration =
|
||||
''
|
||||
bashIntegration = ''
|
||||
eval "$(${getExe cfg.package} init bash)"
|
||||
''
|
||||
+ optionalString cfg.fzf.enable ''
|
||||
|
|
@ -32,16 +31,14 @@ let
|
|||
fi
|
||||
'';
|
||||
|
||||
fishIntegration =
|
||||
''
|
||||
fishIntegration = ''
|
||||
${getExe cfg.package} init fish | source
|
||||
''
|
||||
+ optionalString cfg.fzf.enable ''
|
||||
${getExe cfg.mcflyFzfPackage} init fish | source
|
||||
'';
|
||||
|
||||
zshIntegration =
|
||||
''
|
||||
zshIntegration = ''
|
||||
eval "$(${getExe cfg.package} init zsh)"
|
||||
''
|
||||
+ optionalString cfg.fzf.enable ''
|
||||
|
|
|
|||
|
|
@ -84,8 +84,7 @@ in
|
|||
(mkIf (cfg.ignores != [ ] || cfg.ignoresRegexp != [ ]) {
|
||||
programs.mercurial.iniContent.ui.ignore = "${config.xdg.configHome}/hg/hgignore_global";
|
||||
|
||||
xdg.configFile."hg/hgignore_global".text =
|
||||
''
|
||||
xdg.configFile."hg/hgignore_global".text = ''
|
||||
syntax: glob
|
||||
''
|
||||
+ lib.concatStringsSep "\n" cfg.ignores
|
||||
|
|
|
|||
|
|
@ -99,6 +99,7 @@ in
|
|||
".ne/.keys" = mkIf (cfg.keybindings != "") { text = cfg.keybindings; };
|
||||
".ne/.extensions" = mkIf (cfg.virtualExtensions != "") { text = cfg.virtualExtensions; };
|
||||
".ne/.menus" = mkIf (cfg.menus != "") { text = cfg.menus; };
|
||||
} // autoPrefFiles;
|
||||
}
|
||||
// autoPrefFiles;
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -109,7 +109,8 @@ in
|
|||
"${lib.getExe cfg.package}"
|
||||
"clean"
|
||||
"user"
|
||||
] ++ lib.optional (cfg.clean.extraArgs != "") cfg.clean.extraArgs;
|
||||
]
|
||||
++ lib.optional (cfg.clean.extraArgs != "") cfg.clean.extraArgs;
|
||||
|
||||
StartCalendarInterval = lib.hm.darwin.mkCalendarInterval cfg.clean.dates;
|
||||
|
||||
|
|
|
|||
|
|
@ -532,8 +532,7 @@ in
|
|||
vaults = builtins.listToAttrs (
|
||||
builtins.map (vault: {
|
||||
name = builtins.hashString "md5" vault.target;
|
||||
value =
|
||||
{
|
||||
value = {
|
||||
path = "${config.home.homeDirectory}/${vault.target}";
|
||||
}
|
||||
// (lib.attrsets.optionalAttrs ((builtins.length vaults) == 1) {
|
||||
|
|
|
|||
|
|
@ -65,8 +65,7 @@ let
|
|||
};
|
||||
in
|
||||
toIni {
|
||||
"Account ${name}" =
|
||||
{
|
||||
"Account ${name}" = {
|
||||
localrepository = "${name}-local";
|
||||
remoterepository = "${name}-remote";
|
||||
}
|
||||
|
|
@ -76,10 +75,10 @@ let
|
|||
"Repository ${name}-local" = {
|
||||
type = localType;
|
||||
localfolders = account.maildir.absPath;
|
||||
} // offlineimap.extraConfig.local;
|
||||
}
|
||||
// offlineimap.extraConfig.local;
|
||||
|
||||
"Repository ${name}-remote" =
|
||||
{
|
||||
"Repository ${name}-remote" = {
|
||||
type = remoteType;
|
||||
remoteuser = account.userName;
|
||||
}
|
||||
|
|
@ -189,8 +188,7 @@ in
|
|||
''
|
||||
}/bin/get_settings.pyc";
|
||||
|
||||
xdg.configFile."offlineimap/config".text =
|
||||
''
|
||||
xdg.configFile."offlineimap/config".text = ''
|
||||
# Generated by Home Manager.
|
||||
# See https://github.com/OfflineIMAP/offlineimap/blob/master/offlineimap.conf
|
||||
# for an exhaustive list of options.
|
||||
|
|
@ -201,12 +199,14 @@ in
|
|||
accounts = lib.concatMapStringsSep "," (a: a.name) accounts;
|
||||
pythonfile = "${config.xdg.configHome}/offlineimap/get_settings.py";
|
||||
metadata = "${config.xdg.dataHome}/offlineimap";
|
||||
} // cfg.extraConfig.general;
|
||||
}
|
||||
// cfg.extraConfig.general;
|
||||
}
|
||||
// lib.optionalAttrs (cfg.extraConfig.mbnames != { }) {
|
||||
mbnames = {
|
||||
enabled = true;
|
||||
} // cfg.extraConfig.mbnames;
|
||||
}
|
||||
// cfg.extraConfig.mbnames;
|
||||
}
|
||||
// lib.optionalAttrs (cfg.extraConfig.default != { }) {
|
||||
DEFAULT = cfg.extraConfig.default;
|
||||
|
|
|
|||
|
|
@ -176,8 +176,9 @@ in
|
|||
let
|
||||
resolvedExtraLuaPackages = cfg.extraLuaPackages pkgs.lua54Packages;
|
||||
|
||||
pathPackages =
|
||||
[ cfg.package ]
|
||||
pathPackages = [
|
||||
cfg.package
|
||||
]
|
||||
++ cfg.extraPackages
|
||||
++ lib.optional (cfg.configType == "lua" && cfg.luaPackage != null) cfg.luaPackage;
|
||||
|
||||
|
|
|
|||
|
|
@ -135,8 +135,7 @@ in
|
|||
{ home.packages = lib.mkIf (cfg.package != null) [ cfg.package ]; }
|
||||
|
||||
(lib.mkIf pkgs.stdenv.hostPlatform.isLinux {
|
||||
xdg.configFile =
|
||||
{
|
||||
xdg.configFile = {
|
||||
"streamlink/config" = lib.mkIf (cfg.settings != { }) {
|
||||
text = renderSettings cfg.settings;
|
||||
};
|
||||
|
|
@ -168,8 +167,7 @@ in
|
|||
})
|
||||
|
||||
(lib.mkIf pkgs.stdenv.hostPlatform.isDarwin {
|
||||
home.file =
|
||||
{
|
||||
home.file = {
|
||||
"Library/Application Support/streamlink/config" = lib.mkIf (cfg.settings != { }) {
|
||||
text = renderSettings cfg.settings;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -54,8 +54,7 @@ let
|
|||
profilesIni =
|
||||
lib.foldl lib.recursiveUpdate
|
||||
{
|
||||
General =
|
||||
{
|
||||
General = {
|
||||
StartWithLastProfile = 1;
|
||||
}
|
||||
// lib.optionalAttrs (cfg.profileVersion != null) {
|
||||
|
|
@ -882,11 +881,13 @@ in
|
|||
|
||||
home.packages = [
|
||||
cfg.package
|
||||
] ++ lib.optional (lib.any (p: p.withExternalGnupg) (attrValues cfg.profiles)) pkgs.gpgme;
|
||||
]
|
||||
++ lib.optional (lib.any (p: p.withExternalGnupg) (attrValues cfg.profiles)) pkgs.gpgme;
|
||||
|
||||
mozilla.thunderbirdNativeMessagingHosts = [
|
||||
cfg.package # package configured native messaging hosts (entire mail app actually)
|
||||
] ++ cfg.nativeMessagingHosts; # user configured native messaging hosts
|
||||
]
|
||||
++ cfg.nativeMessagingHosts; # user configured native messaging hosts
|
||||
|
||||
home.file = lib.mkMerge (
|
||||
[
|
||||
|
|
|
|||
|
|
@ -357,8 +357,9 @@ in
|
|||
config = lib.mkIf cfg.enable (
|
||||
lib.mkMerge [
|
||||
{
|
||||
home.packages =
|
||||
[ cfg.package ]
|
||||
home.packages = [
|
||||
cfg.package
|
||||
]
|
||||
++ lib.optional cfg.tmuxinator.enable pkgs.tmuxinator
|
||||
++ lib.optional cfg.tmuxp.enable pkgs.tmuxp;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -142,8 +142,7 @@ in
|
|||
config = lib.mkIf cfg.enable {
|
||||
home.packages = [ cfg.package ];
|
||||
|
||||
xresources.properties =
|
||||
{
|
||||
xresources.properties = {
|
||||
"URxvt.scrollBar" = cfg.scroll.bar.enable;
|
||||
"URxvt.scrollstyle" = cfg.scroll.bar.style;
|
||||
"URxvt.scrollBar_align" = cfg.scroll.bar.align;
|
||||
|
|
|
|||
|
|
@ -259,8 +259,7 @@ let
|
|||
allProfilesExceptDefault = removeAttrs cfg.profiles [ "default" ];
|
||||
in
|
||||
{
|
||||
imports =
|
||||
[
|
||||
imports = [
|
||||
./haskell.nix
|
||||
(lib.mkChangedOptionModule
|
||||
[
|
||||
|
|
@ -272,7 +271,8 @@ in
|
|||
(config: !config.programs.vscode.immutableExtensionsDir)
|
||||
)
|
||||
]
|
||||
++ map
|
||||
++
|
||||
map
|
||||
(
|
||||
v:
|
||||
lib.mkRenamedOptionModule
|
||||
|
|
|
|||
|
|
@ -62,6 +62,7 @@ in
|
|||
|
||||
programs.vscode.profiles.default.extensions = [
|
||||
pkgs.vscode-extensions.justusadam.language-haskell
|
||||
] ++ lib.optional cfg.hie.enable pkgs.vscode-extensions.alanz.vscode-hie-server;
|
||||
]
|
||||
++ lib.optional cfg.hie.enable pkgs.vscode-extensions.alanz.vscode-hie-server;
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -227,8 +227,7 @@ in
|
|||
nushell.extraConfig = mkIf cfg.enableNushellIntegration nushellIntegration;
|
||||
};
|
||||
|
||||
xdg.configFile =
|
||||
{
|
||||
xdg.configFile = {
|
||||
"yazi/keymap.toml" = mkIf (cfg.keymap != { }) {
|
||||
source = tomlFormat.generate "yazi-keymap" cfg.keymap;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -154,11 +154,13 @@ in
|
|||
"/run/current-system/sw"
|
||||
config.home.profileDirectory
|
||||
cfg.iconTheme.package
|
||||
] ++ optional useCustomTheme hicolorTheme.package;
|
||||
]
|
||||
++ optional useCustomTheme hicolorTheme.package;
|
||||
|
||||
themes = [
|
||||
cfg.iconTheme
|
||||
] ++ optional useCustomTheme (hicolorTheme // { size = cfg.iconTheme.size; });
|
||||
]
|
||||
++ optional useCustomTheme (hicolorTheme // { size = cfg.iconTheme.size; });
|
||||
|
||||
categories = [
|
||||
"actions"
|
||||
|
|
|
|||
|
|
@ -22,7 +22,8 @@ let
|
|||
|
||||
finalConfig = {
|
||||
inherit (cfg) order;
|
||||
} // cfg.extraConfig;
|
||||
}
|
||||
// cfg.extraConfig;
|
||||
|
||||
configFile = jsonFormat.generate "dwm-status.json" finalConfig;
|
||||
|
||||
|
|
|
|||
|
|
@ -129,10 +129,8 @@ in
|
|||
}
|
||||
|
||||
(mkIf pkgs.stdenv.isLinux {
|
||||
systemd.user.services.emacs =
|
||||
{
|
||||
Unit =
|
||||
{
|
||||
systemd.user.services.emacs = {
|
||||
Unit = {
|
||||
Description = "Emacs text editor";
|
||||
Documentation = "info:emacs man:emacs(1) https://gnu.org/software/emacs/";
|
||||
|
||||
|
|
@ -150,8 +148,7 @@ in
|
|||
RefuseManualStart = true;
|
||||
};
|
||||
|
||||
Service =
|
||||
{
|
||||
Service = {
|
||||
Type = "notify";
|
||||
|
||||
# We wrap ExecStart in a login shell so Emacs starts with the user's
|
||||
|
|
@ -227,7 +224,8 @@ in
|
|||
ProgramArguments = [
|
||||
"${cfg.package}/bin/emacs"
|
||||
"--fg-daemon"
|
||||
] ++ cfg.extraOptions;
|
||||
]
|
||||
++ cfg.extraOptions;
|
||||
RunAtLoad = true;
|
||||
KeepAlive = {
|
||||
Crashed = true;
|
||||
|
|
|
|||
|
|
@ -23,27 +23,23 @@ let
|
|||
${gpgPkg}/bin/gpg-connect-agent --quiet updatestartuptty /bye > /dev/null
|
||||
'';
|
||||
|
||||
gpgInitStr =
|
||||
''
|
||||
gpgInitStr = ''
|
||||
GPG_TTY="$(tty)"
|
||||
export GPG_TTY
|
||||
''
|
||||
+ optionalString cfg.enableSshSupport gpgSshSupportStr;
|
||||
|
||||
gpgZshInitStr =
|
||||
''
|
||||
gpgZshInitStr = ''
|
||||
export GPG_TTY=$TTY
|
||||
''
|
||||
+ optionalString cfg.enableSshSupport gpgSshSupportStr;
|
||||
|
||||
gpgFishInitStr =
|
||||
''
|
||||
gpgFishInitStr = ''
|
||||
set -gx GPG_TTY (tty)
|
||||
''
|
||||
+ optionalString cfg.enableSshSupport gpgSshSupportStr;
|
||||
|
||||
gpgNushellInitStr =
|
||||
''
|
||||
gpgNushellInitStr = ''
|
||||
$env.GPG_TTY = (tty)
|
||||
''
|
||||
+ optionalString cfg.enableSshSupport ''
|
||||
|
|
@ -439,7 +435,8 @@ in
|
|||
ProgramArguments = [
|
||||
"${gpgPkg}/bin/gpg-agent"
|
||||
"--supervised"
|
||||
] ++ optional cfg.verbose "--verbose";
|
||||
]
|
||||
++ optional cfg.verbose "--verbose";
|
||||
EnvironmentVariables = {
|
||||
GNUPGHOME = homedir;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -131,7 +131,8 @@ in
|
|||
RestartSec = "10";
|
||||
};
|
||||
};
|
||||
} // transitionServices;
|
||||
}
|
||||
// transitionServices;
|
||||
|
||||
timers = lib.mapAttrs' (
|
||||
name: transitionCfg:
|
||||
|
|
|
|||
|
|
@ -44,8 +44,9 @@ let
|
|||
Restart = "always";
|
||||
RestartSec = 30;
|
||||
Type = "simple";
|
||||
Environment =
|
||||
[ "PATH=${cfg.path}" ]
|
||||
Environment = [
|
||||
"PATH=${cfg.path}"
|
||||
]
|
||||
++ lib.optional account.notmuch.enable "NOTMUCH_CONFIG=${config.xdg.configHome}/notmuch/default/config";
|
||||
};
|
||||
|
||||
|
|
@ -64,8 +65,7 @@ let
|
|||
name = "imapnotify-${name}";
|
||||
value = {
|
||||
enable = true;
|
||||
config =
|
||||
{
|
||||
config = {
|
||||
# Use the nix store path for config to ensure service restarts when it changes
|
||||
ProgramArguments = [
|
||||
"${lib.getExe cfg.package}"
|
||||
|
|
|
|||
|
|
@ -90,8 +90,7 @@ in
|
|||
systemd.user = {
|
||||
services.ludusavi = {
|
||||
Unit.Description = "Run a game save backup with Ludusavi";
|
||||
Service =
|
||||
{
|
||||
Service = {
|
||||
Type = "oneshot";
|
||||
ExecStart = "${lib.getExe cfg.package} backup --force";
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,8 +9,9 @@ let
|
|||
|
||||
cfg = config.services.mbsync;
|
||||
|
||||
mbsyncOptions =
|
||||
[ "--all" ]
|
||||
mbsyncOptions = [
|
||||
"--all"
|
||||
]
|
||||
++ lib.optional (cfg.verbose) "--verbose"
|
||||
++ lib.optional (cfg.configFile != null) "--config ${cfg.configFile}";
|
||||
|
||||
|
|
@ -82,8 +83,7 @@ in
|
|||
Description = "mbsync mailbox synchronization";
|
||||
};
|
||||
|
||||
Service =
|
||||
{
|
||||
Service = {
|
||||
Type = "oneshot";
|
||||
ExecStart = "${cfg.package}/bin/mbsync ${lib.concatStringsSep " " mbsyncOptions}";
|
||||
}
|
||||
|
|
|
|||
|
|
@ -228,7 +228,8 @@ in
|
|||
(lib.getExe cfg.package)
|
||||
"--no-daemon"
|
||||
"${mpdConf}"
|
||||
] ++ cfg.extraArgs;
|
||||
]
|
||||
++ cfg.extraArgs;
|
||||
KeepAlive = true;
|
||||
ProcessType = "Interactive";
|
||||
};
|
||||
|
|
|
|||
|
|
@ -19,8 +19,7 @@ let
|
|||
};
|
||||
|
||||
mpdris2Conf = {
|
||||
Connection =
|
||||
{
|
||||
Connection = {
|
||||
host = cfg.mpd.host;
|
||||
port = cfg.mpd.port;
|
||||
music_dir = cfg.mpd.musicDirectory;
|
||||
|
|
|
|||
|
|
@ -118,7 +118,8 @@ in
|
|||
config = {
|
||||
ProgramArguments = [
|
||||
"${nixPackage}/bin/nix-collect-garbage"
|
||||
] ++ lib.optional (cfg.options != null) cfg.options;
|
||||
]
|
||||
++ lib.optional (cfg.options != null) cfg.options;
|
||||
StartCalendarInterval = lib.hm.darwin.mkCalendarInterval cfg.frequency;
|
||||
};
|
||||
};
|
||||
|
|
|
|||
|
|
@ -218,8 +218,11 @@ in
|
|||
{
|
||||
Description = "${programName} colour temperature adjuster";
|
||||
Documentation = serviceDocumentation;
|
||||
After =
|
||||
[ "graphical-session.target" ] ++ (lib.optional cfg.tray "tray.target") ++ geoclueAgentService;
|
||||
After = [
|
||||
"graphical-session.target"
|
||||
]
|
||||
++ (lib.optional cfg.tray "tray.target")
|
||||
++ geoclueAgentService;
|
||||
Wants = geoclueAgentService;
|
||||
Requires = lib.mkIf cfg.tray "tray.target";
|
||||
PartOf = [ "graphical-session.target" ];
|
||||
|
|
|
|||
|
|
@ -395,8 +395,7 @@ in
|
|||
After = [ "network-online.target" ];
|
||||
};
|
||||
|
||||
Service =
|
||||
{
|
||||
Service = {
|
||||
Type = "oneshot";
|
||||
|
||||
X-RestartIfChanged = true;
|
||||
|
|
@ -405,8 +404,7 @@ in
|
|||
CacheDirectoryMode = "0700";
|
||||
PrivateTmp = true;
|
||||
|
||||
Environment =
|
||||
[
|
||||
Environment = [
|
||||
"RESTIC_CACHE_DIR=%C"
|
||||
"PATH=${backup.ssh-package}/bin"
|
||||
]
|
||||
|
|
|
|||
|
|
@ -250,7 +250,8 @@ in
|
|||
"$"
|
||||
"bezier"
|
||||
"name"
|
||||
] ++ lib.optionals cfg.sourceFirst [ "source" ];
|
||||
]
|
||||
++ lib.optionals cfg.sourceFirst [ "source" ];
|
||||
example = [
|
||||
"$"
|
||||
"bezier"
|
||||
|
|
@ -334,7 +335,8 @@ in
|
|||
BindsTo = [ "graphical-session.target" ];
|
||||
Wants = [
|
||||
"graphical-session-pre.target"
|
||||
] ++ lib.optional cfg.systemd.enableXdgAutostart "xdg-desktop-autostart.target";
|
||||
]
|
||||
++ lib.optional cfg.systemd.enableXdgAutostart "xdg-desktop-autostart.target";
|
||||
After = [ "graphical-session-pre.target" ];
|
||||
Before = lib.mkIf cfg.systemd.enableXdgAutostart [ "xdg-desktop-autostart.target" ];
|
||||
};
|
||||
|
|
|
|||
|
|
@ -48,8 +48,7 @@ let
|
|||
};
|
||||
|
||||
startupModule = types.submodule {
|
||||
options =
|
||||
{
|
||||
options = {
|
||||
command = mkOption {
|
||||
type = types.str;
|
||||
description = "Command that will be executed on startup.";
|
||||
|
|
|
|||
|
|
@ -718,7 +718,8 @@ in
|
|||
BindsTo = [ "graphical-session.target" ];
|
||||
Wants = [
|
||||
"graphical-session-pre.target"
|
||||
] ++ optional cfg.systemd.xdgAutostart "xdg-desktop-autostart.target";
|
||||
]
|
||||
++ optional cfg.systemd.xdgAutostart "xdg-desktop-autostart.target";
|
||||
After = [ "graphical-session-pre.target" ];
|
||||
Before = optional cfg.systemd.xdgAutostart "xdg-desktop-autostart.target";
|
||||
};
|
||||
|
|
|
|||
|
|
@ -201,8 +201,7 @@ in
|
|||
];
|
||||
|
||||
home.packages =
|
||||
lib.optional (cfg.package != null) cfg.package
|
||||
++ lib.optional cfg.xwayland.enable pkgs.xwayland;
|
||||
lib.optional (cfg.package != null) cfg.package ++ lib.optional cfg.xwayland.enable pkgs.xwayland;
|
||||
|
||||
# Configuration file ~/.config/river/init
|
||||
xdg.configFile."river/init".source = pkgs.writeShellScript "init" (
|
||||
|
|
|
|||
|
|
@ -167,7 +167,8 @@ in
|
|||
Service = {
|
||||
Type = if cfg.once then "oneshot" else "simple";
|
||||
ExecStart = "${script}";
|
||||
} // lib.optionalAttrs (!cfg.once) { Restart = "always"; };
|
||||
}
|
||||
// lib.optionalAttrs (!cfg.once) { Restart = "always"; };
|
||||
Install.WantedBy = [ "graphical-session.target" ];
|
||||
};
|
||||
};
|
||||
|
|
|
|||
|
|
@ -31,7 +31,8 @@ let
|
|||
osConfig = config;
|
||||
osClass = _class;
|
||||
modulesPath = builtins.toString ../modules;
|
||||
} // cfg.extraSpecialArgs;
|
||||
}
|
||||
// cfg.extraSpecialArgs;
|
||||
modules = [
|
||||
(
|
||||
{ name, ... }:
|
||||
|
|
@ -62,7 +63,8 @@ let
|
|||
};
|
||||
}
|
||||
)
|
||||
] ++ cfg.sharedModules;
|
||||
]
|
||||
++ cfg.sharedModules;
|
||||
};
|
||||
|
||||
in
|
||||
|
|
|
|||
|
|
@ -13,9 +13,7 @@ let
|
|||
|
||||
dynDir = testDir.overrideAttrs (
|
||||
final: prev: {
|
||||
buildCommand =
|
||||
prev.buildCommand
|
||||
+ ''
|
||||
buildCommand = prev.buildCommand + ''
|
||||
echo more secret data > $out/top-secret
|
||||
echo shhhh > $out/top-secret-v2
|
||||
echo this isnt secret > $out/metadata
|
||||
|
|
|
|||
|
|
@ -3,8 +3,7 @@
|
|||
{
|
||||
config = {
|
||||
programs.htop.enable = true;
|
||||
programs.htop.settings =
|
||||
{
|
||||
programs.htop.settings = {
|
||||
color_scheme = 6;
|
||||
cpu_count_from_one = 0;
|
||||
delay = 15;
|
||||
|
|
|
|||
|
|
@ -35,8 +35,7 @@
|
|||
};
|
||||
};
|
||||
|
||||
nmt.script =
|
||||
''
|
||||
nmt.script = ''
|
||||
assertFileExists home-files/.config/kitty/kitty.conf
|
||||
assertFileContent \
|
||||
home-files/.config/kitty/kitty.conf \
|
||||
|
|
|
|||
|
|
@ -42,7 +42,8 @@ espansoExtraArgs: {
|
|||
];
|
||||
};
|
||||
};
|
||||
} // espansoExtraArgs;
|
||||
}
|
||||
// espansoExtraArgs;
|
||||
|
||||
nmt.script = ''
|
||||
serviceFile=home-files/.config/systemd/user/espanso.service
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue