Index of every page on this site: llms.txt
All skills
mcollina avatar

/octocat

@c75d70d
by Matteo Collinamcollina/skills2k stars
146
Run it yourself

Use this skill whenever the prompt contains any `github.com` URL, even if the user only pastes a link and gives no GitHub-specific keywords. Handles git and GitHub operations using the gh CLI. Triggers include any GitHub link to an issue, pull request, commit, compare page, Actions run, release, discussion, or repository. Covers creating and reviewing PRs, repository security advisories (GHSA), their comments, and fix PRs in their temporary private forks, private vulnerability report discussions, watching CI checks, interactive rebasing, branch cleanup, submodule management, and repository archaeology with git log/blame/bisect.

Use this Skill: https://skilld.dev/gh/mcollina/skills/octocat

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

rulessecurity-advisory-lifecycle.md

≈1.5k tokens on demand. Your agent reads this file only when SKILL.md points to it.

Repository security advisory lifecycle

A repository advisory moves triage → draft → published. At triage or draft it can instead become closed.

private report ──► triage ──accept──► draft ──publish──► published
                     │                  │
                     └──────close───────┴──► closed
State How it gets there Visibility
triage A private vulnerability report (POST /repos/{owner}/{repo}/security-advisories/reports) Private: maintainers, reporter, advisory collaborators
draft A maintainer accepts a triage report ("Accept and open as draft"), or creates an advisory directly (POST /repos/{owner}/{repo}/security-advisories) Private
published A maintainer publishes a draft Public, and reviewed for the GitHub Advisory Database
closed A maintainer closes a triage report or draft that is not a vulnerability or will not be pursued Private; closed_at is set, published_at stays null
withdrawn Set by GitHub, not by the maintainer Read-only; withdrawn_at is set

Reading the state

set -o pipefail
repo='OWNER/REPO'
ghsa='GHSA-xxxx-xxxx-xxxx'
base="repos/$repo/security-advisories/$ghsa"
headers=(-H 'Accept: application/vnd.github+json' -H 'X-GitHub-Api-Version: 2022-11-28')

gh api "$base" "${headers[@]}" --jq '{state, created_at, published_at, closed_at, withdrawn_at}'

# Pending private reports. The list filter accepts triage, draft, published, closed (not withdrawn).
gh api "repos/$repo/security-advisories?state=triage&per_page=100" "${headers[@]}" --paginate \
  --jq '.[] | {ghsa_id, summary, created_at}'

Changing the state

PATCH /repos/{owner}/{repo}/security-advisories/{ghsa_id} accepts only state values draft, closed, and published. triage and withdrawn cannot be set. It requires a repository admin, security manager, or advisory collaborator, with a repo or repository_advisories:write token.

# triage -> draft (accept the report). Only when the user asks to accept it.
gh api --method PATCH "$base" "${headers[@]}" -f state=draft

# triage or draft -> closed. Only when the user asks to close; comment why first.
gh api --method PATCH "$base" "${headers[@]}" -f state=closed
  • A closed advisory can be reopened with state=draft (verified on an advisory created as a draft; reopening a closed triage report was not tested).
  • Setting triage or withdrawn returns 422.
  • Starting a temporary private fork does not move an advisory out of triage (private fork workflow).
  • Before closing a report, add a comment explaining the decision (comments workflow).
  • Read the advisory back after each change and report the new state.

Publishing is public and one-way

Never publish unless the user explicitly asks to publish that advisory. Publishing:

  • Discloses the advisory to everyone and submits it for the GitHub Advisory Database, which can trigger Dependabot alerts. Add the patched versions first.
  • Deletes the advisory's temporary private fork. Merge fix PRs upstream from the advisory page before publishing.
  • Is not reversible by the maintainer. There is no unpublish: an advisory published in error can only be deleted by GitHub Support.

Check the user's intent and the advisory's vulnerabilities[].patched_versions before running gh api --method PATCH "$base" "${headers[@]}" -f state=published.

Verification boundary

Verified on October 17, 2026 against the REST reference, the public OpenAPI description, and the GitHub Docs pages on managing private reports and publishing:

  • The advisory schema's state enum is published, closed, withdrawn, draft, triage. The update schema's is published, closed, draft. The list filter's is triage, draft, published, closed.
  • Private reports start in triage. Starting a private fork leaves them in triage. Accepting makes them a draft, and they can be closed from triage.
  • Publishing deletes the temporary private fork. A published advisory can be deleted only through Support.

Live runs on mcollina/skills (October 2 and 17, 2026) with gh and an OAuth token carrying repo, on synthetic advisories:

  • Created advisories start in draft; PATCH state=closed set closed_at and left published_at: null.
  • PATCH state=draft on a closed advisory reopened it to draft and cleared closed_at.
  • PATCH state=triage and state=withdrawn returned 422 with Invalid property /state: `triage` is not a possible value. Must be one of the following: published, closed, draft.
  • A repository admin cannot submit a private report to their own repository: POST .../security-advisories/reports returned 403 You are not authorized to report advisories in this repository via private vulnerability reporting. Testing triage needs a report from a different account.

The triage → draft and triage → closed PATCHes and publishing were not live-tested. Never publish a test advisory.

Source: SKILL.md on GitHub

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

1 warning1mo5 checks · Risk SAFE
  • Gen Agent Trust Hub1mo

    The skill provides comprehensive automation for GitHub workflows and security advisory management, including private vulnerability report triage. It is designed to trigger automatically whenever a GitHub URL is present in the prompt. While it includes robust instructions to treat external data as untrusted and specific rules to prevent the accidental disclosure of security fixes, the broad trigger and the ingestion of external content (such as issue comments and advisory bodies) present a surface for indirect prompt injection.

  • Socket1mo

    No alerts

  • Snyk1mo

    Risk: MEDIUM · 1 issue

  • Runlayer8mo

    1/1 file flagged

  • ZeroLeaks7mo

    Score: 93/100 · 2 sections analyzed

Signed by skilld at c75d70d. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub last month.

Activeupdated last month
Other metadata
metadata
{
  "tags": "git, github, gh-cli, version-control, merge-conflicts, pull-requests, security-advisories, private-fork"
}

README badge

README badge for mcollina/skills/octocat