Skip to main content

Bootstrap an empty directory into a git repo with a GitHub remote

Project description

ghboot

From empty folder to GitHub repo in one command.

ghboot is a small CLI tool and importable Python library that bootstraps a directory into a fully initialized git repository — with a .gitignore, a README.md, an initial commit, and a GitHub remote — interactively, in seconds.


What it does

ghboot /path/to/my-project
  1. git init — prompts before initializing, skips if already a repo
  2. .gitignore — auto-detects your project type (Python, Node, Go, Rust, Ruby, Java) and fetches the matching template from the GitHub API; falls back to a generic template if offline or undetected
  3. README.md — creates a minimal # project-name file; skips if one exists
  4. Initial commit — stages everything and commits with "Initial commit"
  5. GitHub remote — uses the gh CLI to create the remote repo, prompt for name/owner/visibility, and push; skips gracefully if gh is not installed

Install

pip install ghboot

Or install in editable mode from source:

git clone https://github.com/you/ghboot
cd ghboot
pip install -e .

Usage

CLI

# bootstrap the current directory
ghboot

# bootstrap a specific path
ghboot ~/projects/my-new-thing

Interactive prompts guide you through each decision point:

Initialize git repo here? [Y/n]
Using Python .gitignore template.
Repo name [my-new-thing]:
Owner:
  1. yourname (personal)
  2. your-org
Select [1]:
Visibility [private/public, default: private]:
Created https://github.com/yourname/my-new-thing

Python API

from ghboot import bootstrap

# non-interactive, all defaults
bootstrap(path=".")

# interactive — prompts at each decision point
bootstrap(path=".", interactive=True)

Requirements

  • Python 3.10+
  • git available in PATH
  • gh CLI — optional, only needed for the GitHub remote step

What it explicitly does NOT do

  • No LLM calls
  • No framework-specific config
  • No branch management beyond main/master
  • No CI/CD setup

It does one thing and does it well. Anything beyond that is someone else's job.


License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ghboot-0.1.0.tar.gz (6.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ghboot-0.1.0-py3-none-any.whl (7.6 kB view details)

Uploaded Python 3

File details

Details for the file ghboot-0.1.0.tar.gz.

File metadata

  • Download URL: ghboot-0.1.0.tar.gz
  • Upload date:
  • Size: 6.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.3

File hashes

Hashes for ghboot-0.1.0.tar.gz
Algorithm Hash digest
SHA256 7b3200090e6cca6df35d45c953807a53673e3a14b88db2eb31cf157686511a8f
MD5 44c50358c20be40443dae4a46bf9782a
BLAKE2b-256 a8882698c8ad737eca06600884cb1b40d7a4cf233e2bf49e3cab2995efdda45d

See more details on using hashes here.

File details

Details for the file ghboot-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: ghboot-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 7.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.3

File hashes

Hashes for ghboot-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 bd72c0cb0df65a5cbe4de1d99850ad204d65a95621ce52f1b146230bacf5ca30
MD5 ab78d28efc55213bb4b676a6019941a6
BLAKE2b-256 6145b2dae50517fe228d26fb66d397f23312ec3c76eae8c2924b76bf748c2130

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page