Skip to content

Commit

Permalink
feat: add obsidian modules and mount for it
Browse files Browse the repository at this point in the history
  • Loading branch information
sbulav committed Sep 12, 2024
1 parent afb6985 commit 531c125
Show file tree
Hide file tree
Showing 4 changed files with 50 additions and 1 deletion.
4 changes: 4 additions & 0 deletions nix/homes/x86_64-linux/sab@nz/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,10 @@ in {
};
};

apps = {
obsidian = enabled;
};

cli-apps = {
argocd = enabled;
atuin = enabled;
Expand Down
19 changes: 19 additions & 0 deletions nix/modules/darwin/apps/obsidian/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
lib,
config,
...
}:
with lib;
with lib.custom; let
cfg = config.custom.apps.obsidian;
in {
options.custom.desktop.obsidian = {
enable = mkEnableOption "Enable Obsidian note-taking app";
};

config = mkIf cfg.enable {
homebrew = {
casks = ["obsidian"];
};
};
}
20 changes: 20 additions & 0 deletions nix/modules/home/apps/obsidian/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
lib,
config,
pkgs,
...
}: let
inherit (lib) mkEnableOption mkIf;

cfg = config.custom.apps.obsidian;
in {
options.custom.apps.obsidian = {
enable = mkEnableOption "Enable Obsidian note-taking app";
};

config = mkIf cfg.enable {
home.packages = with pkgs; [
obsidian
];
};
}
8 changes: 7 additions & 1 deletion nix/systems/x86_64-linux/nz/hardware-configuration.nix
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,13 @@

fileSystems."/mnt/tank/torrents" = {
device = "truenas.sbulav.ru:/mnt/tank/torrents";
options = ["x-systemd.automount" "x-systemd.idle-timeout=600" "noauto"];
options = ["x-systemd.automount" "x-systemd.idle-timeout=60" "noauto"];
fsType = "nfs";
};

fileSystems."/mnt/obsidian" = {
device = "truenas.sbulav.ru:/mnt/tank/Apps/obsidian";
options = ["x-systemd.automount" "x-systemd.idle-timeout=60" "noauto"];
fsType = "nfs";
};

Expand Down

0 comments on commit 531c125

Please sign in to comment.