entireio / entireio/cli

agent remove claude-code deletes unrelated .claude/settings.json keys

Open
#1,924 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
5.1k
Forks
475
Avg merge
1d 11h
Merged PRs (30d)
178

Description

Summary

entire agent remove claude-code removes unrelated keys from the repository's .claude/settings.json instead of removing only Entire-managed Claude hooks.

Environment

  • Entire CLI: 0.9.0
  • OS: Windows amd64
  • Repository already enabled for both Codex and Claude Code

Reproduction

Start with a project-level .claude/settings.json containing Entire-managed hooks plus an unrelated permission:

{
  "hooks": {
    "SessionStart": [
      {
        "matcher": "",
        "hooks": [
          {
            "type": "command",
            "command": "entire hooks claude-code session-start"
          }
        ]
      }
    ]
  },
  "permissions": {
    "deny": [
      "Read(./.entire/metadata/**)"
    ]
  }
}

Run:

entire agent remove claude-code

CLI output:

Removed Claude Code hooks.

Actual resulting file:

{}

The unrelated permissions.deny setting is removed together with the Entire hooks.

Expected Behavior

Only Entire-managed Claude Code hook entries should be removed. Unrelated top-level keys and unrelated hook entries should be preserved.

For the example above, the resulting file should be:

{
  "permissions": {
    "deny": [
      "Read(./.entire/metadata/**)"
    ]
  }
}

Workaround

Inspect the diff immediately after agent removal and manually restore unrelated Claude settings.

Acceptance Criteria

  • entire agent remove claude-code removes only Entire-owned hooks.
  • Unrelated .claude/settings.json keys survive unchanged.
  • A regression test covers mixed Entire and non-Entire Claude settings.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the entire agent remove claude-code command and its handling of .claude/settings.json; reproduce the issue using the mixed settings example in this report. Add a regression test covering Entire and unrelated Claude settings, then verify that removal preserves unrelated top-level keys and hook entries.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
cli
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.