Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,26 +2,26 @@

## Project Structure & Module Organization

This is a Bash CLI project. The active runtime is the root `devloop` executable. `VERSION` is the single version source, `release.sh` cuts local release commits and annotated tags, `install.sh` links the CLI into a local bin directory and installs bundled skills into `~/.agents/skills` and `~/.claude/skills`, `tests/devloop_test.sh` covers the shell runtime, `skills/devloop-spec/SKILL.md` is the spec-generation skill, `skills/devloop-review/SKILL.md` is the review skill, and `skills/devloop-spec/references/spec-template.md` is the starter spec. Generated runtime output belongs under `.codex/` in target repositories and should not be committed here.
This is a Bash CLI project. The active runtime is the root `devloop` executable. `VERSION` is the single version source, `scripts/release.sh` cuts local release commits and annotated tags, `scripts/install.sh` links the CLI into a local bin directory and installs bundled skills into `~/.agents/skills` and `~/.claude/skills`, `scripts/devloop_test.sh` covers the shell runtime, `skills/devloop-spec/SKILL.md` is the spec-generation skill, `skills/devloop-review/SKILL.md` is the review skill, and `skills/devloop-spec/references/spec-template.md` is the starter spec. Generated runtime output belongs under `.codex/` in target repositories and should not be committed here.

## Build, Test, and Development Commands

- `bash tests/devloop_test.sh`: run the shell test suite.
- `./install.sh`: link `devloop` into `~/.local/bin` or `DEVLOOP_BIN_DIR`.
- `bash scripts/devloop_test.sh`: run the shell test suite.
- `./scripts/install.sh`: link `devloop` into `~/.local/bin` or `DEVLOOP_BIN_DIR`.
- `./devloop --plain .specs/change.md`: example local CLI invocation from a target git worktree.
- `./release.sh patch --dry-run`: validate the release path without changing files.
- `./scripts/release.sh patch --dry-run`: validate the release path without changing files.

## Coding Style & Naming Conventions

Use readable Bash with small named functions, quoted expansions, explicit status handling, and portable macOS/Linux shell utilities where practical. Prefer kebab-case for branch/spec slugs such as `devloop/change`.

## Testing Guidelines

Tests use `tests/devloop_test.sh`. Keep behavior fixture-style where possible: assert generated files, git state, status codes, and user-visible output.
Tests use `scripts/devloop_test.sh`. Keep behavior fixture-style where possible: assert generated files, git state, status codes, and user-visible output.

## Commit & Pull Request Guidelines

Git history follows Conventional Commits, for example `fix: surface devloop commit failures` and `chore: cover shell runtime`. Use concise subjects in imperative style and keep unrelated changes in separate commits. Pull requests should include a short problem summary, the implementation approach, and test evidence (`bash tests/devloop_test.sh`).
Git history follows Conventional Commits, for example `fix: surface devloop commit failures` and `chore: cover shell runtime`. Use concise subjects in imperative style and keep unrelated changes in separate commits. Pull requests should include a short problem summary, the implementation approach, and test evidence (`bash scripts/devloop_test.sh`).

## Agent-Specific Instructions

Expand Down
65 changes: 52 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,48 @@ By default, Codex makes the change, Claude Code reviews it, and Codex retries un

## Install

Install Devloop with the remote installer:

```sh
curl -fsSL https://devloop.sh/install | bash
```

The installer downloads a tagged GitHub release asset, verifies its `.sha256` checksum, installs it under `~/.local/share/devloop/<version>/`, links `~/.local/bin/devloop`, and installs the bundled Agent Skills for Codex under `~/.agents/skills` and Claude Code under `~/.claude/skills`.

Install a specific version or preview the install:

```sh
curl -fsSL https://devloop.sh/install | bash -s -- --version 0.2.0
curl -fsSL https://devloop.sh/install | bash -s -- --dry-run
curl -fsSL https://devloop.sh/install | bash -s -- --no-skills
```

Inspect before running:

```sh
curl -fsSL https://devloop.sh/install -o install.sh
less install.sh
bash install.sh
```

The remote installer checks for `gum`, `fzf`, `codex`, and `claude`. It does not install Codex or Claude Code. If `gum` or `fzf` is missing, it only installs them with Homebrew after explicit confirmation; otherwise it prints the `brew install gum fzf` command to run yourself.

If `~/.local/bin` is not on `PATH`, the installer prints the shell profile line to add. It does not edit shell profile files.

Required dependencies: Bash, git, Homebrew, `codex`, `claude`, `gum`, and `fzf`.
`install.sh` installs missing `gum` and `fzf` with Homebrew. Install the Codex and Claude Code CLIs before running a loop, then verify everything with `devloop doctor`.
`scripts/install.sh` installs missing `gum` and `fzf` with Homebrew. Install the Codex and Claude Code CLIs before running a loop, then verify everything with `devloop doctor`.
The GitHub CLI is optional. Install `gh` and run `gh auth login` only when you want PR-backed loops.

For source checkout development, use the local installer:

```sh
git clone https://github.com/satyaborg/devloop.git
cd devloop
./install.sh
./scripts/install.sh
```

`./scripts/install.sh` symlinks the checkout executable, installs missing `gum` and `fzf` with Homebrew when available, installs bundled skills, and finishes with `try: devloop doctor`.

Check the installed version:

```sh
Expand All @@ -30,14 +62,21 @@ Run without installing:
./devloop --help
```

`install.sh` also installs the bundled Agent Skills globally for Codex under `~/.agents/skills`
and Claude Code under `~/.claude/skills`.
After install or update, verify the local setup:

```sh
devloop doctor
```

Uninstall a remote install:

```sh
rm -f ~/.local/bin/devloop
rm -rf ~/.local/share/devloop
rm -rf ~/.agents/skills/devloop-spec ~/.agents/skills/devloop-review
rm -rf ~/.claude/skills/devloop-spec ~/.claude/skills/devloop-review
```

## Quick Start

Create a spec:
Expand Down Expand Up @@ -146,7 +185,7 @@ When stdout is a terminal, running `devloop` without arguments opens a menu:

Nested menu screens keep `Back` as the final option, and Esc/cancel also returns to the previous menu without exiting Devloop. Interactive screens redraw in place instead of appending a fresh UI after each selection.

`gum` powers the branded help screen, prompts, confirmations, status output, paging, and setup screens. `fzf` powers searchable pickers for specs, tracks, and reports. Both are required and installed by `install.sh` when missing.
`gum` powers the branded help screen, prompts, confirmations, status output, paging, and setup screens. `fzf` powers searchable pickers for specs, tracks, and reports. Both are required and installed by `scripts/install.sh` when missing.

## What Devloop Does

Expand Down Expand Up @@ -178,18 +217,18 @@ If present, `.devloop/verify` is executed from the run worktree with the pass nu
## Development

```sh
bash -n devloop install.sh release.sh skill_helpers.sh
shellcheck devloop install.sh skill_helpers.sh release.sh tests/devloop_test.sh
bash tests/devloop_test.sh
bash -n devloop scripts/install.sh scripts/release.sh scripts/skill_helpers.sh scripts/install.remote.sh scripts/devloop_test.sh
shellcheck devloop scripts/install.sh scripts/skill_helpers.sh scripts/release.sh scripts/install.remote.sh scripts/devloop_test.sh
bash scripts/devloop_test.sh
./devloop --help
./devloop --version
tmp="$(mktemp -d)"
DEVLOOP_BIN_DIR="$tmp/bin" HOME="$tmp/home" ./install.sh
DEVLOOP_BIN_DIR="$tmp/bin" HOME="$tmp/home" ./scripts/install.sh
PATH="$tmp/bin:$PATH" HOME="$tmp/home" devloop doctor
```

The supported runtime is the root [`devloop`](devloop) Bash script.
The shell suite enforces 100% project function coverage for `devloop`, `skill_helpers.sh`, and `release.sh`.
The shell suite enforces 100% project function coverage for `devloop`, `scripts/skill_helpers.sh`, and `scripts/release.sh`.

## Versioning and Release

Expand All @@ -205,11 +244,11 @@ brew install gh
Cut a release from a clean tree by choosing the bump:

```sh
./release.sh patch --dry-run
./release.sh patch --publish
./scripts/release.sh patch --dry-run
./scripts/release.sh patch --publish
```

Use `patch`, `minor`, or `major`. The script reads the current [`VERSION`](VERSION), computes the next SemVer version, updates `VERSION` and [`CHANGELOG.md`](CHANGELOG.md), runs `bash tests/devloop_test.sh`, commits `chore: release <version>`, and creates an annotated `v<version>` tag. Add `--publish` to push the release branch and tag, then create the GitHub Release. Use `--push` only when you want to publish the git refs without creating a GitHub Release. By default, published releases must run from `main`.
Use `patch`, `minor`, or `major`. The script reads the current [`VERSION`](VERSION), computes the next SemVer version, updates `VERSION` and [`CHANGELOG.md`](CHANGELOG.md), runs `bash scripts/devloop_test.sh`, commits `chore: release <version>`, and creates an annotated `v<version>` tag. Add `--publish` to push the release branch and tag, then create the GitHub Release. Use `--push` only when you want to publish the git refs without creating a GitHub Release. By default, published releases must run from `main`.

## License

Expand Down
2 changes: 1 addition & 1 deletion devloop
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ while [ -L "$SCRIPT_PATH" ]; do
esac
done
ROOT_DIR="$(cd -P "$(dirname "$SCRIPT_PATH")" >/dev/null 2>&1 && pwd)"
source "$ROOT_DIR/skill_helpers.sh"
source "$ROOT_DIR/scripts/skill_helpers.sh"
DEVLOOP_VERSION="$(sed -n '1p' "$ROOT_DIR/VERSION" 2>/dev/null || true)"
if [ -z "$DEVLOOP_VERSION" ]; then DEVLOOP_VERSION="0.0.0-dev"; fi

Expand Down
Loading