mirror of
https://github.com/Swarsel/.dotfiles.git
synced 2025-12-06 09:07:21 +01:00
feat[client]: reduce file clobbering
This commit is contained in:
parent
101f4d3183
commit
9ce9a7ec6a
4 changed files with 106 additions and 88 deletions
|
|
@ -4227,6 +4227,7 @@ We enable the use of =home-manager= as a NixoS module. A nice trick here is the
|
|||
useGlobalPkgs = true;
|
||||
useUserPackages = true;
|
||||
verbose = true;
|
||||
backupFileExtension = "hm-bak";
|
||||
users.${config.swarselsystems.mainUser}.imports = [
|
||||
inputs.nix-index-database.homeModules.nix-index
|
||||
inputs.sops-nix.homeManagerModules.sops
|
||||
|
|
@ -11577,7 +11578,9 @@ TODO: Non-NixOS machines (=sp3) should not use these by default, but instead the
|
|||
|
||||
};
|
||||
|
||||
xdg.mimeApps = {
|
||||
xdg = {
|
||||
configFile."mimeapps.list".force = true;
|
||||
mimeApps = {
|
||||
enable = true;
|
||||
defaultApplications = {
|
||||
"application/epub+zip" = [ "calibre-ebook-viewer.desktop" ];
|
||||
|
|
@ -11623,6 +11626,7 @@ TODO: Non-NixOS machines (=sp3) should not use these by default, but instead the
|
|||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
#+end_src
|
||||
|
||||
|
|
@ -14529,14 +14533,19 @@ This service changes the screen hue at night. I am not sure if that really does
|
|||
let
|
||||
moduleName = "obsidian";
|
||||
inherit (nixosConfig.repo.secrets.common.obsidian) userIgnoreFilters;
|
||||
name = "Main";
|
||||
in
|
||||
{
|
||||
options.swarselmodules.${moduleName} = lib.mkEnableOption "enable ${moduleName} with settings";
|
||||
config = lib.mkIf config.swarselmodules.${moduleName} {
|
||||
|
||||
home.file = {
|
||||
"${config.programs.obsidian.vaults.${name}.target}/.obsidian/app.json".force = true;
|
||||
"${config.programs.obsidian.vaults.${name}.target}/.obsidian/appearance.json".force = true;
|
||||
"${config.programs.obsidian.vaults.${name}.target}/.obsidian/core-plugins.json".force = true;
|
||||
};
|
||||
|
||||
programs.obsidian =
|
||||
let
|
||||
name = "Main";
|
||||
in
|
||||
{
|
||||
enable = true;
|
||||
package = pkgs.obsidian;
|
||||
|
|
|
|||
|
|
@ -55,7 +55,9 @@
|
|||
|
||||
};
|
||||
|
||||
xdg.mimeApps = {
|
||||
xdg = {
|
||||
configFile."mimeapps.list".force = true;
|
||||
mimeApps = {
|
||||
enable = true;
|
||||
defaultApplications = {
|
||||
"application/epub+zip" = [ "calibre-ebook-viewer.desktop" ];
|
||||
|
|
@ -101,4 +103,5 @@
|
|||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,14 +2,19 @@
|
|||
let
|
||||
moduleName = "obsidian";
|
||||
inherit (nixosConfig.repo.secrets.common.obsidian) userIgnoreFilters;
|
||||
name = "Main";
|
||||
in
|
||||
{
|
||||
options.swarselmodules.${moduleName} = lib.mkEnableOption "enable ${moduleName} with settings";
|
||||
config = lib.mkIf config.swarselmodules.${moduleName} {
|
||||
|
||||
home.file = {
|
||||
"${config.programs.obsidian.vaults.${name}.target}/.obsidian/app.json".force = true;
|
||||
"${config.programs.obsidian.vaults.${name}.target}/.obsidian/appearance.json".force = true;
|
||||
"${config.programs.obsidian.vaults.${name}.target}/.obsidian/core-plugins.json".force = true;
|
||||
};
|
||||
|
||||
programs.obsidian =
|
||||
let
|
||||
name = "Main";
|
||||
in
|
||||
{
|
||||
enable = true;
|
||||
package = pkgs.obsidian;
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@
|
|||
useGlobalPkgs = true;
|
||||
useUserPackages = true;
|
||||
verbose = true;
|
||||
backupFileExtension = "hm-bak";
|
||||
users.${config.swarselsystems.mainUser}.imports = [
|
||||
inputs.nix-index-database.homeModules.nix-index
|
||||
inputs.sops-nix.homeManagerModules.sops
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue