Skip to content

Commit cc80810

Browse files
authored
Merge branch 'main' into main
2 parents 6ef1bf8 + df347e3 commit cc80810

File tree

113 files changed

+6598
-2861
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

113 files changed

+6598
-2861
lines changed

.github/workflows/close-inactive-issues.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ jobs:
77
close-issues:
88
runs-on: ubuntu-latest
99
env:
10-
PR_DAYS_BEFORE_STALE: 60
11-
PR_DAYS_BEFORE_CLOSE: 120
10+
PR_DAYS_BEFORE_STALE: 30
11+
PR_DAYS_BEFORE_CLOSE: 60
1212
PR_STALE_LABEL: stale
1313
permissions:
1414
issues: write
@@ -21,8 +21,8 @@ jobs:
2121
stale-issue-label: ${{ env.PR_STALE_LABEL }}
2222
stale-issue-message: "This issue is stale because it has been open for ${{ env.PR_DAYS_BEFORE_STALE }} days with no activity. Leave a comment to avoid closing this issue in ${{ env.PR_DAYS_BEFORE_CLOSE }} days."
2323
close-issue-message: "This issue was closed because it has been inactive for ${{ env.PR_DAYS_BEFORE_CLOSE }} days since being marked as stale."
24-
days-before-pr-stale: -1
25-
days-before-pr-close: -1
24+
days-before-pr-stale: ${{ env.PR_DAYS_BEFORE_STALE }}
25+
days-before-pr-close: ${{ env.PR_DAYS_BEFORE_STALE }}
2626
# Start with the oldest items first
2727
ascending: true
2828
repo-token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/code-scanning.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ jobs:
3838
uses: actions/checkout@v5
3939

4040
- name: Initialize CodeQL
41-
uses: github/codeql-action/init@v3
41+
uses: github/codeql-action/init@v4
4242
with:
4343
languages: ${{ matrix.language }}
4444
build-mode: ${{ matrix.build-mode }}
@@ -52,13 +52,13 @@ jobs:
5252
threat-models: [ ]
5353
- name: Setup proxy for registries
5454
id: proxy
55-
uses: github/codeql-action/start-proxy@v3
55+
uses: github/codeql-action/start-proxy@v4
5656
with:
5757
registries_credentials: ${{ secrets.GITHUB_REGISTRIES_PROXY }}
5858
language: ${{ matrix.language }}
5959

6060
- name: Configure
61-
uses: github/codeql-action/resolve-environment@v3
61+
uses: github/codeql-action/resolve-environment@v4
6262
id: resolve-environment
6363
with:
6464
language: ${{ matrix.language }}
@@ -70,10 +70,10 @@ jobs:
7070
cache: false
7171

7272
- name: Autobuild
73-
uses: github/codeql-action/autobuild@v3
73+
uses: github/codeql-action/autobuild@v4
7474

7575
- name: Perform CodeQL Analysis
76-
uses: github/codeql-action/analyze@v3
76+
uses: github/codeql-action/analyze@v4
7777
env:
7878
CODEQL_PROXY_HOST: ${{ steps.proxy.outputs.proxy_host }}
7979
CODEQL_PROXY_PORT: ${{ steps.proxy.outputs.proxy_port }}

.github/workflows/docker-publish.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ jobs:
4646
# https://github.com/sigstore/cosign-installer
4747
- name: Install cosign
4848
if: github.event_name != 'pull_request'
49-
uses: sigstore/cosign-installer@d7543c93d881b35a8faa02e8e3605f69b7a1ce62 #v3.10.0
49+
uses: sigstore/cosign-installer@faadad0cce49287aee09b3a48701e75088a2c6ad #v4.0.0
5050
with:
5151
cosign-release: "v2.2.4"
5252

@@ -70,7 +70,7 @@ jobs:
7070
# https://github.com/docker/metadata-action
7171
- name: Extract Docker metadata
7272
id: meta
73-
uses: docker/metadata-action@c1e51972afc2121e065aed6d45c65596fe445f3f # v5.8.0
73+
uses: docker/metadata-action@318604b99e75e41977312d83839a89be02ca4893 # v5.9.0
7474
with:
7575
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
7676
tags: |
@@ -127,3 +127,4 @@ jobs:
127127
# This step uses the identity token to provision an ephemeral certificate
128128
# against the sigstore community Fulcio instance.
129129
run: echo "${TAGS}" | xargs -I {} cosign sign --yes {}@${DIGEST}
130+

.github/workflows/lint.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,6 @@ jobs:
1818
with:
1919
go-version: stable
2020
- name: golangci-lint
21-
uses: golangci/golangci-lint-action@v8
21+
uses: golangci/golangci-lint-action@v9
2222
with:
23-
version: v2.1
23+
version: v2.5

.github/workflows/moderator.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: AI Moderator
2+
on:
3+
issues:
4+
types: [opened]
5+
issue_comment:
6+
types: [created]
7+
pull_request_review_comment:
8+
types: [created]
9+
10+
jobs:
11+
spam-detection:
12+
runs-on: ubuntu-latest
13+
permissions:
14+
issues: write
15+
pull-requests: write
16+
models: read
17+
contents: read
18+
steps:
19+
- uses: actions/checkout@v5
20+
- uses: github/ai-moderator@v1
21+
with:
22+
token: ${{ secrets.GITHUB_TOKEN }}
23+
spam-label: 'spam'
24+
ai-label: 'ai-generated'
25+
minimize-detected-comments: true
26+
enable-spam-detection: true
27+
enable-link-spam-detection: true
28+
enable-ai-detection: true

.github/workflows/registry-releaser.yml

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,25 @@ jobs:
2929
echo "Skipping tag fetch - already on tag ${{ github.ref_name }}"
3030
fi
3131
32+
- name: Wait for Docker image
33+
run: |
34+
if [[ "${{ github.ref_type }}" == "tag" ]]; then
35+
TAG="${{ github.ref_name }}"
36+
else
37+
TAG=$(git tag --sort=-version:refname | grep -E '^v[0-9]+\.[0-9]+\.[0-9]+$' | head -n1)
38+
fi
39+
IMAGE="ghcr.io/github/github-mcp-server:$TAG"
40+
41+
for i in {1..10}; do
42+
if docker manifest inspect "$IMAGE" &>/dev/null; then
43+
echo "✅ Docker image ready: $TAG"
44+
break
45+
fi
46+
[ $i -eq 10 ] && { echo "❌ Timeout waiting for $TAG after 5 minutes"; exit 1; }
47+
echo "⏳ Waiting for Docker image ($i/10)..."
48+
sleep 30
49+
done
50+
3251
- name: Install MCP Publisher
3352
run: |
3453
git clone --quiet https://github.com/modelcontextprotocol/registry publisher-repo
@@ -40,7 +59,7 @@ jobs:
4059
if [[ "${{ github.ref_type }}" == "tag" ]]; then
4160
TAG_VERSION=$(echo "${{ github.ref_name }}" | sed 's/^v//')
4261
else
43-
LATEST_TAG=$(git tag --sort=-version:refname | grep -E '^v[0-9]+\.[0-9]+\.[0-9]+(-.*)?$' | head -n 1)
62+
LATEST_TAG=$(git tag --sort=-version:refname | grep -E '^v[0-9]+\.[0-9]+\.[0-9]+$' | head -n 1)
4463
[ -z "$LATEST_TAG" ] && { echo "No release tag found"; exit 1; }
4564
TAG_VERSION=$(echo "$LATEST_TAG" | sed 's/^v//')
4665
echo "Using latest tag: $LATEST_TAG"

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,6 @@ bin/
1717
.DS_Store
1818

1919
# binary
20-
github-mcp-server
20+
github-mcp-server
21+
22+
.history

.golangci.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,11 @@ linters:
1111
- misspell
1212
- nakedret
1313
- revive
14+
- errcheck
15+
- staticcheck
16+
- govet
17+
- ineffassign
18+
- unused
1419
exclusions:
1520
generated: lax
1621
presets:

0 commit comments

Comments
 (0)