# How to Enable Always-On Mode for i-have-adhd in Claude Code

> Easily enable always-on mode for i-have-adhd in Claude Code by creating a flag file. Activate ADHD mode automatically in every session. Learn how now.

- Repository: [Ayoub Ghriss/i-have-adhd](https://github.com/ayghri/i-have-adhd)
- Tags: how-to-guide
- Published: 2026-07-31

---

**Create a flag file at `~/.claude/.i-have-adhd-always` to automatically activate ADHD mode in every Claude Code session without manual invocation.**

The `ayghri/i-have-adhd` repository provides a Claude Code skill that helps manage ADHD-related workflows during coding sessions. While you can manually trigger the skill with `/i-have-adhd`, enabling **always-on mode** ensures the ruleset from [`SKILL.md`](https://github.com/ayghri/i-have-adhd/blob/main/SKILL.md) injects automatically at session startup.

## How the Always-On Mechanism Works

Claude Code executes **SessionStart hooks** defined in [[`hooks/hooks.json`](https://github.com/ayghri/i-have-adhd/blob/main/hooks/hooks.json)](https://github.com/ayghri/i-have-adhd/blob/main/hooks/hooks.json) every time a new session begins. One of these hooks triggers [[`hooks/always-on.sh`](https://github.com/ayghri/i-have-adhd/blob/main/hooks/always-on.sh)](https://github.com/ayghri/i-have-adhd/blob/main/hooks/always-on.sh), which implements the persistent activation logic:

1. **Flag file detection**: The script checks for the existence of `$HOME/.claude/.i-have-adhd-always` (or the path specified by the `CLAUDE_CONFIG_DIR` environment variable).
2. **Ruleset injection**: If the flag exists, the script reads [[`skills/i-have-adhd/SKILL.md`](https://github.com/ayghri/i-have-adhd/blob/main/skills/i-have-adhd/SKILL.md)](https://github.com/ayghri/i-have-adhd/blob/main/skills/i-have-adhd/SKILL.md), strips YAML front-matter, and prints an activation banner.
3. **Silent exit**: If the flag is missing, the script exits silently, allowing normal session startup.

## Step-by-Step Setup

### Enable Always-On Mode (Permanent)

Run this command once per user account to create the flag file:

```bash
touch ~/.claude/.i-have-adhd-always

```

The repository's [[`README.md`](https://github.com/ayghri/i-have-adhd/blob/main/README.md)](https://github.com/ayghri/i-have-adhd/blob/main/README.md) documents this shortcut as the official method for persistent activation.

### Verify the Installation

Start a new Claude Code session:

```bash
claude code

```

You should see the activation banner:

```

ADHD MODE ACTIVE (always-on). The ruleset below applies to every response. "stop adhd mode" turns it off for this session; delete /home/youruser/.claude/.i-have-adhd-always to turn always‑on off for good.

<rules from SKILL.md>

```

### Disable for Current Session

Type the following command in any active Claude Code session to temporarily deactivate ADHD mode:

```text
stop adhd mode

```

This affects only the current session; the next session will reactivate automatically if the flag file remains.

### Remove Always-On Permanently

Delete the flag file to disable automatic activation across all future sessions:

```bash
rm ~/.claude/.i-have-adhd-always

```

## Configuration Details

**Flag File Location**: By default, the script searches `$HOME/.claude/.i-have-adhd-always`. You can override this by setting the `CLAUDE_CONFIG_DIR` environment variable before Claude Code launches, in which case the script checks `$CLAUDE_CONFIG_DIR/.i-have-adhd-always`.

**Ruleset Source**: The [[`SKILL.md`](https://github.com/ayghri/i-have-adhd/blob/main/SKILL.md)](https://github.com/ayghri/i-have-adhd/blob/main/skills/i-have-adhd/SKILL.md) file contains the complete behavior rules that define ADHD mode. The [`always-on.sh`](https://github.com/ayghri/i-have-adhd/blob/main/always-on.sh) script automatically strips any leading YAML front-matter and injects the remaining content into the session context.

## Summary

- **Always-on mode** activates automatically via SessionStart hooks in [`hooks/hooks.json`](https://github.com/ayghri/i-have-adhd/blob/main/hooks/hooks.json) running [`hooks/always-on.sh`](https://github.com/ayghri/i-have-adhd/blob/main/hooks/always-on.sh).
- Create `~/.claude/.i-have-adhd-always` to enable permanent activation across all sessions.
- Type `stop adhd mode` to disable the current session without removing the flag file.
- Delete the flag file or set `CLAUDE_CONFIG_DIR` to a custom path for advanced configuration.

## Frequently Asked Questions

### What happens if I delete the flag file mid-session?

Deleting `~/.claude/.i-have-adhd-always` during an active session does not affect the current session. The check occurs only at session startup through the SessionStart hook. You must either start a new session or type `stop adhd mode` to deactivate the current session.

### Can I use a custom configuration directory?

Yes. Set the `CLAUDE_CONFIG_DIR` environment variable before launching Claude Code. The [`always-on.sh`](https://github.com/ayghri/i-have-adhd/blob/main/always-on.sh) script checks `$CLAUDE_CONFIG_DIR/.i-have-adhd-always` instead of the default `$HOME/.claude/.i-have-adhd-always` when this variable is present.

### Why do I see the ruleset printed at session start?

When the flag file exists, the [`always-on.sh`](https://github.com/ayghri/i-have-adhd/blob/main/always-on.sh) script reads [`skills/i-have-adhd/SKILL.md`](https://github.com/ayghri/i-have-adhd/blob/main/skills/i-have-adhd/SKILL.md) and outputs the full ruleset as a banner. This confirms that ADHD mode is active and serves as a reminder that the specialized behavior rules are governing the session.

### Does always-on mode affect Claude Code performance?

No. The activation adds minimal overhead—a single file existence check and text output at session startup. The [`SKILL.md`](https://github.com/ayghri/i-have-adhd/blob/main/SKILL.md) content loads into the session context, but this occurs through standard Claude Code hook mechanisms without impacting runtime performance.