9 cfg = config.programs.nautilus-open-any-terminal;
12 options.programs.nautilus-open-any-terminal = {
13 enable = lib.mkEnableOption "nautilus-open-any-terminal";
15 terminal = lib.mkOption {
16 type = with lib.types; nullOr str;
19 The terminal emulator to add to context-entry of nautilus. Supported terminal
20 emulators are listed in https://github.com/Stunkymonkey/nautilus-open-any-terminal#supported-terminal-emulators.
25 config = lib.mkIf cfg.enable {
26 environment.systemPackages = with pkgs; [
28 nautilus-open-any-terminal
31 environment.sessionVariables = lib.mkIf (!config.services.xserver.desktopManager.gnome.enable) {
32 NAUTILUS_4_EXTENSION_DIR = "${pkgs.nautilus-python}/lib/nautilus/extensions-4";
35 environment.pathsToLink = [
36 "/share/nautilus-python/extensions"
39 programs.dconf = lib.optionalAttrs (cfg.terminal != null) {
41 profiles.user.databases = [
43 settings."com/github/stunkymonkey/nautilus-open-any-terminal".terminal = cfg.terminal;
50 maintainers = with lib.maintainers; [