Skip to content

feat: auto-create .allagents/.gitignore to exclude sync-state.json#336

Merged
christso merged 1 commit intomainfrom
feat/gitignore-sync-state
Mar 26, 2026
Merged

feat: auto-create .allagents/.gitignore to exclude sync-state.json#336
christso merged 1 commit intomainfrom
feat/gitignore-sync-state

Conversation

@christso
Copy link
Copy Markdown
Contributor

Summary

  • Auto-creates .allagents/.gitignore containing sync-state.json on workspace init and on every sync state save
  • Idempotent — safe to call repeatedly, preserves existing user entries in .gitignore
  • sync-state.json contains machine-local filesystem paths and should never be committed

Related: #335 (lock file proposal for reproducible remote plugin syncs)

Test plan

  • Unit tests: creation, idempotency, preserving existing entries, skipping when already present (4 tests)
  • Full test suite passes (1082 tests)
  • E2E: workspace init creates .allagents/.gitignore with sync-state.json
  • Pre-push hooks pass (lint, typecheck, test)

E2E steps to reproduce

cd /tmp && mkdir gitignore-test && cd gitignore-test
git init
allagents workspace init
cat .allagents/.gitignore
# Expected: sync-state.json

sync-state.json contains machine-local filesystem paths and should never
be committed. This ensures the .gitignore is created on workspace init
and on every sync state save (idempotent, preserves user entries).
@cloudflare-workers-and-pages
Copy link
Copy Markdown

Deploying allagents with  Cloudflare Pages  Cloudflare Pages

Latest commit: d40c35b
Status: ✅  Deploy successful!
Preview URL: https://560156b4.allagents.pages.dev
Branch Preview URL: https://feat-gitignore-sync-state.allagents.pages.dev

View logs

@christso christso merged commit 99ed76d into main Mar 26, 2026
1 check passed
@christso christso deleted the feat/gitignore-sync-state branch March 26, 2026 23:37
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