You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(aidd-vcs): add repo-init skill (init + publish a repository) (#269)
New skill aidd-vcs:00-repo-init: init a project's repository (git init, default branch, CONTRIBUTING.md, bootstrap commit) and, on request, create the remote and push. Provider- and mechanism-agnostic: host + reach (CLI, MCP, or API) resolved from VCS memory or environment, main as default-branch fallback. No hardcoded provider or fixed mechanism.
Conforms to the skill-authoring contract (R1-R13 + action anatomy).
Co-authored-by: Baptiste LAFOURCADE <baptiste.lafourcade@gmail.com>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|`-`|[SKILL.md](skills/00-repo-init/SKILL.md)|`Initialize a project's repository - resolve the default branch and VCS provider, run git init with a bootstrap commit, write CONTRIBUTING.md, and on request create the remote repository and push. Use when the user says "init a repo", "git init", "initialize version control", "set up a new repo", "start a project", "create the remote and push", or "publish this repo". Do NOT use for committing changes (use 01-commit), opening pull requests (use 02-pull-request), tagging releases (use 03-release-tag), or cloning an existing remote.`|
36
+
26
37
#### `skills/01-commit`
27
38
28
39
| Group | File | Description |
@@ -42,7 +53,7 @@ Auto-generated index of skills, agents, references and assets shipped by the `ai
|`-`|[SKILL.md](skills/02-pull-request/SKILL.md)|`Create a draft pull or merge request from the current branch. Use when the user says "open a pr", "open a pull request", "create a pr", "create a merge request", "open mr", "draft a pr for this branch", or invokes `/pull-request`. Do NOT use for committing changes, pushing a branch directly, tagging releases, merging an existing request, or amending commits.`|
56
+
|`-`|[SKILL.md](skills/02-pull-request/SKILL.md)|`Create a draft pull or merge request from the current branch. Use when the user ask to create a PR or invokes `/pull-request`.`|
Initializes a project's repository locally and, on request, on the remote host: `git init`, sets the default branch, resolves the provider, and can create the remote repository and push, returning its URL.
6
+
7
+
> Status: experimental.
8
+
9
+
## When to use
10
+
11
+
- Starting version control on a new project (e.g. right after scaffolding it).
12
+
- Creating the remote repository and pushing the initial state.
13
+
14
+
## When NOT to use
15
+
16
+
- Cloning an existing remote, opening pull requests, or tagging releases.
17
+
- Re-initializing a directory that is already a repository (the local step no-ops there).
18
+
19
+
## How to invoke
20
+
21
+
`aidd-vcs:00-repo-init`, or say "initialize a git repository here" / "create the remote and publish".
22
+
23
+
## Outputs
24
+
25
+
-`init`: an initialized `.git`, the default branch set, the resolved provider, and `origin` added when a remote URL is given.
26
+
-`publish`: the created remote repository and a push, returning its URL.
27
+
28
+
## Prerequisites
29
+
30
+
-`git` on the PATH. For `publish`, the resolved host's tooling (CLI, MCP, or API) available and authenticated.
31
+
32
+
## Technical details
33
+
34
+
Two actions: `init` (local) and `publish` (remote, outward-facing, confirms first). See [SKILL.md](SKILL.md).
description: Initialize a project's repository - resolve the default branch and VCS provider, run git init with a bootstrap commit, write CONTRIBUTING.md, and on request create the remote repository and push. Use when the user says "init a repo", "git init", "initialize version control", "set up a new repo", "start a project", "create the remote and push", or "publish this repo". Do NOT use for committing changes (use 01-commit), opening pull requests (use 02-pull-request), tagging releases (use 03-release-tag), or cloning an existing remote.
4
+
argument-hint: init | publish
5
+
---
6
+
7
+
# Repo Init
8
+
9
+
Initializes a project's repository locally and, on request, on the remote host, then returns the remote URL.
| 02 |`publish`| Create the remote repo on the resolved host and push, return its URL | cwd, non_interactive |
17
+
18
+
## Default flow
19
+
20
+
Chain `01 → 02`, testing each before the next. The router runs `init` alone for a local-only request, and runs `publish` after an `init` when asked to create the remote.
21
+
22
+
## Transversal rules
23
+
24
+
- The local step is idempotent. If the target is already a git work tree, `init` does nothing and reports.
25
+
-`init` makes one bootstrap commit (`--allow-empty`) so `HEAD` exists and is pushable. The project's real first commit stays the commit skill's job.
26
+
-`publish` is outward-facing. It confirms before creating the remote unless `non_interactive` is set.
27
+
- The provider is open. Resolve the host and how to reach it (CLI, MCP, or API) from the VCS memory when present, else from the VCS tooling available in the environment. Never restrict to a fixed list or a fixed mechanism. `main` is the default-branch fallback.
28
+
29
+
## Assets
30
+
31
+
-`assets/CONTRIBUTING.md`: the project-root `CONTRIBUTING.md` template.
32
+
33
+
## External data
34
+
35
+
-`aidd_docs/memory/vcs.md`: the project's VCS config (default branch, provider), read by both actions when present and pointed to, never copied.
Initialize a fresh local git repository on the resolved default branch.
4
+
5
+
## Input
6
+
7
+
-`cwd` (optional): directory to initialize. Defaults to the current directory.
8
+
-`default_branch` (optional): overrides the resolved branch.
9
+
-`remote_url` (optional): added as `origin` when given.
10
+
11
+
## Output
12
+
13
+
A report of the repo root, the resolved default branch and provider, and whether `origin` was added. Reports `created: false` and stops when the target is already a git work tree.
14
+
15
+
## Process
16
+
17
+
1.**Guard.** If `cwd` is already a git work tree, skip and report `created: false`.
18
+
2.**Resolve.** Read the default branch and provider from the project's VCS memory. If absent, infer the provider from the environment (an installed VCS CLI, a configured MCP, or an existing remote URL). Fall back to `main` when nothing resolves. An explicit `default_branch` wins.
19
+
3.**Init.** Run `git init -b <default_branch> <cwd>`.
20
+
4.**Contribute.** Write `CONTRIBUTING.md` at the repo root from the template, filling `{{PROJECT_NAME}}`. Leave no raw `{{...}}`.
21
+
22
+
```markdown
23
+
@../assets/CONTRIBUTING.md
24
+
```
25
+
26
+
5.**Bootstrap.** Commit once so `HEAD` exists and is pushable: `git -C <cwd> commit --allow-empty -m "chore: initialize repository"`.
27
+
6.**Remote.** If `remote_url` is given, run `git -C <cwd> remote add origin <remote_url>`.
28
+
29
+
## Test
30
+
31
+
-`git -C <cwd> rev-parse --is-inside-work-tree` prints `true`.
Create the project's remote repository on the resolved host and push to it. Outward-facing; runs after `01-init`.
4
+
5
+
## Input
6
+
7
+
-`cwd` (optional): the initialized local repository. Defaults to the current directory.
8
+
-`non_interactive` (optional, default `false`): skip the confirmation prompt for scaffolder or auto runs.
9
+
10
+
## Output
11
+
12
+
A report of the created remote URL, the resolved provider, and the pushed default branch.
13
+
14
+
## Process
15
+
16
+
1.**Resolve.** Read the host and how to reach it (CLI, MCP, or API) from the project's VCS memory. If absent, detect it from the VCS tooling available in the environment. Use no fixed provider list or fixed mechanism.
17
+
2.**Confirm.** Unless `non_interactive`, confirm before creating the remote. The remote may be public, so create it private by default.
18
+
3.**Create.** Create the remote repository and push through the resolved host tooling. `01-init` already left a pushable `HEAD`. If no host tooling is available, stop and report.
19
+
4.**Return.** Report the remote URL to the user.
20
+
21
+
## Test
22
+
23
+
- The action prints a non-empty remote URL.
24
+
-`git -C <cwd> remote get-url origin` resolves to that URL.
Copy file name to clipboardExpand all lines: plugins/aidd-vcs/skills/02-pull-request/SKILL.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
---
2
2
name: 02-pull-request
3
-
description: Create a draft pull or merge request from the current branch. Use when the user says "open a pr", "open a pull request", "create a pr", "create a merge request", "open mr", "draft a pr for this branch", or invokes `/pull-request`. Do NOT use for committing changes, pushing a branch directly, tagging releases, merging an existing request, or amending commits.
3
+
description: Create a draft pull or merge request from the current branch. Use when the user ask to create a PR or invokes `/pull-request`.
0 commit comments