Skip to content
cccskills
FreePublished on GitHubEnglish overview

fewer-permission-prompts

Review recent Claude Code session logs to find frequently used read-only Bash commands and MCP tools, which connect agents to services. Rank suitable permission rules and merge them into project settings to reduce repeated approval prompts.

OriginalShow the original description

Scan your transcripts for common read-only Bash and MCP tool calls, then add a prioritized allowlist to project .claude/settings.json to reduce permission prompts.

Run score Not tested

See how to install

Good for

  • Reduce prompts for frequently used read-only tools
  • Choose permission rules from actual usage
  • Add project rules while preserving existing settings
  • Exclude overly broad or unnecessary permission rules

Overview

What it does

This skill reviews recent Claude Code sessions and counts calls to Bash commands and MCP tools. MCP connects agents to external services and other systems. It filters for read-only operations, presents permission candidates in a table ranked by frequency, and adds them to permissions.allow in the project's .claude/settings.json.

When it helps

Use it when the same information checks repeatedly trigger permission prompts, or when you want permission settings to reflect actual usage. It examines history across projects, preserves existing settings, and removes duplicates. It also reports entries already present and explains why other operations were excluded.

Example requests

  • “Rank read-only permission candidates from my recent usage and add them to the settings.”
  • “Reduce permission prompts while preserving existing settings and avoiding unnecessarily broad rules.”

Notes

You need a Claude Code environment that can read session history under ~/.claude/projects/. Changes apply to the current project's settings. Operations that write or delete data, broad rules allowing arbitrary code execution, and operations already automatically allowed are excluded. It does not change permissions.deny or permissions.ask.

This overview was written by AI (OpenAI Codex) from the public SKILL.md. Check the original below for the exact behavior.

Document check

AI checked the SKILL.md for operations that need care and for setup requirements. The score comes only from actually running the skill (hands-on test).

SafetyAre sending data, deleting files, and running commands disclosed?
AGoodPermission changes are limited to allow entries, excluding rules that permit arbitrary code execution or writes.
Easy setupDoes it need few tools or API keys, and are they documented?
AGoodIt identifies Claude Code history and settings paths and specifies no additional services.

Not counted in the score. Rated by AI (OpenAI Codex) as of Oct 23, 2026. Treat it as a guide and read the original before installing.

Disagree? Request a re-evaluation

Tell us which point is wrong and why. No login needed. We will check it against the SKILL.md, redo the evaluation, and show the result here.

This form is protected by reCAPTCHA, and the Google Privacy Policy and Terms of Service apply.

Files included (1)

  • SKILL.md7.7 KB

SKILL.md (original)

Review the instructions the agent will receive before you install.

Fewer Permission Prompts

Look through my transcripts' MCP and bash tool calls, and based on those, make a prioritized list of patterns that I should add to my permission allowlist to reduce permission prompts. Focus on read-only commands.

The format for permissions is: Bash(foo*), Bash(foo), Bash(foo bar *), mcp__slack__slack_read_thread, etc.

Then, add these to the project .claude/settings.json under permissions.allow.

Steps

  1. Locate transcripts. Session transcripts live at ~/.claude/projects/<sanitized-cwd>/*.jsonl. Each line is a JSON object. Tool calls appear as assistant messages with message.content[] entries of type: "tool_use". The name field identifies the tool (e.g. "Bash", "mcp__slack__slack_read_thread"); for Bash, input.command is the shell string.

    Scan the recent transcripts across the user's projects dir — not just the current project — so the allowlist reflects their actual usage. Cap the scan at a reasonable number of recent sessions (e.g. 50 most-recently-modified JSONL files) so this stays fast.

  2. Extract tool-call frequencies.

    • For Bash calls: parse input.command, take the leading command token (handling sudo, timeout, pipes, &&, env-var prefixes). Record the command + first subcommand pair (e.g. git status, gh pr view, ls, cat).
    • For MCP calls: record the full tool name (e.g. mcp__slack__slack_read_thread).
    • Count occurrences across the scanned transcripts.
  3. Filter to read-only. Keep only commands that don't mutate state. Examples of read-only: ls, cat, pwd, git status, git log, git diff, git show, git branch, rg, grep, find, head, tail, wc, file, which, echo, date, gh pr view, gh pr list, gh pr diff, gh issue view, gh issue list, gh run list, gh run view, gh api (GET), bun run typecheck, bun run lint, bun run test (for tests that don't mutate), docker ps, docker logs, kubectl get, kubectl describe, ps, top, df, du, env, printenv, any MCP tool with read/get/list/search/view in its name.

    Drop anything that writes, deletes, renames, pushes, merges, installs, or runs a build/test that has side effects. When in doubt, leave it out.

    Never allowlist a pattern that grants arbitrary code execution. A wildcard rule for any of these (e.g. Bash(python3:*)) is equivalent to allowing arbitrary code execution. This list is not exhaustive — apply the same rule to anything in the same category:

    • Interpreters: python/python3, node, bun, deno, ruby, perl, php, lua, etc.
    • Shells: bash, sh, zsh, fish, eval, exec, ssh, etc.
    • Package runners: npx, bunx, uvx, uv run, etc.
    • Task-runner wildcards: npm run *, yarn run *, pnpm run *, bun run *, make *, just *, cargo run *, go run *, etc. — an exact Bash(bun run typecheck) is fine, Bash(bun run *) is not
    • Tools that start an interpreter in the working directory: pyright in any form (it runs python3 there, which imports from that directory first), and similar
    • gh api *, docker run/exec, kubectl exec, sudo, and similar
  4. Drop commands Claude Code already auto-allows. These don't need an allowlist entry — they never prompt. If you see any of these in the transcripts, skip them; don't suggest them to the user.

    • Always auto-allowed (any args): cal, uptime, cat, head, tail, wc, stat, strings, hexdump, od, nl, id, uname, free, df, du, locale, groups, nproc, basename, dirname, realpath, cut, paste, tr, column, tac, rev, fold, expand, unexpand, fmt, comm, cmp, numfmt, readlink, diff, true, false, sleep, which, type, expr, seq, tsort, pr, echo, ls, cd.
    • Auto-allowed with zero args only: pwd, whoami, alias.
    • Auto-allowed exact forms: claude -h, claude --help, node -v, node --version, python --version, python3 --version, ip addr.
    • Auto-allowed with safe flags only (validated): xargs, file, sed (read-only expressions), sort, man, help, netstat, ps, base64, grep, egrep, fgrep, sha256sum, sha1sum, md5sum, tree, date, hostname, lsof, pgrep, tput, ss, fd, fdfind, aki, rg, jq, uniq, history, arch, ifconfig, find (blocks -delete/-exec/-execdir/-ok/-okdir/-fprint*/-fls/-files0-from), printf (blocks any -flag), test (blocks -v/-R/-a/-o).
    • All git read-only subcommands: git status, git log, git diff, git show, git blame, git branch, git tag, git remote, git ls-files, git ls-remote, git config --get, git rev-parse, git describe, git stash list, git reflog, git shortlog, git cat-file, git for-each-ref, git worktree list, etc.
    • All gh read-only subcommands: gh pr view, gh pr list, gh pr diff, gh pr checks, gh pr status, gh issue view, gh issue list, gh issue status, gh run view, gh run list, gh workflow list, gh workflow view, gh repo view, gh release view, gh release list, gh api (GET), gh auth status, etc.
    • Docker read-only subcommands: docker ps, docker images, docker logs, docker inspect.

    Source of truth: src/tools/BashTool/readOnlyValidation.ts (READONLY_COMMANDS, READONLY_NOARGS, READONLY_EXACT, COMMAND_ALLOWLIST) and src/utils/shell/readOnlyCommandValidation.ts (GIT_READ_ONLY_COMMANDS, GH_READ_ONLY_COMMANDS, DOCKER_READ_ONLY_COMMANDS, RIPGREP_READ_ONLY_COMMANDS). If the user is in this repo and you're unsure whether a command is covered, grep these files rather than guessing.

  5. Pick the pattern form. Use the narrowest pattern that still covers the observed usage:

    • If the user runs many variants (git log, git log --oneline, git log main..HEAD): use Bash(git log *) — note the space before *, which is required for prefix matching to work correctly.
    • If a single exact invocation is common: use Bash(foo) with no wildcard.
    • For MCP: use the full tool name verbatim (no wildcard needed; they're already specific).
    • Never widen a pattern to the point that it conflicts with the rules above (no arbitrary code execution, no mutation/side effects).
  6. Prioritize. Rank by count descending. Drop anything that appeared fewer than ~3 times — not worth the allowlist entry. Cap the list at the top ~20 so the user can skim it.

  7. Present the prioritized list to the user as a markdown table with columns: rank, pattern, count, one-line description. Example:

    #PatternCountNotes
    1Bash(git status *)142repo status checks
    2Bash(gh pr view *)87PR inspection
    3mcp__slack__slack_read_thread54Slack thread reads
  8. Merge into .claude/settings.json in the current project (not ~/.claude/settings.json, not .claude/settings.local.json). Create the file if it doesn't exist. Preserve existing keys and existing entries in permissions.allow; de-duplicate against what's already there; don't remove anything; don't reorder unrelated fields.

  9. Report back. Tell the user what you added (count + a few examples), what was already in the allowlist, and what you skipped and why (e.g. "dropped rm and git push — not read-only; dropped cat/ls/git status — already auto-allowed, no rule needed").

Do not add anything to permissions.deny or permissions.ask. Do not touch any other settings field.

Reviews

No reviews yet. Tell others what you thought.

Comments

No login needed. Share how it worked for you, ask a question, or note where it did not run.

No comments yet. Be the first to write one.

Comments are published right away. Do not include personal information such as email addresses or phone numbers. Up to 2 URLs.

0 / 1,000 characters

This form is protected by reCAPTCHA, and the Google Privacy Policy and Terms of Service apply.

More skills from this repository

3d-object

FreeSummary

Create a 3D object with three.js, inspect it from every angle in an interactive viewer, and download it as OBJ + MTL or GLB for use in other 3D applications.

  • Create a 3D object and inspect it from every angle
  • Export a model for further editing in Blender
  • Review an object's silhouette and materials
asgeirtj/system_prompts_leaks70.1KUpdated Oct 23, 2026

action-items

FreeSummary

Maintain a private task list with deadlines, next steps, waiting parties, and blockers. Update progress and dependencies, merge duplicate items, and archive closed tasks so ongoing commitments stay clear and easy to follow.

  • Record tasks and commitments with deadlines
  • Track pending replies and reasons work cannot proceed
  • Update task dependencies when prerequisites are completed
asgeirtj/system_prompts_leaks70.1KUpdated Oct 23, 2026

agents

FreeSummary

Coordinate a task from a verifiable goal through completion. Handle work directly or split independent tasks across separate agent sessions, track progress, verify results, and arrange pull request merging when included in the goal.

  • Split independent tasks across agents
  • Check progress across ongoing tasks
  • Resume a previously started project
asgeirtj/system_prompts_leaks70.1KUpdated Oct 23, 2026

animated-video

FreeSummary

Create animated HTML pages with smooth scene transitions and playback controls. An editable timeline lets users adjust scene lengths and speeds, with fixed landscape or portrait layouts prepared for video export.

  • Create an animated product walkthrough
  • Explain a message through moving text and graphics
  • Build a portrait animation for video export
asgeirtj/system_prompts_leaks70.1KUpdated Oct 23, 2026

apple_healthkit

FreeSummary

Review synced Apple Health records, including steps, heart rate, sleep, and workouts. Retrieve daily summaries or detailed samples for a chosen period, and check sync status and missing data before interpreting the results.

  • Review daily steps and heart rate over time
  • Check sleep stages, duration, and awakenings
  • Review workout duration, distance, and calories
asgeirtj/system_prompts_leaks70.1KUpdated Oct 23, 2026

Create and edit Word documents and templates, reorganize text, replace images, and work with tracked changes or comments. Apply proper headings and lists, then render every page to check its appearance before delivery.

  • Create a structured Word document
  • Reorganize content in an existing document
  • Replace images or text in a document
asgeirtj/system_prompts_leaks70.1KUpdated Oct 23, 2026

See all skills by asgeirtj

Report a problem with this skill