longline-repo-allowlist

longline-repo-allowlist is a skill for Claude Code from devinbarry/longline. It costs 102 tokens per session (1,779 once invoked), scanned B, original, MIT.

A per-repository setup for deciding which command-line commands may run without a confirmation prompt. It stores the rules in the repository’s `.claude/longline.yaml` file and can make narrower exceptions.

In plain words
What is it for?
Use it to control confirmation rules for tools such as kubectl, Terraform, AWS, Google Cloud, Docker, and similar command families within a specific repository.
Why use it?
It avoids repeated prompts for routine commands in one project while keeping potentially sensitive commands subject to confirmation. Rules are based on commands actually used in that repository.

Skill for Claude Code

Written for Claude Code: PreToolUse hook event. Also seen: reads .claude/ paths.

Good fit Use it to control confirmation rules for tools such as kubectl, Terraform, AWS, Google Cloud, Docker, and similar command families within a specific repository.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/devinbarry/longline/longline-repo-allowlist
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add devinbarry/longline --skill longline-repo-allowlist
Clone the repo
git clone --depth 1 https://github.com/devinbarry/longline

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for longline-repo-allowlist

README.md
[![agentmods](https://agentmods.dev/badge/skills/devinbarry/longline/longline-repo-allowlist/github.svg)](https://agentmods.dev/skills/devinbarry/longline/longline-repo-allowlist)
Your own site
<a href="https://agentmods.dev/skills/devinbarry/longline/longline-repo-allowlist"><img src="https://agentmods.dev/badge/skills/devinbarry/longline/longline-repo-allowlist/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for longline-repo-allowlist

Your own site · 80×15
<a href="https://agentmods.dev/skills/devinbarry/longline/longline-repo-allowlist"><img src="https://agentmods.dev/badge/skills/devinbarry/longline/longline-repo-allowlist.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 102 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,779 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00102 $0.01779
Opus 5 $0.00051 $0.00890
Sonnet 5 $0.00020 $0.00356
Haiku 4.5 $0.00010 $0.00178

Measured 10d ago against content hash 36b915a8b900, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

Grade B, and why

longline-repo-allowlist scanned grade B with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Reads agent configuration directoriesmediumAgent snooping

.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.

grep '"cwd":"/abs/path/to/target-repo' ~/.claude/hooks-logs/longline.jsonl \
skills/longline-repo-allowlist/SKILL.md · 127 lines

How it starts

The opening of the file, as written. The whole thing — 127 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Longline Per-Repo Allowlist

Create or update .claude/longline.yaml in a target repo so specific commands get allow (or a narrower ask) instead of the default ask.

Core mechanism: longline walks up from the hook invocation's cwd looking for .git or .claude, finds <repo>/.claude/longline.yaml, and overlays it on top of the embedded defaults. You never pass --config (that would replace the defaults), never edit the global PreToolUse hook, and never touch ~/.claude/settings.json.

Core technique: rules evaluate before allowlists. That lets you allowlist a broad prefix (oc get) and add a narrow rule that overrides it (oc get secret → ask).

Workflow

1. Identify commands to allow

longline writes every decision to ~/.claude/hooks-logs/longline.jsonl. Filter for the target repo and tool — use real usage, not guesses from docs:

jq -r 'select(.cwd | startswith("/abs/path/to/target-repo"))
       | select(.command | startswith("TOOL "))
       | .command' \
  ~/.claude/hooks-logs/longline.jsonl | sort -u

Quick grep variant if jq isn't handy:

grep '"cwd":"/abs/path/to/target-repo' ~/.claude/hooks-logs/longline.jsonl \
  | grep '"decision":"ask"' | tail -50

2. Classify: safe vs unsafe

Safe → allowlist Unsafe → ask (default)
get, list, describe, logs, status, version, history, explain, api-resources, whoami, auth can-i, config view apply, create, delete, patch, edit, replace, set, scale, rollout undo/restart, exec, rsh, cp, port-forward, login --token, import-image, start-build, debug, new-*

Credential-exposing reads (get secret, extract, describe secret) go in the ask-rule bucket even though they look read-only.

3. Check for compound-command companions

longline flattens compound statements to leaf nodes and the most-restrictive decision wins. export FOO=bar && kubectl get pods has two leaves: export and kubectl. If export isn't allowlisted the whole command asks.

Read the full file on GitHub · 127 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 10d ago First seen · 127 lines · 102 tokens per session scan B 36b915a8b900

Subscribe to this mod's changes

longline-repo-allowlist is a skill published in the GitHub repository devinbarry/longline (5 stars, last pushed 1mo ago), licensed MIT. It adds 102 tokens to every session and 1,779 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it B with 1 finding (reads agent configuration directories). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.