speckit-git-initialize

Initialize a Git repository with an initial commit in the current project directory.

Updated Dec 20, 2023
One-click install
npx skills add https://github.com/Thiago-Cruz-eng/Hibrygame --skill speckit-git-initialize-thiago-cruz-eng
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: speckit-git-initialize
Source: https://github.com/Thiago-Cruz-eng/Hibrygame/tree/main/.claude/skills/speckit-git-initialize
Command: npx skills add https://github.com/Thiago-Cruz-eng/Hibrygame --skill speckit-git-initialize-thiago-cruz-eng

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Setting up version control from scratch is repetitive and error-prone, especially when a project is missing a repository or the user forgets to create an initial commit.

Core Features & Use Cases

  • Repository bootstrap with safety checks: Detects whether Git is available and whether you are already inside a Git repository, then initializes only when appropriate.
  • Initial commit creation: Runs git init, stages project files, and creates an initial commit with a consistent message.
  • Cross-shell support (Bash/PowerShell): Chooses the correct script for your environment or uses a reliable fallback when extension scripts are missing.

Quick Start

Run the skill to initialize Git in the current project directory and produce an initial commit when no repository exists yet.

Frequently Asked Questions about speckit-git-initialize

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I initialize a Git repository and create the first commit for a new project?

Git initialization safely runs only when Git is available and you are not already inside a repository. It performs platform-specific setup via Bash or PowerShell extension scripts, using a reliable safe git fallback when scripts are missing.

How does repository initialization handle cross-shell support for Bash and PowerShell?

Repository initialization chooses the correct Bash or PowerShell script for your environment to execute git init and stage files. It automatically uses a safe git fallback when extension scripts are missing from the project directory.

Can I use this to create an initial commit if my project is already in a Git repository?

You cannot create an initial commit if the project is already in a Git repository. The skill includes safety checks that detect existing repository status and skip initialization to prevent overwriting your current version control state.

What happens to repository initialization when Git is not installed on my system?

Repository initialization is completely skipped when Git is unavailable on your system. The skill detects whether Git is installed before attempting any actions, ensuring no errors occur during the project bootstrap process.

What's the best way to bootstrap version control for spec-kit-based projects?

The best way to bootstrap version control for spec-kit-based projects is running an initialization skill that automates git init, file staging, and initial commit creation. It applies platform-specific scripts to ensure consistent repository setup across different environments.