Skip to content

feat: /create-repository#34

Open
tmikula-dev wants to merge 8 commits into
masterfrom
feature/repository-creation-skill
Open

feat: /create-repository#34
tmikula-dev wants to merge 8 commits into
masterfrom
feature/repository-creation-skill

Conversation

@tmikula-dev

@tmikula-dev tmikula-dev commented Jul 23, 2026

Copy link
Copy Markdown
Collaborator

Overview

This pull request introduces the new create-repository skill, which automates the creation and configuration of GitHub repositories under the AbsaOSS (open source) or absa-group (internal) organizations. The skill runs an interactive interview, generates an annotated gh command plan, and executes it upon user confirmation, ensuring that all standard settings, labels, rules, and project links are applied consistently. The PR also adds robust documentation, a reusable ruleset asset, and evaluation scenarios to guide and test the skill.

Key Changes

  • Adding the /create-repository skill with our Absa guardrails and best practices
  • Adding the PR template to the repo

Related

Closes #https://github.com/absa-group/cps-organizational/issues/36

@tmikula-dev tmikula-dev self-assigned this Jul 23, 2026
@tmikula-dev tmikula-dev added the enhancement New feature or request label Jul 23, 2026
@tmikula-dev
tmikula-dev requested a review from HuvarVer July 23, 2026 13:41
@tmikula-dev tmikula-dev changed the title /create-repository Feat: /create-repository Jul 23, 2026
@tmikula-dev tmikula-dev changed the title Feat: /create-repository feat: /create-repository Jul 23, 2026
Comment thread skills/create-repository/SKILL.md Outdated

Run `gh auth status`. If it exits non-zero, **stop immediately** and tell the user:

> This skill needs an authenticated GitHub CLI with org-admin permissions for AbsaOSS / absa-group.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not sure if the permissions that are needed are org-admin, its really high permission category.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You are right, change done in d395a5d

### 4. Code owners (OSS repos only, ≥1 user)

**Only ask this for open source (`AbsaOSS`) repos.** Internal (`absa-group`) repos keep the template's
empty `CODEOWNERS`. An always-on org-level ruleset **prohibits committing straight to the default branch**

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is the CODEOWNERS file for internal repositories empty in this step?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is because CSO team added to every internal repository a mandatory Check appid.json file workflow, that is added automatically. But they did not think about option to merge a commit straight without PR. So when we try to modify CODEOWNERS directly, the appid.json check is pending and the change is not possible without PR.

Comment thread skills/create-repository/SKILL.md Outdated
If the `Write a different set of code owners` option is chosen, ask: "Enter the GitHub usernames for
the code owners."

A single global `CODEOWNERS` rule covers all files. Individuals only — no teams.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMHO, teams should be available too.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Correct, added in: d395a5d.

gh api -X PATCH repos/{owner}/{name} -F delete_branch_on_merge=true
```

8. Link the repository to project number {number} (https://github.com/orgs/absa-group/projects/{number}). ← private repos only (one block per project); omit otherwise

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it should automatically ask for adding the scope if the user token doesn't have it:
gh auth refresh -s read:project

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMO, this skill should do only repository creation scoped commands. If person does not have permission to add it to the absa-group project, then someone with correct permission should do it instead.

This command is refreshing existing login token and requesting extra permission, which can be overlooked by skill user and cause not wanted outcomes.

| Core Branches ruleset | ✓ |
| Auto-delete branches on merge | ✓ |

Template: https://github.com/absa-group/cps-repository-template

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am missing the information in this summary about which files are copied from the template repository. I think it can be useful for the user to know exactly what he created.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You are right, I added under Template another row called: Files copied from the template. See commit: d395a5d

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants