Skip to content

Commit 2bb3df6

Browse files
data-douserCopilotCopilot
authored
Update README.md and **/package.json files to prepare for open-source release (#14)
* Update package.json files : name, keywords & version Updates the package.json files for repo root, client & server in order to prepare for open-source release. * Update esbuild dev dependency to latest * Update license field in package.json files to reference LICENSE file (#15) * Update README.md Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Fix unzip command syntax in release installation docs (#16) --------- Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent baf5e3b commit 2bb3df6

File tree

8 files changed

+287
-181
lines changed

8 files changed

+287
-181
lines changed

.github/skills/upgrade-codeql-cli-and-packs/SKILL.md

Lines changed: 22 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,12 @@ This skill guides you through upgrading the CodeQL CLI version used by the MCP s
2222

2323
### Version Alignment Strategy
2424

25-
This repository uses a **CLI-aligned versioning strategy** for `ql-mcp-*` packs:
25+
This repository uses a **CLI-aligned versioning strategy** across all version-bearing files:
2626

2727
1. **`.codeql-version`**: Contains the target CLI version (e.g., `v2.23.9`)
28-
2. **`ql-mcp-*` pack versions**: Use the CLI version number without the "v" prefix (e.g., `2.23.9`)
29-
3. **`codeql/*-all` dependencies**: Must have `cliVersion <= target CLI version`
28+
2. **`package.json` versions**: All `package.json` files (root, client, server) use the CLI version number without the "v" prefix (e.g., `2.23.9`)
29+
3. **`ql-mcp-*` pack versions**: Use the CLI version number without the "v" prefix (e.g., `2.23.9`)
30+
4. **`codeql/*-all` dependencies**: Must have `cliVersion <= target CLI version`
3031

3132
### Why Database Compatibility Matters
3233

@@ -68,6 +69,24 @@ gh codeql set-version vX.XX.Y
6869
codeql version # Verify installation
6970
```
7071

72+
#### 1.3 Update package.json Versions
73+
74+
All `package.json` files must have their `version` field set to match the CLI version (without the "v" prefix):
75+
76+
| File | Field to Update |
77+
| --------------------- | --------------- |
78+
| `package.json` | `version` |
79+
| `client/package.json` | `version` |
80+
| `server/package.json` | `version` |
81+
82+
Example: If `.codeql-version` is `v2.23.9`, set all `package.json` versions to `"version": "2.23.9"`.
83+
84+
After updating, regenerate the lock file:
85+
86+
```bash
87+
npm install
88+
```
89+
7190
### Phase 2: Identify Compatible Pack Versions
7291

7392
#### 2.1 List Available Packs
File renamed without changes.

README.md

Lines changed: 112 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,53 +1,139 @@
11
# CodeQL Development MCP Server
22

3-
A comprehensive Model Context Protocol (MCP) server designed specifically for agentic AI development of CodeQL (QL) code. This server provides tools and resources to help AI assistants write, validate, and optimize CodeQL queries for security analysis and code quality.
3+
> Enabling AI-assisted CodeQL query development through the Model Context Protocol
44
5-
## Quick Start
5+
A comprehensive [Model Context Protocol (MCP)](https://modelcontextprotocol.io/) server designed specifically for agentic AI development of CodeQL (QL) code. This server provides tools, prompts, and resources to help AI assistants write, validate, and optimize CodeQL queries for security analysis and code quality.
66

7-
For users who want to quickly get started with the MCP server:
7+
## Features
88

9-
### Download and Install
9+
- **Comprehensive Tool Suite** - Wraps CodeQL CLI commands for query compilation, execution, testing, and database operations
10+
- **Multi-Language Support** - Supports CodeQL query development for 9 languages including Python, JavaScript, Java, C/C++, and more
11+
- **AI-Optimized Prompts** - Built-in prompts and resources that guide AI assistants through CodeQL development workflows
12+
- **Test-Driven Development** - Integrated testing tools for validating query accuracy with expected results
13+
- **Flexible Transport** - Supports both stdio and HTTP transport modes for different integration scenarios
1014

11-
1. Download the latest release from [GitHub Releases](https://github.com/advanced-security/codeql-development-mcp-server/releases)
12-
2. Extract the archive:
15+
## Limitations
16+
17+
- Requires CodeQL CLI to be installed separately
18+
- Performance depends on the size of CodeQL databases being analyzed
19+
- Some advanced CodeQL CLI features may not yet be exposed as tools
20+
21+
## Project Status
22+
23+
**Active Development** - This project is actively maintained and used in production environments for AI-assisted CodeQL development.
1324

14-
```bash
15-
tar -xzvf codeql-development-mcp-server-vX.X.X.tar.gz -C /path/to/destination
16-
```
25+
## Background
1726

18-
3. Configure VS Code by adding to your `mcp.json`:
27+
The `codeql-development-mcp-server` project is maintained by GitHub's CodeQL Expert Services team and builds (and hopefully improves) on the concepts from the [`advanced-security/codeql-development-template`](https://github.com/advanced-security/codeql-development-template) repository template.
1928

20-
```json
21-
{
22-
"servers": {
23-
"codeql-dev-mcp-server": {
24-
"command": "node",
25-
"args": ["/path/to/destination/server/dist/ql-mcp-server.js"],
26-
"type": "stdio"
27-
}
28-
}
29-
}
30-
```
29+
The main advantages of using the `codeql-development-mcp-server` are:
3130

32-
## Contributing
31+
1. **Agnostic of development environment**
32+
2. **Agnostic of calling Large Language Model (LLM)**
33+
3. **MCP server tools codify advanced CodeQL development practices**
3334

34-
We welcome contributions to this project! Please see [CONTRIBUTING.md](CONTRIBUTING.md) for detailed guidelines on how to contribute.
35+
### Roadmap
36+
37+
Development priorities and open issues are tracked in [GitHub Issues](https://github.com/advanced-security/codeql-development-mcp-server/issues).
38+
39+
### Contributing
40+
41+
We welcome contributions! Whether it's bug fixes, new features, documentation improvements, or additional language support, please see [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines.
3542

3643
Please note that this project is released with a [Contributor Code of Conduct](CODE_OF_CONDUCT.md). By participating in this project you agree to abide by its terms.
3744

45+
## Requirements
46+
47+
### Environment
48+
49+
- **Node.js** v25.2.1 or later ([nodejs.org](https://nodejs.org/))
50+
- **Some calling LLM** Bring your own LLM, but some LLMs are (much) better than others.
51+
52+
### External Dependencies
53+
54+
- **CodeQL CLI** - Must be installed and available in PATH ([github.com/github/codeql-cli-binaries](https://github.com/github/codeql-cli-binaries/releases))
55+
56+
## Quick Start
57+
58+
### Download and Install
59+
60+
1. Download the latest release from [GitHub Releases](https://github.com/advanced-security/codeql-development-mcp-server/releases)
61+
2. Extract the archive:
62+
63+
```bash
64+
unzip codeql-development-mcp-server-vX.X.X.zip -d /path/to/destination
65+
```
66+
67+
### VS Code Configuration
68+
69+
Add to your `mcp.json` file:
70+
71+
| OS | Location |
72+
| ------- | -------------------------------------------------- |
73+
| Linux | `~/.config/Code/User/mcp.json` |
74+
| macOS | `~/Library/Application Support/Code/User/mcp.json` |
75+
| Windows | `%APPDATA%\Code\User\mcp.json` |
76+
77+
```json
78+
{
79+
"servers": {
80+
"codeql-dev-mcp-server": {
81+
"command": "node",
82+
"args": ["/path/to/destination/server/dist/ql-mcp-server.js"],
83+
"type": "stdio"
84+
}
85+
}
86+
}
87+
```
88+
89+
### Installing from Source
90+
91+
```bash
92+
git clone https://github.com/advanced-security/codeql-development-mcp-server.git
93+
cd codeql-development-mcp-server
94+
npm install && npm run build
95+
```
96+
97+
### Verification
98+
99+
1. Restart VS Code
100+
2. Open Command Palette (`Ctrl+Shift+P` / `Cmd+Shift+P`)
101+
3. Run "GitHub Copilot: List MCP Servers"
102+
4. Confirm `codeql-dev-mcp-server` appears
103+
104+
## Supported Languages
105+
106+
| Language | CodeQL Identifier |
107+
| --------------------- | ----------------- |
108+
| GitHub Actions | `actions` |
109+
| C/C++ | `cpp` |
110+
| C# | `csharp` |
111+
| Go | `go` |
112+
| Java/Kotlin | `java` |
113+
| JavaScript/TypeScript | `javascript` |
114+
| Python | `python` |
115+
| Ruby | `ruby` |
116+
| Swift | `swift` |
117+
38118
## Documentation
39119

40-
- [Getting Started Guide](docs/getting-started.md) - Installation and setup instructions
41-
- [Tools Reference](docs/tools-reference.md) - Complete list of available MCP tools
120+
- [Getting Started Guide](docs/getting-started.md) - Detailed installation and setup instructions
121+
- [Tools Reference](docs/tools-reference.md) - Complete list of available MCP tools and usage examples
42122

43123
## License
44124

45-
See [LICENSE.md](LICENSE.md) for license terms.
125+
This project is licensed under the terms of the GitHub CodeQL Terms and Conditions. Please refer to [LICENSE](LICENSE) for the full terms.
46126

47127
## Maintainers
48128

49129
This repository is maintained by the team specified in [CODEOWNERS](CODEOWNERS).
50130

51131
## Support
52132

133+
This project uses GitHub issues to track bugs and feature requests. Please search existing issues before filing new ones to avoid duplicates.
134+
53135
This project comes with no expectation or guarantee of support, with more details in the [SUPPORT.md](SUPPORT.md) document.
136+
137+
## Acknowledgement
138+
139+
This project builds upon the [CodeQL CLI](https://github.com/github/codeql-cli-binaries) and the broader [CodeQL ecosystem](https://codeql.github.com/) developed by GitHub. Special thanks to the GitHub Advanced Security team and the open-source community for their contributions.

client/package.json

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "codeql-development-mcp-server_client",
3-
"version": "1.0.0",
3+
"version": "2.23.9",
44
"description": "MCP client for integration testing of the CodeQL development MCP server",
55
"main": "src/ql-mcp-client.js",
66
"type": "module",
@@ -9,20 +9,22 @@
99
},
1010
"keywords": [
1111
"codeql",
12-
"github",
12+
"development",
1313
"integration-testing",
14+
"llm",
1415
"mcp",
1516
"model-context-protocol",
1617
"ql",
1718
"sast",
1819
"security",
19-
"static-analysis"
20+
"static-analysis",
21+
"typescript"
2022
],
21-
"author": "GitHub",
22-
"license": "MIT",
23+
"author": "@github/ps-codeql",
24+
"license": "SEE LICENSE IN LICENSE",
2325
"engines": {
24-
"node": ">=24.10.0",
25-
"npm": ">=11.6.1"
26+
"node": ">=25.2.1",
27+
"npm": ">=11.6.2"
2628
},
2729
"dependencies": {
2830
"@modelcontextprotocol/sdk": "^1.26.0",

docs/getting-started.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ This guide covers installation, configuration, and usage of the CodeQL Developme
1313
### From GitHub Releases
1414

1515
1. Download the latest release from [Releases](https://github.com/advanced-security/codeql-development-mcp-server/releases)
16-
2. Extract: `tar -xzvf codeql-development-mcp-server-vX.X.X.tar.gz -C /path/to/destination`
16+
2. Extract: `unzip codeql-development-mcp-server-vX.X.X.zip -d /path/to/destination`
1717

1818
### From Source
1919

0 commit comments

Comments
 (0)