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
4 changes: 3 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@ format and uses semantic versioning when versioned releases are published.

### Added

- Initial project setup.
- Release-candidate metadata, package allowlist, and npm pack smoke coverage.
- Fixture-backed CLI smoke test for Markdown and JSON output.
- README quickstart, safety notes, and release verification commands.

## Release Links

Expand Down
55 changes: 39 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# atomcommit

atomcommit is an early-stage local-first developer tool.
`atomcommit` is a local-first CLI that turns staged and unstaged git diffs into deterministic atomic commit plans.

## Status

This repository is early-stage. The README now reflects the current project intent from `docs/PRD.md`, but behavior should still be treated as pre-1.0 until implementation, examples, and release checks mature.
Early V0.1 release candidate. The planner is useful for local git diffs, but it does not stage files, create commits, push branches, or infer product intent.

## Install from a checkout

Expand All @@ -22,21 +22,49 @@ npm install -g atomcommit

## Use

Start by reading the product notes and running the local checks:
Generate an atomic commit plan from a repository with local changes:

```sh
sed -n '1,120p' docs/PRD.md
npm test
atomcommit
atomcommit plan
```

Generate an atomic commit plan from a repository with local changes:
Use JSON output for automation:

```sh
atomcommit plan
atomcommit plan --json
```

Print version or help without needing to be inside a git repository:

```sh
atomcommit --version
atomcommit --help
```

## What it reads

`atomcommit` shells out to read-only git diff commands:

- `git diff --name-status`
- `git diff --cached --name-status`
- `git diff --numstat`
- `git diff --stat`

It groups changes by repository area such as documentation, tests, source code, package metadata, and CI automation. It also flags review risks such as deletions, renames, lockfiles, large changes, binary files, and sensitive-looking paths.

## Fixture smoke

The repository includes a deterministic mixed-change fixture:

```sh
bash fixtures/setup-mixed-changes.sh /tmp/atomcommit-fixture
cd /tmp/atomcommit-fixture
node /path/to/atomcommit/src/index.js plan --json
```

The fixture covers source edits, docs, tests, workflow changes, a rename, and a deletion.

## Verification

```sh
Expand All @@ -50,9 +78,10 @@ bash scripts/validate.sh

## Limitations

- The package is still a v0.1.0 project and may not expose a finished CLI or public API yet.
- Treat the PRD as direction, not a guarantee that every listed capability is implemented.
- Do not use the package for production security, compliance, or release decisions until tests and examples cover that workflow.
- The package is still a v0.1.0 project and its JSON shape may change before 1.0.
- Commit boundaries are structural suggestions. Humans still choose the final history.
- Sensitive-path flags are heuristics, not a secret scanner or compliance control.
- Git rename detection follows `git diff --name-status`; unusual diff settings can affect rename reporting.

## Contributing

Expand All @@ -66,12 +95,6 @@ See [SECURITY.md](SECURITY.md). Do not include secrets, private tokens, propriet

MIT

## Verification

Run the release-readiness checks that match this package before publishing or opening a release PR.

- `npm run build` - compile the package artifacts

## Release Verification

Before publishing or tagging a release, run the local verification path that matches CI:
Expand Down
18 changes: 8 additions & 10 deletions ROADMAP.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,22 +6,20 @@ contributors, and implementation constraints.

## Now

- Define the smallest useful project scope.
- Keep repository setup, documentation, and verification easy for contributors
to follow.
- Ship small, reviewable improvements.
- Keep the git-diff planner deterministic and local-only.
- Verify the CLI with fixture-backed tests and smoke checks before release.
- Document the V0.1 safety model and pack contents clearly.

## Next

- Add the next capabilities that directly support the project's primary users.
- Improve tests, docs, and examples around the most used workflows.
- Reduce setup friction discovered during early use.
- Add optional configuration for grouping rules and sensitive-path patterns.
- Provide examples for staged-only and mixed staged/unstaged workflows.
- Add richer JSON schema documentation for agent integrations.

## Later

- Consider larger features after the core workflow is stable.
- Add automation only where it removes repeated maintainer work.
- Revisit packaging, deployment, or integration options based on real demand.
- Explore editor and GitHub Action integrations once the CLI contract is stable.
- Consider commit-message templates after enough real plans are reviewed.

## Not Planned

Expand Down
6 changes: 2 additions & 4 deletions scripts/smoke.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,8 @@ trap 'rm -rf "$tmp_dir"' EXIT
fixture_repo="$tmp_dir/mixed-changes-repo"
bash "$repo_root/fixtures/setup-mixed-changes.sh" "$fixture_repo" >/dev/null

markdown_output="$(node "$repo_root/src/index.js" plan < /dev/null 2>/dev/null || true)"
if [ -z "$markdown_output" ]; then
: # running outside a git repo may fail; the fixture smoke below is authoritative
fi
node "$repo_root/src/index.js" --help | grep -q 'Usage: atomcommit'
test "$(node "$repo_root/src/index.js" --version)" = "0.1.0"

cd "$fixture_repo"
node "$repo_root/src/index.js" plan > "$tmp_dir/plan.md"
Expand Down