Sets up git version control in your CRAFT project folder
The AI checks whether git is already configured, initializes a repository if needed, sets your identity, creates a CRAFT-aware .gitignore, makes an initial commit, and optionally connects a GitHub remote โ all idempotent, so running it twice wonโt break anything.
Cowork Git Initialization
TL;DR
How To Start
STEP 1Tell the AI to Initialize Git
-
github_repo_url
· string · optional
GitHub remote URL (e.g., “https://github.com/Org/Repo.git”). If omitted, the repository stays local-only. You can add a remote later by running this recipe again with the URL. -
user_name
· string · optional
Git user.name for commits. If omitted, auto-detected from your project’s ABOUT_ME configuration. -
user_email
· string · optional
Git user.email for commits. If omitted, auto-detected from project context. The AI will ask if it cannot detect one.
STEP 2Review the Git Status Report
STEP 3Confirm Identity and .gitignore
STEP 4Verify the Initial Commit and Optional Push
Usage Examples
How AI Reads This Recipe
- CHECK for an existing git repository using git status before making any changes.
- REPORT existing state (branch, last commit, remote) if a repo is found, and ASK whether to skip or update configuration.
- INITIALIZE with git init and rename the default branch to main if no repo exists.
- AUTO-DETECT user name and email from the project’s ABOUT_ME field or CLAUDE.md context before asking the user.
- CREATE a .gitignore with CRAFT-specific exclusions only if one does not already exist — never overwrite an existing .gitignore.
- STAGE all files and create an initial commit with a descriptive message that includes the project ID and a Co-Authored-By line.
- CONFIGURE the GitHub remote only when a URL is provided, and SCRUB the Personal Access Token from the remote URL immediately after a successful push — never leave credentials in git config.
When to Use This Recipe
- Start a new CRAFT project and need version control from the beginning.
- Have an existing CRAFT project folder that is not yet under git.
- Need to connect a local CRAFT repository to a GitHub remote for the first time.
- Want to verify or update the git identity configured for your project.
- Are setting up a project on a new device and need to re-establish the git configuration.
Recipe FAQ
Q.What if I already have a git repo in this folder?
Q.Will this overwrite my existing .gitignore?
Q.What happens to the Personal Access Token after push?
Q.Can I add a remote later if I skip it now?
Q.What branch does this create?
Q.Does this recipe handle SSH remotes?
Q.What files does the .gitignore exclude?
Version History
Get this recipe with CRAFT for Claude Cowork
Cowork recipes ship bundled with CRAFT for Claude Cowork — there’s no separate download. Clone the framework once, and your AI runs every recipe automatically when invoked.
Pull anytime to stay on the latest version — free to clone, no login or email required.
Then start your session
Once CRAFT is in your project folder, open a new Cowork session and ask Claude to initialize. For example:
You
Claude
Not familiar with Git? Download as a ZIP
No command line needed. Just download, move, and unzip:
- Open the CRAFT framework repo on GitHub.
- Click the green Code button, then choose Download ZIP.
- Move the downloaded ZIP into your Claude Cowork project folder.
- Unzip it: double-click on Mac, or right-click → Extract All on Windows.
