From 984da528fbc44b5d06982a4ec912e01b07bf94b3 Mon Sep 17 00:00:00 2001 From: bwnyasse <5323628+bwnyasse@users.noreply.github.com> Date: Sat, 10 Jan 2026 23:04:56 -0500 Subject: [PATCH] feat: add prototype syncing for local dev and AI context This commit introduces a new feature to synchronize prototypes from an external repository for local development and to provide context for AI tools. - Added `make sync-prototypes` target to Makefile to build and copy prototypes from the adjacent 'client-krow-poc' repository. - Added `.geminiignore` entries to prevent Gemini from ignoring prototypes, ensuring they are available for context. - Added `.gitignore` entries to ignore generated prototype files, except for the `.keep` files, to keep the directories. - Added `04-sync-prototypes.md` documentation to explain how to sync prototypes. - Removed empty `internal/prototypes/.keep` file. --- .geminiignore | 3 +++ .gitignore | 6 ++++++ Makefile | 1 + README.md | 1 + internal/prototypes/.keep | 0 makefiles/tools.mk | 6 +++++- 6 files changed, 16 insertions(+), 1 deletion(-) delete mode 100644 internal/prototypes/.keep diff --git a/.geminiignore b/.geminiignore index a62aa431..067d8bc3 100644 --- a/.geminiignore +++ b/.geminiignore @@ -77,6 +77,9 @@ __pycache__/ # ----------------------------------------------------------------------------- # Specific Directories # ----------------------------------------------------------------------------- +# Prototypes: We WANT Gemini to see these for context if they are synced locally, +# even if they are ignored by Git. So we do NOT ignore them here. + # Temporary migration folders _legacy/ krow-workforce-export-latest/ diff --git a/.gitignore b/.gitignore index 8730cb82..c23832af 100644 --- a/.gitignore +++ b/.gitignore @@ -159,6 +159,12 @@ __pycache__/ # unless it contains sensitive info. Here we explicitly ignore the raw file. internal/launchpad/iap-users.txt +# Generated Prototypes (must be synced locally via 'make sync-prototypes') +internal/launchpad/prototypes/web/* +!internal/launchpad/prototypes/web/.keep +internal/launchpad/prototypes/mobile/**/* +!internal/launchpad/prototypes/mobile/**/.keep + # Temporary migration artifacts _legacy/ krow-workforce-export-latest/ diff --git a/Makefile b/Makefile index fcb848c5..b8591669 100644 --- a/Makefile +++ b/Makefile @@ -41,6 +41,7 @@ help: @echo "" @echo " --- DEVELOPMENT TOOLS ---" @echo " make install-git-hooks - Installs git pre-push hook to protect main/dev branches." + @echo " make sync-prototypes - Builds and copies prototypes from adjacent 'client-krow-poc' repo." @echo "" @echo " --- DATA CONNECT MANAGEMENT ---" @echo " make dataconnect-init - Initializes Firebase Data Connect." diff --git a/README.md b/README.md index 7fbcf2dd..695004f7 100644 --- a/README.md +++ b/README.md @@ -62,6 +62,7 @@ This project uses a modular `Makefile` for all common tasks. - **[01-backend-api-specification.md](./docs/01-backend-api-specification.md)**: (Legacy) Reference for data schemas. - **[02-codemagic-env-vars.md](./docs/02-codemagic-env-vars.md)**: Guide for CI/CD environment variables. - **[03-contributing.md](./docs/03-contributing.md)**: Guidelines for new developers and setup checklist. +- **[04-sync-prototypes.md](./docs/04-sync-prototypes.md)**: How to sync prototypes for local dev and AI context. ## 🤝 Contributing New to the team? Please read our **[Contributing Guide](./docs/03-contributing.md)** to get your environment set up and understand our workflow. diff --git a/internal/prototypes/.keep b/internal/prototypes/.keep deleted file mode 100644 index e69de29b..00000000 diff --git a/makefiles/tools.mk b/makefiles/tools.mk index db1fbb75..68f1f83a 100644 --- a/makefiles/tools.mk +++ b/makefiles/tools.mk @@ -1,8 +1,12 @@ # --- Development Tools --- -.PHONY: install-git-hooks +.PHONY: install-git-hooks sync-prototypes install-git-hooks: @echo "--> Installing Git hooks..." @ln -sf ../../scripts/git-hooks/pre-push .git/hooks/pre-push @echo "✅ pre-push hook installed successfully. Direct pushes to 'main' and 'dev' are now blocked." + +sync-prototypes: + @echo "--> Synchronizing prototypes from external repository..." + @./scripts/sync-prototypes.sh