agentleFS
gitt510gitt510/agent-skills/skills/create-repo/SKILL.md

create-repo

Skill0 starsChanged 3 months agoMITView on GitHub

Create a new GitHub repository with an empty root commit and check it out on a scaffold branch. Use when starting a repository from zero.

  • Commits and pushes

2 other projects use a version of this.

Adopted by

Most recently taken up by

  • Other versions2 projects use a version of this.

    Word for word · 0

    None found.

    Edited · 0

    None found.

    Wrote their own version · 2

    1. ambroselittle/agent-skills★ 0same name
    2. gastonmorixe/project-factory★ 0same name

    How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.

  • In this repository11 other files it gives its agents.

The file

We split this skill into the rules it gives an agent

3 rules. About 0 are common, 0 are distinctive, and 3 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 3

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Do not pass --license, --gitignore, --add-readme, or --clone — any of those would create a remote first commit and break the clean-root …

    line 51
  2. Very specific:

    If the name already exists, gh errors.

    line 53
  3. Very specific:

    Stop and explain: if gh, ghq, or auth is missing, or the target name already exists, rather than improvising.

    line 107

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Create Repo

Goal: Go from "no repository" to "an empty repository with a clean root commit, checked out locally on a scaffold branch, ready for the first real work".

The design intent: main starts as a single empty commit and stays clean. Everything that makes the repository useful — directory layout, README, license, tooling — arrives later via pull requests from the scaffold branch. This skill only prepares that starting line; it never writes project files itself.

Why an empty init commit

A root commit with no files gives every later change — including the very first README — a parent to diff against, keeps git rebase -i --root and git bisect well-behaved, and means the actual scaffolding can go through a reviewable PR instead of being baked into the root.

Workflow

0) Preconditions

gh auth status and ghq root must both succeed. Surface errors and stop on failure.

1) Gather the essentials

From the user (or the conversation), determine:

  • Repository name — required.
  • Visibility — --public or --private. If not stated, ask; never guess. Publishing a repository is outward-facing.
  • Owner — default to the authenticated user, resolved concretely with gh api user --jq .login (a machine may hold several gh accounts). Only ask when an organization is plausibly intended.
  • Description — optional; include only if the user provides one.

Confirm the combination (owner/name, visibility) with the user before creating. This is the one confirmation gate in the flow.

2) Create the remote

gh repo create <owner>/<name> --private|--public [--description "<desc>"]

Do not pass --license, --gitignore, --add-readme, or --clone — any of those would create a remote first commit and break the clean-root design. If the name already exists, gh errors; surface it and stop.

3) Clone under the ghq root

ghq get <owner>/<name>

Cloning an empty repository warns; that is expected. Run everything after this inside the clone:

cd "$(ghq root)/github.com/<owner>/<name>"

4) Root commit on main

The fresh clone has no commits yet, so HEAD is an unborn branch named by the local init.defaultBranch — branch commands like git switch misbehave on it. Point HEAD at main directly, then create the empty root commit and push:

git symbolic-ref HEAD refs/heads/main
git commit --allow-empty -m "chore: init" -m "Co-Authored-By: <your harness's co-author line>"
git push -u origin main

The second -m carries the Co-Authored-By trailer your harness convention specifies — this commit is authored through the agent, same as any other.

5) Cut the scaffold branch

git switch -c scaffold

The branch name is fixed: scaffold, always. Local only — it gets pushed when the first real work goes up (typically via create-pr).

6) Report

Give the user the repository URL, the local path, and the current branch (scaffold), and note that main holds exactly one empty commit.

Boundaries

  • No project files. Directory layout, README, LICENSE, justfile, .gitignore — all of it is scaffold-branch work owned by other skills (writing-documents, build-justfile) or the user.
  • No PR. Opening the first PR belongs to create-pr.
  • No CI / branch protection / repo settings. Separate concerns, configured once there is something to protect.
  • Never proceed past step 1 without explicit confirmation of owner, name, and visibility — repository creation is public-facing and annoying to undo.
  • Stop and explain if gh, ghq, or auth is missing, or the target name already exists, rather than improvising.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.