---
name: Anchorify + Aider
---

# Anchorify + Aider

[Aider](https://aider.chat) keeps a per-project chat transcript at
`.aider.chat.history.md`. Sharing that transcript with a teammate
or a client usually means a gist. With Anchorify you publish
it as a stable URL in one command — no gist account, no copy-paste.

## One-off publish

After an Aider session:

```bash
anchorify .aider.chat.history.md
```

You get a public URL on stdout. Re-running the same command after
the next session updates the same share (Anchorify resolves
the file → slug mapping locally), so the URL stays valid across
follow-up sessions.

## Auto-publish on session end

Aider supports lifecycle hooks via shell wrappers. Wrap `aider`
with a small alias that publishes when the session exits:

```bash
# ~/.zshrc or ~/.bashrc
aider() {
  command aider "$@"
  if [[ -f .aider.chat.history.md ]]; then
    url=$(anchorify .aider.chat.history.md 2>/dev/null)
    [[ -n "$url" ]] && echo "↗ aider transcript: $url"
  fi
}
```

The CLI prints only the URL on success (one line, no decoration),
so you can pipe it to `pbcopy` / `xclip` if you'd rather it land
on your clipboard automatically.

## Visibility

Default visibility is `public`. To keep the transcript discoverable
only by people you send the URL to, pass `--unlisted`:

```bash
anchorify .aider.chat.history.md --unlisted
```

For team-internal transcripts that should require sign-in, use
`--members` — the share will redirect to the Anchorify sign-in page for
anyone who isn't a member of your org. See
[guide-visibility](../guide-visibility) for the full tier table.

## Install

```bash
npm i -g anchorify-cli
anchorify login
```

Then create an API token at
<https://anchorify.io/dashboard> and paste it into the
`login` prompt. The token persists in
`~/.config/anchorify/auth.json` (mode 600).
