agentleFS
MicrosoftKnown publishermicrosoft/amplifier-bundle-gitea/skills/gitea/SKILL.md

gitea

Skill2 starsChanged 8 months agoMITView on GitHub

Use when managing ephemeral Gitea Docker environments, mirroring GitHub repos for isolated work, or promoting changes back to GitHub as PRs. Triggers on gitea, ephemeral git, isolated git environment, git sandbox for experiments/testing/demos, mirror repo, promote branch, disposable git server with issues/PRs/API access.

5 other projects use a version of this.

Adopted by

Most recently taken up by

  • Other versions5 projects use a version of this.

    Word for word · 0

    None found.

    Edited · 0

    None found.

    Wrote their own version · 5

    1. lawless-m/claude-skills★ 6same name
    2. Aidas-dev/k8s-agent-skills★ 4same name
    3. dekoza/oh-my-slop★ 4same name
    4. zzci/skills★ 2same name
    5. tendant/simple-skills★ 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 repositoryOne other file it gives its agents.

The file

We split this skill into the rules it gives an agent

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

  • 0

    Common

    Most of the 4 edited versions we read keep these.

  • 3

    Distinctive

    This author's own choices. Worth a look.

  • 2

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Before any gitea operation, verify the environment:

    line 13
  2. Very specific:

    If amplifier-gitea is not found:

    line 23
  3. Distinctive:

    If Docker is not running:

    line 28
  4. Distinctive:

    WSL: Start Docker Desktop on Windows, ensure WSL integration is enabled

    line 31
  5. Very specific:

    If the user has gh auth login done, no extra token configuration is needed.

    line 74

“Common” is measured: kept by at least 6 in 10 of the 4 edited versions of this file we could read. “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

Gitea Ephemeral Environments

amplifier-gitea is a CLI for on-demand, ephemeral Gitea Docker containers. All commands output JSON to stdout.

Prerequisites Check

Before any gitea operation, verify the environment:

# 1. Is the CLI installed?
which amplifier-gitea

# 2. Is Docker available and running?
which docker && docker info > /dev/null 2>&1 && echo "Docker OK" || echo "Docker NOT running"

If amplifier-gitea is not found:

uv tool install git+https://github.com/microsoft/amplifier-bundle-gitea@main

If Docker is not running:

  • Linux: sudo systemctl start docker
  • macOS: open -a Docker
  • WSL: Start Docker Desktop on Windows, ensure WSL integration is enabled

If prerequisites are missing, report clearly and stop. Do not attempt workarounds.

Documentation

For overview, quick start, installation, and workflow examples:

read_file("@gitea:README.md")

For complete CLI reference with all flags, output schemas, and Gitea API examples:

read_file("@gitea:docs/api_reference.md")

For development setup, testing, and design decisions:

read_file("@gitea:docs/development.md")

Key Details

Admin Credentials

Every environment is created with an admin account and a unique random password returned by create. The service binds to 127.0.0.1 by default; pass --bind-address 0.0.0.0 only when remote access is required. The Gitea web UI is accessible at http://localhost:<port> and the Swagger API docs at http://localhost:<port>/swagger.

Mirroring Performance

By default mirror-from-github copies only git content (full history + all branches) and skips metadata. This is fast -- typically a few seconds.

Issues and PRs are the expensive part. Enabling --include-issues --include-prs can take several minutes depending on the repo size. Only opt in when you actually need it.

GitHub Token Resolution

GitHub sync commands (mirror-from-github, promote-to-github) resolve tokens in this order:

  1. --github-token flag (explicit)
  2. GH_TOKEN environment variable
  3. gh auth token CLI command

If the user has gh auth login done, no extra token configuration is needed.

Deploying Local Changes Without Committing

To test a local repo's working tree (committed + staged + unstaged + untracked + deletions) through a Gitea mirror without committing or staging anything in the source repo, snapshot it into a throwaway clone and push from there. Use this when the mirror must reflect your exact local state but you must not mutate the source repo (no git add/commit/stash in it).

First make sure the repo exists in Gitea (mirror-from-github <id> --github-repo ... or create an empty repo), then:

PORT=...   # from `amplifier-gitea status <id>`
TOKEN=...  # from `amplifier-gitea token <id>`
SNAP="$(mktemp -d)/<repo-name>"
git clone --local --no-hardlinks "<local-repo>" "$SNAP"
# overlay staged + unstaged + untracked (non-ignored) files from the working tree
( cd "<local-repo>" && git ls-files -z --cached --modified --others --exclude-standard ) \
  | rsync -a --files-from=- --from0 "<local-repo>/" "$SNAP/"
# mirror tracked-file deletions
( cd "<local-repo>" && git ls-files -z --deleted ) \
  | ( cd "$SNAP" && xargs -0 --no-run-if-empty rm -f )
# single throwaway commit IN THE SNAPSHOT, then force-push to the mirror
cd "$SNAP"
git -c user.email=snapshot@local -c user.name="Gitea Snapshot" add -A
git -c user.email=snapshot@local -c user.name="Gitea Snapshot" commit --allow-empty -m "working-tree snapshot"
git -c credential.helper= push --force \
  "http://admin:$TOKEN@localhost:$PORT/admin/<repo-name>.git" HEAD:refs/heads/main

All git add/commit happens only in the temp snapshot, never in the source repo. If snapshotting fails, abort -- never fall back to operating on the source working tree.

Troubleshooting

ProblemFix
command not found: amplifier-giteauv tool install git+https://github.com/microsoft/amplifier-bundle-gitea@main
Cannot connect to the Docker daemonStart Docker: sudo systemctl start docker (Linux) or open Docker Desktop (macOS/Windows)
port is already allocatedChoose a different --port value, or amplifier-gitea list to find existing environments
mirror-from-github fails on private repoPass --github-token or ensure gh auth login is done
Token lost after createRun amplifier-gitea token <id> to generate a new one
promote-to-github 404 errorVerify --github-repo is in owner/repo format (not a full URL)
No GitHub token foundRun gh auth login, or set GH_TOKEN, or pass --github-token
Branch already exists on promoteThe --github-branch already exists on the target repo. Use a different branch name.

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.