Skip to content
Merged
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
47 changes: 47 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,12 @@
version: 2
updates:
# GitHub Actions version updates are scoped by GitHub to `directory: /`.
# This checks workflow files under `/.github/workflows` on the `dev` branch.
# Composite actions under `/.github/actions/*/action.yml` are not separately
# configurable for Dependabot version updates in `dependabot.yml`.
- package-ecosystem: github-actions
directory: /
target-branch: dev
schedule:
interval: weekly
day: monday
Expand All @@ -18,6 +23,7 @@ updates:

- package-ecosystem: cargo
directory: /
target-branch: dev
schedule:
interval: weekly
day: monday
Expand All @@ -34,6 +40,7 @@ updates:

- package-ecosystem: npm
directory: /
target-branch: dev
schedule:
interval: weekly
day: monday
Expand All @@ -50,6 +57,7 @@ updates:

- package-ecosystem: npm
directory: /cli
target-branch: dev
schedule:
interval: weekly
day: monday
Expand All @@ -64,8 +72,43 @@ updates:
patterns:
- '*'

- package-ecosystem: npm
directory: /sdk
target-branch: dev
schedule:
interval: weekly
day: monday
time: '09:00'
timezone: Asia/Shanghai
open-pull-requests-limit: 5
labels:
- dependencies
- javascript
groups:
npm-sdk:
patterns:
- '*'

- package-ecosystem: npm
directory: /mcp
target-branch: dev
schedule:
interval: weekly
day: monday
time: '09:00'
timezone: Asia/Shanghai
open-pull-requests-limit: 5
labels:
- dependencies
- javascript
groups:
npm-mcp:
patterns:
- '*'

- package-ecosystem: npm
directory: /gui
target-branch: dev
schedule:
interval: weekly
day: monday
Expand All @@ -82,6 +125,7 @@ updates:

- package-ecosystem: npm
directory: /doc
target-branch: dev
schedule:
interval: weekly
day: monday
Expand All @@ -98,6 +142,7 @@ updates:

- package-ecosystem: npm
directory: /libraries/logger
target-branch: dev
schedule:
interval: weekly
day: monday
Expand All @@ -114,6 +159,7 @@ updates:

- package-ecosystem: npm
directory: /libraries/md-compiler
target-branch: dev
schedule:
interval: weekly
day: monday
Expand All @@ -130,6 +176,7 @@ updates:

- package-ecosystem: npm
directory: /libraries/script-runtime
target-branch: dev
schedule:
interval: weekly
day: monday
Expand Down
38 changes: 38 additions & 0 deletions .github/mergify.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
pull_request_rules:
- name: auto-approve and merge Dependabot docs updates into dev
conditions:
- author = dependabot[bot]
- base = dev
- -draft
- files ~= ^doc/
- check-success = check-doc
actions:
review:
type: APPROVE
message: Automatically approving Dependabot docs update after docs CI passes.
merge:
method: merge

- name: auto-approve and merge Dependabot updates into dev
conditions:
- author = dependabot[bot]
- base = dev
- -draft
- check-success = release-preflight
- check-success = gui-release-preflight
- check-success = build
- check-success = lint
- check-success = check-type
- check-success = test
- check-success = test-gui
- check-success = test-sdk
- check-success = test-cli
- check-success = test-mcp
- check-success = test-libraries
- check-success = test-rust
actions:
review:
type: APPROVE
message: Automatically approving Dependabot update after all dev CI checks pass.
merge:
method: merge
1 change: 1 addition & 0 deletions .github/workflows/pull-request-doc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
pull_request:
branches:
- main
- dev
types: [opened, synchronize, reopened, ready_for_review]
paths:
- doc/**
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
pull_request:
branches:
- main
- dev
types: [opened, synchronize, reopened, ready_for_review]
paths-ignore:
- .attachments/**
Expand Down
16 changes: 15 additions & 1 deletion .github/workflows/release-cli.yml
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,20 @@ jobs:
shell: bash
run: |
shopt -s nullglob
min_size=$((1024 * 1024))
get_min_size_for_binding() {
local node_file="$1"
case "$(basename "$node_file")" in
napi-logger.*.node|napi-script-runtime.*.node)
echo $((512 * 1024))
;;
napi-md-compiler.*.node|napi-memory-sync-cli.*.node)
echo $((1024 * 1024))
;;
*)
echo $((256 * 1024))
;;
esac
}
for target_dir in cli/npm/*/; do
if [ ! -f "${target_dir}package.json" ]; then
continue
Expand All @@ -261,6 +274,7 @@ jobs:
if [ ! -f "$node_file" ]; then
continue
fi
min_size=$(get_min_size_for_binding "$node_file")
size=$(stat -c%s "$node_file" 2>/dev/null || stat -f%z "$node_file" 2>/dev/null || echo 0)
if [ "$size" -lt "$min_size" ]; then
echo "ERROR: ${node_file} is too small (${size} bytes), expected at least ${min_size} bytes"
Expand Down
42 changes: 42 additions & 0 deletions renovate.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"extends": [
"config:recommended",
"helpers:pinGitHubActionDigests"
],
"baseBranchPatterns": [
"dev"
],
"dependencyDashboard": true,
"prConcurrentLimit": 5,
"branchConcurrentLimit": 5,
"labels": [
"dependencies"
],
"packageRules": [
{
"matchManagers": [
"github-actions"
],
"addLabels": [
"github-actions"
]
},
{
"matchManagers": [
"npm"
],
"addLabels": [
"javascript"
]
},
{
"matchManagers": [
"cargo"
],
"addLabels": [
"rust"
]
}
]
}
Loading