Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
9f44699
Initial plan
Copilot Mar 13, 2026
d56443f
Initial plan
Copilot Mar 13, 2026
7ff5eb8
feat: add daily automated lint and type-check workflow
Copilot Mar 13, 2026
a91d3fa
Add GitHub Actions for automated upstream sync and PR labeling
Copilot Mar 13, 2026
16e4d6f
plan: add Agent Skills spec validation workflow
Copilot Mar 13, 2026
4b41a1a
feat: add Agent Skills spec validation and Markdown linting
Copilot Mar 13, 2026
7508158
Enrich upstream sync with conflict detection and diff reporting
Copilot Mar 13, 2026
247830c
Automate upstream sync with rich conflict/diff reporting (#3)
d33disc Mar 13, 2026
8aa4a52
fix: critical mdformat SKILL.md corruption, pin tool versions, add ma…
Copilot Mar 13, 2026
18a4795
Merge branch 'main' into copilot/setup-automatic-linting-typechecking
d33disc Mar 13, 2026
703de64
Add automated daily lint, typecheck, Markdown formatting, and Agent S…
d33disc Mar 13, 2026
c0b27e1
Add wiki generator, static pages, and auto-update workflow
Copilot Mar 13, 2026
032b3a6
Fix American English spelling: licence → license
Copilot Mar 13, 2026
5d888e0
chore: auto-fix lint issues [skip ci]
github-actions[bot] Mar 14, 2026
1bc9adc
chore: auto-fix lint issues [skip ci]
github-actions[bot] Mar 15, 2026
d799ce9
Add tufte-swiss-typography skill
d33disc Mar 19, 2026
14e8438
Fix broken YAML frontmatter in 17 skills
d33disc Mar 19, 2026
b4fea7f
Add git-workflow, tdd skills + tangent, reality-check agents
d33disc Mar 19, 2026
cae5493
Bump GitHub Actions to Node.js 24, fix wiki deploy (#7)
d33disc Mar 19, 2026
7707087
Initial plan
Copilot Mar 19, 2026
748f583
Address PR #1 review comments: pin tool versions, fix mdformat scope,…
Copilot Mar 19, 2026
39a90d1
chore: auto-fix lint issues [skip ci]
github-actions[bot] Mar 19, 2026
eb1a98e
Merge branch 'main' into copilot/continue-working-on-pr-1
d33disc Mar 19, 2026
7a900b7
Address unresolved review comments from PR #1: pin versions, fix mdfo…
d33disc Mar 19, 2026
cec36ee
fix(tufte-swiss): universal font support, fontspec warnings, skill re…
d33disc Mar 21, 2026
7807b19
chore: add .gitignore, symlink ToolUniverse skills (#10)
d33disc Mar 22, 2026
dda4818
chore: remove slack-gif-creator (#11)
d33disc Mar 22, 2026
71257a7
feat: add ascii codebase diagramming skill
d33disc Mar 23, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add GitHub Actions for automated upstream sync and PR labeling
Co-authored-by: d33disc <[email protected]>
  • Loading branch information
Copilot and d33disc committed Mar 13, 2026
commit a91d3fab025bab60abaf316adaf37e713c6241eb
5 changes: 5 additions & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# CODEOWNERS
# Ensures the repo maintainer is automatically requested for review on all PRs.
# https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners

* @d33disc
24 changes: 24 additions & 0 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Path-based label configuration for actions/labeler@v5
# https://github.com/actions/labeler

"skills":
- changed-files:
- any-glob-to-any-file: "skills/**"

"spec":
- changed-files:
- any-glob-to-any-file: "spec/**"

"template":
- changed-files:
- any-glob-to-any-file: "template/**"

"documentation":
- changed-files:
- any-glob-to-any-file:
- "*.md"
- "**/*.md"

"github-actions":
- changed-files:
- any-glob-to-any-file: ".github/**"
28 changes: 28 additions & 0 deletions .github/labels.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# GitHub Labels
# Consumed by the label-pr and sync-upstream workflows.
# Apply with: gh label create --force ... (or via a labels-sync action)

labels:
- name: upstream-sync
color: "0075ca"
description: "Automated PR syncing changes from anthropics/skills"

- name: skills
color: "e4e669"
description: "Changes to one or more skills"

- name: spec
color: "d93f0b"
description: "Changes to the Agent Skills specification"

- name: template
color: "bfd4f2"
description: "Changes to the skill template"

- name: documentation
color: "0052cc"
description: "Documentation improvements"

- name: github-actions
color: "f9d0c4"
description: "Changes to GitHub Actions workflows or configuration"
21 changes: 21 additions & 0 deletions .github/workflows/label-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: Label Pull Requests

on:
pull_request_target:
types: [opened, synchronize, reopened]

permissions:
contents: read
pull-requests: write

jobs:
label:
name: Auto-label PR
runs-on: ubuntu-latest

steps:
- name: Apply path-based labels
uses: actions/labeler@v5
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
configuration-path: .github/labeler.yml
170 changes: 170 additions & 0 deletions .github/workflows/sync-upstream.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,170 @@
name: Sync with Upstream

on:
schedule:
# Runs daily at 06:00 UTC
- cron: '0 6 * * *'
workflow_dispatch:
inputs:
dry_run:
description: 'Dry run (check only, do not push)'
required: false
default: 'false'
type: boolean

permissions:
contents: write
pull-requests: write

jobs:
sync-upstream:
name: Sync anthropics/skills → main
runs-on: ubuntu-latest

steps:
- name: Checkout fork
uses: actions/checkout@v4
with:
# Full history is required so we can compare with upstream
fetch-depth: 0
token: ${{ secrets.GITHUB_TOKEN }}

- name: Configure git identity
run: |
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"

- name: Add upstream remote and fetch
run: |
git remote add upstream https://github.com/anthropics/skills.git
git fetch upstream main --no-tags

- name: Determine sync status
id: status
run: |
UPSTREAM_SHA=$(git rev-parse upstream/main)
LOCAL_SHA=$(git rev-parse origin/main)

echo "upstream_sha=$UPSTREAM_SHA" >> "$GITHUB_OUTPUT"
echo "local_sha=$LOCAL_SHA" >> "$GITHUB_OUTPUT"

if [ "$UPSTREAM_SHA" = "$LOCAL_SHA" ]; then
echo "in_sync=true" >> "$GITHUB_OUTPUT"
echo "✅ Already in sync with upstream (${UPSTREAM_SHA:0:7})"
else
echo "in_sync=false" >> "$GITHUB_OUTPUT"
BEHIND=$(git rev-list --count "origin/main..upstream/main")
echo "commits_behind=$BEHIND" >> "$GITHUB_OUTPUT"
echo "🔄 Fork is ${BEHIND} commit(s) behind upstream"
fi

- name: Nothing to do
if: steps.status.outputs.in_sync == 'true'
run: echo "Fork is already up-to-date. Exiting."

# ------------------------------------------------------------------ #
# Happy path: upstream is a strict ancestor of our local HEAD → just #
# fast-forward merge and push directly to main. #
# ------------------------------------------------------------------ #
- name: Fast-forward merge (no conflicts)
if: steps.status.outputs.in_sync == 'false' && inputs.dry_run != true
id: ff_merge
run: |
git checkout main

if git merge --ff-only upstream/main 2>/dev/null; then
echo "merged=true" >> "$GITHUB_OUTPUT"
echo "✅ Fast-forward successful"
else
echo "merged=false" >> "$GITHUB_OUTPUT"
echo "⚠️ Fast-forward not possible — diverged history. Will open a PR."
fi

- name: Push fast-forward merge to main
if: |
steps.status.outputs.in_sync == 'false' &&
steps.ff_merge.outputs.merged == 'true' &&
inputs.dry_run != true
run: git push origin main

# ------------------------------------------------------------------ #
# Fallback: histories have diverged → create a PR so the maintainer #
# can review conflicts and decide what to keep. #
# ------------------------------------------------------------------ #
- name: Check for existing sync PR
if: |
steps.status.outputs.in_sync == 'false' &&
steps.ff_merge.outputs.merged == 'false' &&
inputs.dry_run != true
id: existing_pr
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
OPEN=$(gh pr list \
--base main \
--label upstream-sync \
--state open \
--json number \
--jq '.[0].number // empty')
echo "pr_number=${OPEN}" >> "$GITHUB_OUTPUT"
if [ -n "$OPEN" ]; then
echo "ℹ️ Existing sync PR #${OPEN} already open — skipping creation."
fi

- name: Create sync branch and open PR
if: |
steps.status.outputs.in_sync == 'false' &&
steps.ff_merge.outputs.merged == 'false' &&
steps.existing_pr.outputs.pr_number == '' &&
inputs.dry_run != true
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
BRANCH="sync/upstream-$(date +%Y%m%d-%H%M%S)"
git checkout -b "$BRANCH"

# Attempt a regular merge; capture conflicts without aborting the job
if git merge upstream/main \
--no-edit \
-m "chore: sync with upstream anthropics/skills"; then
CONFLICT_NOTE=""
else
# Stage everything (including conflict markers) so the PR is visible
git add -A
git commit -m "chore: sync with upstream (conflict markers included)"
CONFLICT_NOTE="> ⚠️ **Merge conflicts were detected.** Please resolve them before merging this PR."
fi

git push origin "$BRANCH"

gh pr create \
--title "chore: sync with upstream anthropics/skills" \
--body "## 🔄 Automated Upstream Sync

This PR brings in **${{ steps.status.outputs.commits_behind }} new commit(s)** from \
[anthropics/skills](https://github.com/anthropics/skills/commits/main) \
(upstream SHA: \`${{ steps.status.outputs.upstream_sha }}\`).

${CONFLICT_NOTE}

**What to do:**
1. Review the diff below.
2. Resolve any conflicts if flagged above.
3. Merge when ready.

> _This PR was opened automatically by the [Sync with Upstream](${{ github.server_url }}/${{ github.repository }}/actions/workflows/sync-upstream.yml) workflow._" \
--base main \
--head "$BRANCH" \
--label "upstream-sync"

# ------------------------------------------------------------------ #
# Dry-run summary #
# ------------------------------------------------------------------ #
- name: Dry-run summary
if: inputs.dry_run == true
run: |
echo "=== DRY RUN SUMMARY ==="
echo "Upstream SHA : ${{ steps.status.outputs.upstream_sha }}"
echo "Local SHA : ${{ steps.status.outputs.local_sha }}"
echo "In sync : ${{ steps.status.outputs.in_sync }}"
echo "Commits behind: ${{ steps.status.outputs.commits_behind }}"