> ## Documentation Index
> Fetch the complete documentation index at: https://docs.jylhis.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Default Applications

> Configure which applications are installed and set as system defaults

When `marchyo.desktop.enable = true`, the `marchyo.defaults.*` options control which applications are installed and registered as system defaults. Set any option to `null` to skip management for that category.

## Options

| Option                                 | Default            | Choices                                                  |
| -------------------------------------- | ------------------ | -------------------------------------------------------- |
| `marchyo.defaults.browser`             | `"google-chrome"`  | `"brave"`, `"google-chrome"`, `"firefox"`, `"chromium"`  |
| `marchyo.defaults.editor`              | `"jotain"`         | `"emacs"`, `"jotain"`, `"vscode"`, `"vscodium"`, `"zed"` |
| `marchyo.defaults.terminalEditor`      | `"jotain"`         | `"emacs"`, `"jotain"`, `"neovim"`, `"helix"`, `"nano"`   |
| `marchyo.defaults.videoPlayer`         | `"mpv"`            | `"mpv"`, `"vlc"`, `"celluloid"`                          |
| `marchyo.defaults.audioPlayer`         | `"mpv"`            | `"mpv"`, `"cmus"`, `"vlc"`, `"amberol"`                  |
| `marchyo.defaults.musicPlayer`         | `"spotify-player"` | `"spotify-player"`, `"ncspot"`, `"spotify"`              |
| `marchyo.defaults.fileManager`         | `"nautilus"`       | `"nautilus"`, `"thunar"`                                 |
| `marchyo.defaults.terminalFileManager` | `"yazi"`           | `"yazi"`, `"ranger"`, `"lf"`                             |
| `marchyo.defaults.imageEditor`         | `"pinta"`          | `"pinta"`, `"gimp"`, `"krita"`                           |
| `marchyo.defaults.email`               | `"aerc"`           | `"aerc"`, `"neomutt"`, `"gmail"`, `"outlook"`            |

## Example

```nix theme={}
marchyo.defaults = {
  browser = "firefox";
  editor = "vscode";
  terminalEditor = "neovim";
  videoPlayer = "mpv";
  audioPlayer = "mpv";        # or "cmus" for a TUI library player
  musicPlayer = "spotify-player";  # TUI Spotify client (floating terminal)
  fileManager = "nautilus";
  terminalFileManager = "yazi";
  imageEditor = "gimp";
  email = "aerc";             # TUI mail client; requires account config
};
```

## Skipping management

Set any option to `null` to prevent Marchyo from installing or configuring that category:

```nix theme={}
marchyo.defaults = {
  browser = null;        # Don't manage browser
  musicPlayer = null;    # Don't install a music player
};
```

## Externally managed applications

Some choices are "externally managed" — Marchyo does not install a package for them:

* **`"gmail"`** and **`"outlook"`** (email) — Web applications opened in the default browser. No package is installed.

## Jotain editor

`"jotain"` is the default `editor` and `terminalEditor` — [Jylhis's Emacs config](https://github.com/Jylhis/jotain), distributed as a flake. When selected, Marchyo enables its `services.jotain` Home-Manager module (installing the Emacs build, the `jotain-editor`/`jotain-visual` wrappers, and `jotain-client.desktop`) and sets `$EDITOR`/`$VISUAL` to those wrappers. Switch `editor` to `"emacs"`/`"vscode"`/… or `terminalEditor` to `"emacs"`/`"neovim"`/… to use a standard editor instead. The two selectors resolve independently, so you can mix (e.g. `editor = "jotain"` with `terminalEditor = "neovim"`).

<Warning>
  jotain is itself a full Emacs distribution, so it cannot share a home profile with another Emacs. Marchyo rejects (at evaluation) mixing `"jotain"` with `"emacs"` across the two selectors, and rejects `marchyo.emacs.enable = true` while either selector is `"jotain"` (both would run an Emacs daemon on the same socket). Use `"jotain"` for both selectors, or `"emacs"` for both — not one of each.
</Warning>

<Note>
  The TUI music (`spotify-player`, `ncspot`) and mail (`aerc`, `neomutt`) clients are installed but require account configuration before use. The music clients launch in a floating terminal under Hyprland (Super+M).
</Note>

## How defaults work

When a default is set, Marchyo:

1. **Installs the package** (unless externally managed)
2. **Registers MIME type associations** — e.g., setting `browser = "firefox"` registers Firefox as the handler for `text/html`, `x-scheme-handler/http`, etc.
3. **Sets environment variables** — e.g., `editor` sets `$VISUAL`, `terminalEditor` sets `$EDITOR`
