{ ... }: {
  flake.homeManagerModules.wisdomEditorsObsidian =
    { config, lib, pkgs, ... }:
    let
      root = config.chiasson.home;
      cfg = config.chiasson.home.editors.obsidian;
    in
    {
      options.chiasson.home.editors.obsidian.enable = lib.mkEnableOption ''
        Obsidian (unfree); skipped if unavailable here.
      '';

      config = lib.mkIf (root.enable && cfg.enable) {
        home.packages = lib.optional (
          lib.meta.availableOn pkgs.stdenv.hostPlatform pkgs.obsidian
        ) pkgs.obsidian;
      };
    };
}
