Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
89 changes: 89 additions & 0 deletions .config/deny.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,89 @@
# Cargo-deny configuration for deepwiki-mcp-server extension
# See: https://embarkstudios.github.io/cargo-deny/

[graph]
targets = [
"wasm32-wasip1", # Primary target for Zed extensions
]
all-features = false
no-default-features = false

[output]
feature-depth = 1

[advisories]
# The path where the advisory databases are cloned/fetched into
db-path = "~/.cargo/advisory-db"
# The url(s) of the advisory databases to use
db-urls = ["https://github.com/rustsec/advisory-db"]
# A list of advisory IDs to ignore
ignore = [
# Add specific advisories to ignore here if needed after review
#"RUSTSEC-0000-0000",
]

[licenses]
# List of explicitly allowed licenses
allow = [
"MIT",
"Apache-2.0",
"Apache-2.0 WITH LLVM-exception",
"Unicode-DFS-2016",
"Unicode-3.0",
"Zlib",
]
# The confidence threshold for detecting a license from license text
confidence-threshold = 0.8
# Allow specific licenses for individual crates
exceptions = [
# Serde ecosystem
{ allow = ["MIT", "Apache-2.0"], crate = "serde" },
{ allow = ["MIT", "Apache-2.0"], crate = "serde_json" },
{ allow = ["MIT", "Apache-2.0"], crate = "serde_derive" },
# JSON schema library
{ allow = ["MIT"], crate = "schemars" },
]

[licenses.private]
ignore = false
registries = []

[bans]
# Lint level for when multiple versions of the same crate are detected
multiple-versions = "warn"
# Lint level for when a crate version requirement is `*`
wildcards = "deny"
# The graph highlighting used when creating dotgraphs for crates with multiple versions
highlight = "all"
# Default features configuration
workspace-default-features = "allow"
external-default-features = "allow"

# List of crates to deny
deny = [
# Insecure cryptographic libraries
{ crate = "openssl", reason = "Use rustls instead for better security" },
{ crate = "native-tls", reason = "Use rustls instead for better security" },
# Unmaintained or problematic crates
{ crate = "chrono", reason = "Use time crate for new code" },
]

# Certain crates/versions that will be skipped when doing duplicate detection
skip = []

skip-tree = []

[sources]
# Lint level for what to happen when a crate from a crate registry that is not in the allow list
unknown-registry = "warn"
# Lint level for what to happen when a crate from a git repository that is not in the allow list
unknown-git = "warn"
# List of URLs for allowed crate registries
allow-registry = ["https://github.com/rust-lang/crates.io-index"]
# List of URLs for allowed Git repositories
allow-git = []

[sources.allow-org]
github = []
gitlab = []
bitbucket = []
81 changes: 81 additions & 0 deletions .config/lefthook.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
# Lefthook configuration for DeepWiki MCP Server Extension
# Optimized for WASM-based Zed extension development

pre-commit:
parallel: true
commands:
format:
glob: "**/*.rs"
run: cargo fmt --check
stage_fixed: true

clippy-wasm:
glob: "**/*.rs"
run: cargo clippy --target wasm32-wasip1 -- -D warnings

test:
glob: "**/*.rs"
run: cargo test

extension-manifest:
glob: "extension.toml"
run: echo "✓ Extension manifest updated"

wasm-check:
glob: "src/**/*.rs"
run: cargo check --target wasm32-wasip1

pre-push:
parallel: true
commands:
build-extension-release:
glob: "src/**/*.rs"
run: cargo build --target wasm32-wasip1 --release

comprehensive-test:
run: cargo test --all-features

extension-validation:
glob: "extension.toml"
run: |
echo "Validating extension configuration..."
if [ -f extension.toml ]; then
echo "✓ extension.toml exists"
else
echo "✗ extension.toml missing"
exit 1
fi

documentation-check:
glob: "{README.md,BUILD.md}"
run: |
echo "Checking documentation consistency..."
if grep -q "zed-mcp-proxy" README.md && grep -q "wasm32-wasip1" BUILD.md; then
echo "✓ Documentation up to date"
else
echo "⚠ Documentation may need updates"
fi

# Skip hooks for specific scenarios
skip_output:
- meta
- summary

# Configuration for different environments
staging:
pre-commit:
parallel: true
commands:
quick-check:
run: cargo check --target wasm32-wasip1

production:
pre-commit:
parallel: true
commands:
full-validation:
run: |
cargo fmt --check &&
cargo clippy --target wasm32-wasip1 -- -D warnings &&
cargo test &&
cargo build --target wasm32-wasip1 --release
36 changes: 36 additions & 0 deletions .config/release.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# Release configuration for deepwiki-mcp-server Zed extension
# Configured for WASM-based Zed extension releases

# Enable semantic versioning and changelog management
pre-release-replacements = [
{ file = "CHANGELOG.md", search = "## \\[Unreleased\\]", replace = "## [Unreleased]\n\n## [{{version}}] - {{date}}" },
{ file = "extension.toml", search = "version = \".*\"", replace = "version = \"{{version}}\"" },
{ file = "Cargo.toml", search = "version = \".*\"", replace = "version = \"{{version}}\"" },
]

# Configure git operations for extension repository
allow-branch = ["main", "master"]
sign-commit = false
sign-tag = false
push-remote = "origin"

# Configure publishing - extensions are distributed through Zed registry
publish = false

# Configure tagging for extension releases
tag-message = "Release deepwiki-mcp-server extension {{version}}"
tag-prefix = "extension-v"

# Pre-release hooks for WASM extension quality assurance
pre-release-hook = [
"cargo fmt --check",
"cargo clippy --target wasm32-wasip1 -- -D warnings",
"cargo nextest run",
"cargo build --target wasm32-wasip1 --release",
]

# Dependencies update configuration
dependent-version = "upgrade"

# Extension-specific configuration
consolidate-commits = false
69 changes: 69 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
version: 2
updates:
# Cargo dependencies for the main extension
- package-ecosystem: "cargo"
directory: "/"
schedule:
interval: "weekly"
day: "monday"
time: "09:00"
timezone: "UTC"
open-pull-requests-limit: 5
target-branch: "main"
commit-message:
prefix: "deps"
prefix-development: "deps-dev"
include: "scope"
labels:
- "dependencies"
- "rust"
reviewers:
- "keshav1998"
assignees:
- "keshav1998"
milestone: null
allow:
- dependency-type: "direct"
- dependency-type: "indirect"
ignore:
# Ignore patch updates for stable dependencies
- dependency-name: "serde"
update-types: ["version-update:semver-patch"]
- dependency-name: "serde_json"
update-types: ["version-update:semver-patch"]
groups:
# Group serde ecosystem updates
serde:
patterns:
- "serde*"
update-types:
- "minor"
- "patch"
# Group Zed extension API updates
zed-api:
patterns:
- "zed_extension_api"
update-types:
- "minor"
- "patch"

# GitHub Actions workflow dependencies
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
day: "monday"
time: "10:00"
timezone: "UTC"
open-pull-requests-limit: 3
target-branch: "main"
commit-message:
prefix: "ci"
include: "scope"
labels:
- "dependencies"
- "github-actions"
reviewers:
- "keshav1998"
assignees:
- "keshav1998"
Loading
Loading