diff --git a/.windsurf/workflows/README.md b/.windsurf/workflows/README.md new file mode 100644 index 0000000..dc0ad02 --- /dev/null +++ b/.windsurf/workflows/README.md @@ -0,0 +1,15 @@ +# ChronoMind Workflows + +Product-specific workflows for ChronoMind AI-powered contextual clock. + +## Repo-management Workflows + +Cross-repo workflows are maintained centrally in `learning_ai_common_plat/.windsurf/workflows/`: +- `/repo_sync-repos` — Pull latest from all repos +- `/repo_commit-workspace` — Commit changes across repos +- `/repo_backup-main-branch` — Backup main branches +- `/repo_backup-and-push` — Backup then push all repos + +## Product Workflows + +- `/refresh-chat-history` — Refresh Windsurf chat archive diff --git a/.windsurf/workflows/repo_backup-and-push.md b/.windsurf/workflows/repo_backup-and-push.md deleted file mode 100644 index e05b763..0000000 --- a/.windsurf/workflows/repo_backup-and-push.md +++ /dev/null @@ -1,55 +0,0 @@ ---- -description: Backup main branches then push all repos to origin in sequence ---- - -# Backup & Push All Repos - -Combines `/repo_backup-main-branch` and `/repo_push-repos` into a single sequential workflow. Ideal for end-of-session save-all. - -## Step 1: Backup main branches - -Creates timestamped backup branches with smart duplicate detection. - -// turbo -Run `bash scripts/backup-main.sh` from any repository root - -## Step 2: Push all repos to origin - -// turbo - -```bash -for repo in learning_ai_common_plat learning_voice_ai_agent learning_multimodal_memory_agents learning_ai_clock learning_ai_fastgap learning_ai_jarvis_jr learning_ai_peakpulse; do - echo "━━━ Pushing $repo ━━━" - (cd ~/code/mygh/$repo && git push origin main 2>&1) -done -echo "" -echo "✨ All repos pushed!" -``` - -## What it does: - -1. **Backup** — creates timestamped backup branches, cleans up old ones (7 days), skips duplicates -2. **Push** — pushes `main` to `origin/main` for all 7 repos - -## Repositories: - -- learning_ai_common_plat -- learning_voice_ai_agent -- learning_multimodal_memory_agents -- learning_ai_clock -- learning_ai_fastgap -- learning_ai_jarvis_jr -- learning_ai_peakpulse - -## When to use: - -- End of a work session -- Before switching machines -- After a batch of commits across repos -- Anytime you want a safe checkpoint + sync to remote - -## Notes: - -- Backup runs first so the backup branch includes the latest local commits -- Push only pushes `main` — backup branches are pushed by the backup script itself -- If push fails (diverged remote), run `/repo_sync-repos` first to pull diff --git a/.windsurf/workflows/repo_backup-main-branch.md b/.windsurf/workflows/repo_backup-main-branch.md deleted file mode 100644 index 1bae9e9..0000000 --- a/.windsurf/workflows/repo_backup-main-branch.md +++ /dev/null @@ -1,36 +0,0 @@ ---- -description: Smart backup of main branches with duplicate detection ---- - -# Backup Main Branch - -Creates smart backups of main branches across all repositories. - -// turbo -Run `bash scripts/backup-main.sh` from any repository root - -## What it does: - -1. Checks each repository for changes -2. Skips backup if main hasn't changed since last backup -3. Creates timestamped backup branch -4. Cleans up old backups (keeps 7 days) -5. Returns to main branch - -## Repositories covered: - -- learning_ai_common_plat -- learning_voice_ai_agent -- learning_multimodal_memory_agents -- learning_ai_clock -- learning_ai_fastgap -- learning_ai_jarvis_jr -- learning_ai_peakpulse - -## Features: - -- ✅ Smart duplicate detection -- ✅ Automatic cleanup of old backups -- ✅ Multi-repo support -- ✅ Safe operations (always returns to main) -- ✅ Color-coded output for clarity diff --git a/.windsurf/workflows/repo_commit-workspace.md b/.windsurf/workflows/repo_commit-workspace.md deleted file mode 100644 index 2cce84c..0000000 --- a/.windsurf/workflows/repo_commit-workspace.md +++ /dev/null @@ -1,117 +0,0 @@ ---- -description: Commit all workspace changes in logical order with intelligent messages -date: 2025-02-12 ---- - -# Commit Workspace - -Scans all repositories for pending changes and commits them in logical order with intelligent commit messages. - -// turbo -~/commit-workspace.sh - -## What it does: - -1. **Scans** all 7 repos for changes: - - learning_ai_common_plat - - learning_voice_ai_agent - - learning_multimodal_memory_agents - - learning_ai_clock - - learning_ai_fastgap - - learning_ai_jarvis_jr - - learning_ai_peakpulse - -2. **Analyzes** changed files to determine: - - Commit scope (auth, ci, docs, feat, chore, etc.) - - Appropriate commit message - - Logical grouping - -3. **Commits** in dependency order: - - Always commits common platform first - - Then other repos - -4. Does **NOT** push — use `/repo_sync-repos` or `git push` separately - -## Commit Message Logic: - -The script analyzes file types to generate appropriate messages: - -| File Pattern | Commit Message Example | -| ------------------------- | ---------------------------------------------------- | -| auth/middleware/jwt files | `feat(auth): update authentication and middleware` | -| .github/workflows/ | `ci: update CI/CD configuration` | -| Dockerfile + package.json | `feat: update Dockerfile for pnpm workspace support` | -| package.json, lock files | `chore: update dependencies` | -| \*.md files | `docs: update documentation` | -| \*.py, requirements.txt | `feat(python): update Python modules` | -| test/, _spec_ | `test: add/update tests` | -| .env, config files | `chore: update configuration` | -| Other files | `chore: update project files` | - -## Usage: - -```bash -# Run from anywhere -~/commit-workspace.sh - -# Or via Windsurf -/commit-workspace -``` - -## Example Output: - -``` -📋 Scanning workspace for changes... - -📁 learning_ai_common_plat: - - 2 staged - - 1 modified - -📁 learning_voice_ai_agent: - - 3 untracked - -Found changes in 2 repo(s) - -🚀 Committing in dependency order... - -📝 Committing learning_ai_common_plat... - Message: feat(auth): update authentication and middleware - ✅ Committed - -📝 Committing learning_voice_ai_agent... - Message: docs: update documentation - ✅ Committed - -✨ All changes committed locally! -💡 Use /repo_sync-repos or git push to push to remote -``` - -## Features: - -- ✅ No prompts - fully automated -- ✅ Intelligent commit messages -- ✅ Logical dependency order -- ✅ Stages all changes automatically -- ✅ Local commits only (no push) -- ✅ Clean, colored output - -## Safety: - -- Always shows what will be committed -- Uses conventional commit format -- Commits in correct order to avoid issues -- Preserves all changes - -## When to Use: - -- After making changes across multiple repos -- Before switching contexts/tasks -- At the end of a development session -- When preparing for releases - -## Notes: - -- Script location: `~/commit-workspace.sh` -- Requires git access to all repos -- Works with any branch (but assumes main is primary) -- Will skip repos with no changes diff --git a/.windsurf/workflows/repo_push-repos.md b/.windsurf/workflows/repo_push-repos.md deleted file mode 100644 index 3238edf..0000000 --- a/.windsurf/workflows/repo_push-repos.md +++ /dev/null @@ -1,42 +0,0 @@ ---- -description: Push local main branch to origin for all 5 workspace repos ---- - -# Push Repos - -Pushes local `main` to `origin/main` for all workspace repositories. - -// turbo - -```bash -for repo in learning_ai_common_plat learning_voice_ai_agent learning_multimodal_memory_agents learning_ai_clock learning_ai_fastgap; do - echo "━━━ $repo ━━━" - (cd ~/code/mygh/$repo && git push origin main) -done -``` - -## What it does: - -1. Iterates over all 5 workspace repos -2. Runs `git push origin main` in each -3. Fails fast if a repo has diverged from remote (resolve with rebase manually) - -## Repositories: - -- learning_ai_common_plat -- learning_voice_ai_agent -- learning_multimodal_memory_agents -- learning_ai_clock -- learning_ai_fastgap - -## When to use: - -- After committing a batch of changes locally -- After running `/repo_commit-workspace` -- To sync local work to GitHub before switching machines - -## Notes: - -- Only pushes `main` — does not push other branches -- Will fail safely if remote has diverged — run `/repo_sync-repos` first then rebase -- Use `/repo_sync-repos` to pull before pushing if you've been working on another machine diff --git a/.windsurf/workflows/repo_sync-repos.md b/.windsurf/workflows/repo_sync-repos.md deleted file mode 100644 index 2f513bb..0000000 --- a/.windsurf/workflows/repo_sync-repos.md +++ /dev/null @@ -1,44 +0,0 @@ ---- -description: Pull latest from origin main across all 7 workspace repos ---- - -# Sync Repos - -Pulls the latest changes from `origin/main` for all workspace repositories. - -// turbo - -```bash -for repo in learning_ai_common_plat learning_voice_ai_agent learning_multimodal_memory_agents learning_ai_clock learning_ai_fastgap learning_ai_jarvis_jr learning_ai_peakpulse; do - echo "━━━ $repo ━━━" - (cd ~/code/mygh/$repo && git pull --ff-only origin main) -done -``` - -## What it does: - -1. Iterates over all 7 workspace repos -2. Runs `git pull --ff-only origin main` in each -3. Fails fast if there are local divergent commits (use `git pull --rebase` manually in that case) - -## Repositories: - -- learning_ai_common_plat -- learning_voice_ai_agent -- learning_multimodal_memory_agents -- learning_ai_clock -- learning_ai_fastgap -- learning_ai_jarvis_jr -- learning_ai_peakpulse - -## When to use: - -- Starting a new work session -- After pushing changes from another machine -- Before running `/repo_backup-main-branch` - -## Notes: - -- Uses `--ff-only` to prevent accidental merge commits -- If a repo has uncommitted changes, `git pull` will still work (fast-forward only) -- If a repo has diverged from origin, the pull will fail safely — resolve manually diff --git a/.windsurf/workflows/repo_update-agent-docs.md b/.windsurf/workflows/repo_update-agent-docs.md deleted file mode 100644 index 51bbe0f..0000000 --- a/.windsurf/workflows/repo_update-agent-docs.md +++ /dev/null @@ -1,51 +0,0 @@ ---- -description: Regenerate AI agent docs (AGENTS.md, CLAUDE.md, .cursorrules, etc.) across all repos ---- - -# Update Agent Docs Across Workspace - -Regenerates all 8 AI agent configuration files across all repos in the workspace. - -## Files Generated Per Repo - -| File | Tool | -|------|------| -| `AGENTS.md` | Universal (OpenAI Codex, Claude, Copilot, etc.) | -| `CLAUDE.md` | Claude Code | -| `.cursorrules` | Cursor AI | -| `.github/copilot-instructions.md` | GitHub Copilot | -| `.windsurfrules` | Windsurf / Cascade | -| `.clinerules` | Cline / Roo Code | -| `.aider.conf.yml` | Aider | -| `.editorconfig` | All editors | - -## Steps - -1. Run the update script: - -```bash -cd /Users/sd9235/code/mygh/learning_ai_common_plat -./scripts/update-agent-docs.sh -``` - -2. Review changes per repo: - -```bash -cd /Users/sd9235/code/mygh/learning_voice_ai_agent && git diff --stat -cd /Users/sd9235/code/mygh/learning_multimodal_memory_agents && git diff --stat -# ... etc for all repos -``` - -3. Commit changes (if any): - -```bash -cd /Users/sd9235/code/mygh/learning_voice_ai_agent -[ -n "$(git status --porcelain)" ] && git add -A && git commit -m "chore(docs): update agent configuration files" -``` - -## Notes - -- The script scans each repo's structure and regenerates docs based on current state -- Only commits if there are actual changes -- Safe to run repeatedly (idempotent) -- Requires `learning_ai_common_plat` to be the source of truth for templates