Skip to content

Commit e6ef804

Browse files
committed
Fix: Add github mcp server action
1 parent 7c83c71 commit e6ef804

File tree

2 files changed

+118
-2
lines changed

2 files changed

+118
-2
lines changed
Lines changed: 116 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,116 @@
1+
name: Build and Publish GitHub MCP Server
2+
3+
on:
4+
workflow_dispatch:
5+
inputs:
6+
version:
7+
description: 'Package version (e.g. 0.0.1)'
8+
required: true
9+
default: '0.0.1'
10+
type: string
11+
uipath_access_token:
12+
description: 'UiPath Access Token'
13+
required: true
14+
type: string
15+
uipath_url:
16+
description: 'UiPath URL'
17+
required: true
18+
default: 'https://alpha.uipath.com/ada/byoa'
19+
type: string
20+
21+
jobs:
22+
build:
23+
runs-on: ubuntu-latest
24+
steps:
25+
- name: Checkout repository
26+
uses: actions/checkout@v4
27+
with:
28+
repository: github/github-mcp-server
29+
30+
- name: Set up Go
31+
uses: actions/setup-go@v5
32+
with:
33+
go-version: '1.21'
34+
35+
- name: Build MCP Server
36+
run: |
37+
cd cmd/github-mcp-server
38+
go build
39+
40+
- name: Set up Python
41+
uses: actions/setup-python@v5
42+
with:
43+
python-version: '3.10'
44+
45+
- name: Install UV
46+
run: pip install uv
47+
48+
- name: Prepare package directory
49+
run: |
50+
mkdir -p temp
51+
cp cmd/github-mcp-server/github-mcp-server temp
52+
53+
- name: Create MCP config file
54+
run: |
55+
cat > temp/mcp.json << EOF
56+
{
57+
"servers": {
58+
"github": {
59+
"command": "github-mcp-server",
60+
"args": ["stdio"],
61+
"env": {
62+
"GITHUB_PERSONAL_ACCESS_TOKEN": "x"
63+
}
64+
}
65+
}
66+
}
67+
EOF
68+
69+
- name: Create pyproject.toml
70+
run: |
71+
cat > temp/pyproject.toml << EOF
72+
[project]
73+
name = "mcp-github-server"
74+
version = "${{ github.event.inputs.version }}"
75+
description = "Official GitHub MCP Server"
76+
authors = [{ name = "John Doe" }]
77+
dependencies = [
78+
"uipath-mcp==0.0.71",
79+
]
80+
requires-python = ">=3.10"
81+
EOF
82+
83+
- name: Create .env file
84+
run: |
85+
cat > temp/.env << EOF
86+
UIPATH_ACCESS_TOKEN=${{ github.event.inputs.uipath_access_token }}
87+
UIPATH_URL=${{ github.event.inputs.uipath_url }}
88+
EOF
89+
90+
- name: Setup Python environment and package
91+
working-directory: ./temp
92+
run: |
93+
# Create and activate virtual environment
94+
uv venv -p 3.10 .venv
95+
source .venv/bin/activate
96+
97+
# Install dependencies
98+
uv sync
99+
100+
# Initialize uipath
101+
uipath init
102+
103+
# Modify uipath.json to add settings
104+
python -c "import json; f=open('uipath.json','r'); data=json.load(f); f.close(); data['settings']={'filesIncluded':['github-mcp-server']}; f=open('uipath.json','w'); json.dump(data,f,indent=4); f.close(); print('Updated uipath.json')"
105+
106+
# Show the modified file
107+
cat uipath.json
108+
109+
# Continue with packing
110+
uipath pack
111+
112+
- name: Upload artifact
113+
uses: actions/upload-artifact@v4
114+
with:
115+
name: mcp-github-server-${{ github.event.inputs.version }}
116+
path: temp/.uipath/mcp-github-server.${{ github.event.inputs.version }}.nupkg

pyproject.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
[project]
22
name = "uipath-mcp"
3-
version = "0.0.70"
3+
version = "0.0.71"
44
description = "UiPath MCP SDK"
55
readme = { file = "README.md", content-type = "text/markdown" }
66
requires-python = ">=3.10"
77
dependencies = [
88
"mcp==1.6.0",
99
"pysignalr==1.2.0",
10-
"uipath==2.0.18",
10+
"uipath==2.0.19",
1111
]
1212
classifiers = [
1313
"Development Status :: 3 - Alpha",

0 commit comments

Comments
 (0)