Skip to content

v0.6.3: repo clone + workspace + workspace-clean#9

Merged
corvid-agent merged 1 commit into
mainfrom
feat/v0.6.3-repo-clone
May 21, 2026
Merged

v0.6.3: repo clone + workspace + workspace-clean#9
corvid-agent merged 1 commit into
mainfrom
feat/v0.6.3-repo-clone

Conversation

@corvid-agent
Copy link
Copy Markdown
Contributor

Summary

Closes the cross-repo-sandbox gap users hit in Discord: `shell-exec git clone ...` is auto-denied by merlin's Tier 1.5 safety gate in `--yes` mode (CorvidLabs/merlin#469), and there was no structured plugin command to clone instead. Adds three actions on `repo`:

  • `clone <OWNER/NAME> [DIR] [--depth N]` — thin wrapper over `gh repo clone`. Inherits `gh auth` for private repos.
  • `workspace <OWNER/NAME> [-r REF] [--depth N]` — the agent-facing path. Creates a fresh `/tmp/fledge-gh---XXXXXX/` dir, clones into it, prints the path. `-r REF` wires through to git's `--branch` so shallow + ref work together.
  • `workspace-clean ` — `rm -rf` with a safety check that refuses anything outside `/tmp/fledge-gh-`. Walks up to the fledge-gh-* parent if DIR is the inner clone path.

Plugin and arg descriptions in `plugin.toml` surface `workspace` as the preferred path with examples.

Test plan

  • `workspace CorvidLabs/corvid-verify -r feat/jwks-endpoint --depth 1` clones, checks out the ref, prints the path
  • `ls $WS` shows the repo contents at that ref
  • `workspace-clean $WS` removes both the inner dir AND the fledge-gh-* parent
  • `workspace-clean /etc` refuses (safety check works)
  • `bash -n` + `shellcheck --severity=warning` clean

Agents driven from non-interactive bridges (Discord/Telegram) had no
structured path to clone a repo for edit work. They were falling
back to `shell-exec git clone ...` which is auto-denied by merlin's
Tier 1.5 safety gate under --yes mode (PR CorvidLabs/merlin#469).
The agent then gave up with "I don't have local access" or escalated
via owner-notify even when the user just wanted them to grab a repo
and start working.

Three new actions on `repo`:

- `clone <OWNER/NAME> [DIR] [--depth N]` — thin wrapper over
  `gh repo clone`. Explicit destination, current cwd, inherits
  `gh auth` for private repos.

- `workspace <OWNER/NAME> [-r REF] [--depth N]` — the high-level
  "give me a sandbox" path. Creates a fresh
  /tmp/fledge-gh-<owner>-<name>-XXXXXX/<name> dir via mktemp -d,
  clones the repo there, and prints the absolute path on stdout.
  -r REF is wired through git's --branch so shallow + ref work
  together (a post-clone checkout fails on shallow because the
  partial fetch only contains the default branch tip).

- `workspace-clean <DIR>` — rm -rf with a safety check that refuses
  any path not under /tmp/fledge-gh-. If DIR is the inner clone
  path, walks up to the fledge-gh-* parent so we don't leave an
  empty shell behind.

Plugin / arg description in plugin.toml updated to surface workspace
as the preferred path for agents, with examples.
@gemini-code-assist
Copy link
Copy Markdown

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

@corvid-agent corvid-agent merged commit ebe7e98 into main May 21, 2026
5 checks passed
@corvid-agent corvid-agent deleted the feat/v0.6.3-repo-clone branch May 21, 2026 23:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant