Standalone Bash utilities for project scaffolding, GitHub repository management and multi-repo maintenance.
A standalone collection of Bash command-line utilities (plus one Python tool) for project bootstrapping, GitHub repository management, and multi-repo maintenance.
There is no application to build and no dependency install โ every script is self-contained and runs directly. This repo is also vendored as a submodule of the bamr87/bamr87 dash, which installs several of these scripts as named CLI commands (see Installation).
Every tool, the command the hub installs it as, and what it does:
| Script | Command | What it does |
|---|---|---|
project-init.sh |
project-wizard |
Interactive/non-interactive project scaffolding wizard โ Django, React, Node, Python, custom; optional Docker, CI, license, and GitHub repo creation |
forkme.sh โ FORKME/forkme.sh |
forkme |
Repository forking/cloning utility with 10 strategies (full, shallow, sparse, toplevel, structure, filetype, analysis, mirror, bundle, metadata-only) |
STASHME/stashme.sh |
stashme |
Multi-repo cloud stash โ pushes uncommitted work across many repos to timestamped stashme/โฆ backup branches, with restore and cleanup modes |
git_init.sh |
git-init |
Interactive/headless git + GitHub repo creator; prefers gh, falls back to npx degit for templates, uses gitignore.io for .gitignore |
rename-directory.sh |
rename-dir |
Safe directory rename with git/Docker pre-flight checks and optional backup |
create_package.sh |
create-package |
Bootstraps a Python package repo from microsoft/python-package-template |
tools/unwrap-prose.py |
โ | Liquid-safe markdown unwrapper enforcing one-paragraph-per-line; backs the markdown-oneline CI gate |
Per-tool guides live next to the tools: FORKME/, STASHME/, and docs/rename-directory-quick-reference.md.
git clone https://github.com/bamr87/scripts.git
cd scriptsThen, from the checkout:
# install: none; every tool runs from the checkout (./install.sh only puts project-wizard on PATH, see Installation) ./project-init.sh --help # every tool prints its own flags with --help tests/smoke.sh # offline safety smoke (sandboxed HOME, stub gh); CI: smoke.yml ./git_init.sh --headless -n previewme --dry-run # smoke test, no side effects ./STASHME/stashme.sh --dry-run # smoke test, no side effects shellcheck --severity=warning *.sh FORKME/forkme.sh STASHME/stashme.sh tests/*.sh # lint (.shellcheckrc disables SC2034/SC2086/SC1091) python3 tools/unwrap-prose.py --check # markdown one-paragraph-per-line (fix with --write) python3 tools/docs_index.py --check # docs/README.md index is current (rebuild with --write)
There are two ways to get these tools on your PATH, and which one you want depends on whether you also use the bamr87/bamr87 dash.
If you have the dash checked out, use its bootstrap โ do not run install.sh. tools/setup.sh in the hub marks every *.sh here executable and symlinks the full set into ~/.local/bin as forkme, stashme, git-init, project-wizard, rename-dir, and create-package:
cd /path/to/bamr87 # the hub checkout ./tools/setup.sh # or: ./tools/setup-dev.sh
If you only have this repo, use the standalone installer. It is narrower on purpose โ it wires up the Project Initialization Wizard only (project-wizard), creates ~/.project-wizard/, appends ~/.local/bin to your shell PATH, and drops a copy of .env.example for you to customize:
git clone https://github.com/bamr87/scripts.git cd scripts ./install.sh source ~/.zshrc # or ~/.bashrc
Running both is harmless (the symlinks are idempotent), but redundant โ the hub's setup is a strict superset for CLI installation.
Every script also runs directly with no installation at all; each prints its options with --help.
Interactive mode walks you through project type, name, GitHub settings, optional features (Docker, CI/CD), and license:
./project-init.sh
Non-interactive mode takes environment variables or flags:
# Environment variables PROJECT_TYPE=django PROJECT_NAME=my-api SETUP_DOCKER=true SETUP_CI=true \ ./project-init.sh --non-interactive # Command-line arguments ./project-init.sh --type react --name my-react-app --dir ~/projects/my-react-app
To set your own defaults, copy .env.example and either pass it with --config FILE (any mode; it is applied where it appears, so put it first and let later flags override it) or save it as .env in the directory you run the wizard from (interactive mode only; a .env overrides flags and --config). Only the variables below are read; the rest of .env.example is reserved and currently ignored. An unsupported PROJECT_TYPE stops the wizard before anything is created. Key options:
| Variable | Description | Options |
|---|---|---|
PROJECT_TYPE |
Type of project to create | django, react, node, python, custom |
PROJECT_NAME |
Name of your project | Any valid directory name |
PROJECT_DIR |
Where to create it | Defaults to ~/github/$PROJECT_NAME |
PROJECT_DESCRIPTION |
Used in the README and GitHub repo | โ |
GITHUB_USERNAME / GITHUB_EMAIL |
Your GitHub handle and email | Default to git config user.name / user.email |
LICENSE |
License type | MIT, Apache-2.0, GPL-3.0, None |
PRIVATE_REPO |
Create the GitHub repo as private | true, false |
CREATE_GITHUB_REPO |
Create the GitHub repo with gh; anything but true keeps the project local-only |
true (default), false |
PUSH_TO_GITHUB |
Push the initial commit to GitHub | true (default), false |
SETUP_DOCKER |
Create Docker configuration | true, false |
SETUP_CI |
Set up GitHub Actions | true, false |
./project-init.sh --help prints the full option list without writing anything. A run logs to ~/.project-wizard/wizard.log.
Forking and cloning strategies that go beyond git clone โ shallow and sparse checkouts for large repos, filetype extraction, and metadata-only analysis:
# Quick shallow clone for review ./forkme.sh --strategy shallow --depth 1 owner/repo # Extract documentation only ./forkme.sh --strategy filetype --file-types "md,txt" owner/repo # Pull just config and source paths for an audit ./forkme.sh --strategy sparse --sparse-paths "src/,*.config" owner/repo # Repository metadata without cloning ./forkme.sh --analyze-only owner/repo
โ Full ForkMe documentation ยท Quick reference
Saves uncommitted changes across every git repo under a directory tree to timestamped remote backup branches (stashme/2026-02-03-143021). It never modifies your working branch:
./STASHME/stashme.sh # stash all repos in ~/github ./STASHME/stashme.sh ~/projects # a specific tree ./STASHME/stashme.sh --list # repos with uncommitted changes ./STASHME/stashme.sh --dry-run # preview ./STASHME/stashme.sh -m "WIP: saving before vacation" # custom message ./STASHME/stashme.sh --restore # recover stashed changes ./STASHME/stashme.sh --cleanup # remove old stashme branches
โ Full StashMe documentation ยท Quick reference
Creates a git repo (and optionally the GitHub remote) in interactive or headless mode, preferring gh and falling back to npx degit for templates:
./git_init.sh # interactive ./git_init.sh --headless -n myrepo -u myuser --gitignore python,macos --scaffold python ./git_init.sh --headless -n myrepo -u myuser -t octocat/template-repo ./git_init.sh --headless -n localrepo --no-push ./git_init.sh --headless -n previewme --dry-run # preview only
Renames a directory with pre-flight validation โ checks source/target paths and permissions, detects and offers to stop related Docker containers, verifies git status, optionally backs up first, then verifies the result:
./rename-directory.sh ~/projects/old-name ~/projects/new-name ./rename-directory.sh --help
โ Quick reference
./create_package.sh awesome-lib # โ ~/github/awesome-lib, seeded from microsoft/python-package-template
./create_package.sh --helpThe name must be a plain directory name; anything starting with - or containing / is rejected. The template files are staged (git add .) but not committed.
Required: Git and Bash 4.0+ (plus Python 3 for the maintenance scripts in tools/).
Optional, depending on the tool: GitHub CLI (gh) for repository creation and forking, curl for gitignore.io lookups, rsync for create_package.sh, Docker for rename-directory.sh container handling, and the language toolchains (Python 3.8+ for django/python, Node 16+ with npm/npx for react/node) matching whatever project-init.sh scaffolds.
The docs index lists every document with a one-line summary: the ForkMe guide, the StashMe guide, the rename-directory quick reference, the decision log and the PRD.
| Path | What |
|---|---|
*.sh (root) |
The tools themselves (forkme.sh is a symlink to FORKME/forkme.sh); see Features |
FORKME/, STASHME/ |
ForkMe and StashMe, each with its own guide, quick reference and examples |
docs/ |
Docs index, decision log, the rename-directory quick reference |
tests/ |
smoke.sh, the offline safety smoke run by smoke.yml |
tools/ |
Repo maintenance scripts (the prose gate and the docs index generator) |
features/, verify/ |
Feature index and verification scenarios |
public/ |
The fleet page-feedback widget (vendored) |
.github/ |
Workflows (hub-kit callers) and sdlc.yml, this repo's SDLC profile |
The gates are ShellCheck, the offline smoke test tests/smoke.sh (side-effect-free --help for every tool, CREATE_GITHUB_REPO / PUSH_TO_GITHUB honored, run against a sandboxed HOME and a stub gh), the markdown one-paragraph-per-line rule and the docs index check, all in the Quick start block. In CI, smoke.yml runs ShellCheck and the smoke test (the hub's shared standard-ci.yml shellchecks nothing here), markdown-oneline.yml enforces the prose rule and ci.yml calls the hub's shared standard-ci.yml. claude.yml is the @claude handler, and conformance.yml, release.yml (release-please) and verify.yml are likewise thin callers of hub workflows. Conventions for new scripts, commits and branches live in AGENTS.md.
Contributions are welcome via pull request. Use Conventional Commits and keep the CI checks green. The fleet-wide workflow is described in the hub's CONTRIBUTING.md. AI agents start with AGENTS.md; CLAUDE.md imports it for Claude Code. This repo is a submodule of the bamr87/bamr87 dash, so changes land here first.
Notable changes are recorded in CHANGELOG.md; the full record is in the commit history.
MIT โ see LICENSE.
Part of the bamr87 portfolio โ browse every project on Amr's GitHub profile.