Skip to content

Commit 38c6905

Browse files
authored
Merge branch 'main' into perf/hashset-declaration-lookups
2 parents f37cb06 + 442b7fd commit 38c6905

File tree

323 files changed

+15648
-4806
lines changed

Some content is hidden

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

323 files changed

+15648
-4806
lines changed

.github/ISSUE_TEMPLATE/bug_report.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
name: "\U0001F41B Bug report"
33
about: Create a report to help us improve
44
title: ""
5-
labels: bug
5+
type: "Bug"
66
assignees: ""
77
---
88

.github/ISSUE_TEMPLATE/custom.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
---
22
name: Custom
3-
about: Open an issue in the repo that is neither a bug or a feature, such a new idea
3+
about: Open an issue in the repo that is neither a bug or a feature.
44
title: ""
55
labels: ""
6+
type: ""
67
assignees: ""
78
---
89

.github/ISSUE_TEMPLATE/feature_request.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@
22
name: "\U0001F680 Feature request"
33
about: Suggest a new ECMAScript feature to be implemented, or a new capability of the engine.
44
title: ""
5-
labels: enhancement
5+
type: "Feature"
6+
labels: ""
67
assignees: ""
78
---
89

.github/dependabot.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ updates:
44
directory: /
55
schedule:
66
interval: weekly
7+
labels:
8+
- "C-Dependencies"
9+
- "C-Actions"
710
groups:
811
ci-dependencies:
912
applies-to: version-updates
@@ -15,6 +18,8 @@ updates:
1518
directory: /
1619
schedule:
1720
interval: weekly
21+
labels:
22+
- "C-Dependencies"
1823
groups:
1924
rust-dependencies:
2025
applies-to: version-updates
@@ -26,6 +31,8 @@ updates:
2631
directory: /tests/fuzz/
2732
schedule:
2833
interval: weekly
34+
labels:
35+
- "C-Dependencies"
2936
groups:
3037
fuzz-dependencies:
3138
applies-to: version-updates

.github/labeler.yml

Lines changed: 86 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,86 @@
1+
C-Actions:
2+
- changed-files:
3+
- any-glob-to-any-file:
4+
- '.github/**'
5+
6+
C-AST:
7+
- changed-files:
8+
- any-glob-to-any-file: 'core/ast/**'
9+
10+
C-Benchmark:
11+
- changed-files:
12+
- any-glob-to-any-file:
13+
- 'benches/**'
14+
- 'core/engine/benches/**'
15+
16+
C-Builtins:
17+
- all:
18+
- changed-files:
19+
- any-glob-to-any-file:
20+
- 'core/engine/src/builtins/**'
21+
- 'core/engine/src/object/builtins/**'
22+
- all-globs-to-all-files:
23+
- '!core/engine/src/object/builtins/intl/**'
24+
25+
C-CLI:
26+
- changed-files:
27+
- any-glob-to-any-file:
28+
- 'cli/**'
29+
30+
C-Dependencies:
31+
- changed-files:
32+
- any-glob-to-any-file:
33+
- '**/Cargo.lock'
34+
- '**/Cargo.toml'
35+
36+
C-Documentation:
37+
- changed-files:
38+
- any-glob-to-any-file:
39+
- '**/*.md'
40+
41+
C-FFI:
42+
- changed-files:
43+
- any-glob-to-any-file:
44+
- 'ffi/**'
45+
46+
C-GC:
47+
- changed-files:
48+
- any-glob-to-any-file:
49+
- 'core/gc/**'
50+
51+
C-Intl:
52+
- changed-files:
53+
- any-glob-to-any-file:
54+
- 'core/engine/src/builtins/intl/**'
55+
56+
C-Javascript:
57+
- changed-files:
58+
- any-glob-to-any-file:
59+
- '**/*.js'
60+
61+
C-Parser:
62+
- changed-files:
63+
- any-glob-to-any-file:
64+
- 'core/parser/**'
65+
66+
C-Runtime:
67+
- changed-files:
68+
- any-glob-to-any-file:
69+
- 'core/runtime/**'
70+
71+
C-Tests:
72+
- changed-files:
73+
- any-glob-to-any-file:
74+
- '**/tests/**'
75+
- '**/test*'
76+
77+
C-VM:
78+
- changed-files:
79+
- any-glob-to-any-file:
80+
- 'core/engine/src/bytecompiler/**'
81+
- 'core/engine/src/vm/**'
82+
83+
C-WebAssembly:
84+
- changed-files:
85+
- any-glob-to-any-file:
86+
- 'ffi/wasm/**'

.github/release.yml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,18 @@ changelog:
77
categories:
88
- title: Feature Enhancements
99
labels:
10-
- enhancement
10+
- A-Enhancement
1111
- title: Bug Fixes
1212
labels:
13-
- bug
13+
- A-Bug
14+
- title: Performance Improvements
15+
labels:
16+
- A-Performance
17+
- A-Memory
1418
- title: Internal Improvements
1519
labels:
16-
- Internal
17-
- memory
20+
- A-Internal
21+
- A-Technical Debt
1822
- title: Other Changes
1923
labels:
2024
- "*"

.github/workflows/codeql.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: "CodeQL SAST Scanning"
2+
3+
on:
4+
workflow_dispatch:
5+
schedule:
6+
- cron: '0 0 * * 0' # Run weekly on Sundays
7+
8+
permissions:
9+
contents: read
10+
11+
jobs:
12+
analyze:
13+
name: Analyze
14+
runs-on: ubuntu-latest
15+
timeout-minutes: 60
16+
permissions:
17+
actions: read
18+
contents: read
19+
security-events: write
20+
21+
strategy:
22+
fail-fast: false
23+
matrix:
24+
language: [ 'rust' ]
25+
26+
steps:
27+
- name: Checkout repository
28+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
29+
with:
30+
persist-credentials: false
31+
32+
- name: Initialize CodeQL
33+
uses: github/codeql-action/init@c10b8064de6f491fea524254123dbe5e09572f13 # v4.35.1
34+
with:
35+
languages: ${{ matrix.language }}
36+
build-mode: none
37+
38+
- name: Perform CodeQL Analysis
39+
uses: github/codeql-action/analyze@c10b8064de6f491fea524254123dbe5e09572f13 # v4.35.1
40+
with:
41+
category: "/language:${{matrix.language}}"

.github/workflows/labeler.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
name: "Pull Request Labeler"
2+
on:
3+
- pull_request_target
4+
5+
permissions:
6+
contents: read
7+
8+
jobs:
9+
labeler:
10+
permissions:
11+
contents: read
12+
pull-requests: write
13+
runs-on: ubuntu-latest
14+
timeout-minutes: 10
15+
steps:
16+
- uses: actions/labeler@634933edcd8ababfe52f92936142cc22ac488b1b # v6

.github/workflows/nightly_build.yml

Lines changed: 11 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: Nightly Build
22
permissions:
3-
"contents": "write"
3+
contents: read
44

55
# Schedule this workflow to run at midnight every day
66
on:
@@ -10,6 +10,8 @@ on:
1010

1111
jobs:
1212
build:
13+
permissions:
14+
contents: write
1315
strategy:
1416
matrix:
1517
include:
@@ -25,31 +27,27 @@ jobs:
2527
os: windows-latest
2628
binary_extension: ".exe"
2729
runs-on: ${{ matrix.os }}
30+
timeout-minutes: 60
2831
steps:
2932
- name: Checkout repository
30-
uses: actions/checkout@v6
33+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
34+
with:
35+
persist-credentials: false
3136

3237
- name: Install Rust toolchain
33-
uses: dtolnay/rust-toolchain@stable
38+
uses: dtolnay/rust-toolchain@631a55b12751854ce901bb631d5902ceb48146f7 # stable
3439
with:
3540
toolchain: stable
3641
targets: ${{ matrix.target }}
3742

38-
- name: Restore cache
39-
id: cache
40-
uses: actions/cache@v5
41-
with:
42-
path: |
43-
~/.cargo/registry
44-
~/.cargo/git
45-
target
46-
key: ${{ matrix.os }}-${{ runner.arch }}-cargo-${{ hashFiles('**/Cargo.lock') }}
43+
- name: Cache Cargo
44+
uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2.9.1
4745

4846
- name: Build
4947
run: cargo build --target ${{ matrix.target }} --release --locked --bin boa
5048

5149
- name: Upload binaries to release
52-
uses: svenstaro/upload-release-action@v2
50+
uses: svenstaro/upload-release-action@29e53e917877a24fad85510ded594ab3c9ca12de # v2
5351
with:
5452
repo_token: ${{ secrets.GITHUB_TOKEN }}
5553
file: target/${{ matrix.target }}/release/boa${{ matrix.binary_extension }}
Lines changed: 78 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,78 @@
1+
name: PR Management
2+
3+
on:
4+
pull_request_target:
5+
types: [opened, reopened, synchronize, closed]
6+
7+
permissions:
8+
contents: read
9+
10+
jobs:
11+
manage_pr:
12+
runs-on: ubuntu-latest
13+
timeout-minutes: 10
14+
permissions:
15+
pull-requests: write
16+
issues: write
17+
steps:
18+
- name: Auto Add Label
19+
if: github.event.action == 'opened' || github.event.action == 'reopened' || github.event.action == 'synchronize'
20+
uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd # v8
21+
with:
22+
script: |
23+
const labels = await github.rest.issues.listLabelsOnIssue({
24+
owner: context.repo.owner,
25+
repo: context.repo.repo,
26+
issue_number: context.issue.number
27+
});
28+
29+
if (labels.data.every(label => label.name != "Waiting On Author")) {
30+
github.rest.issues.addLabels({
31+
issue_number: context.issue.number,
32+
owner: context.repo.owner,
33+
repo: context.repo.repo,
34+
labels: ['Waiting On Review']
35+
})
36+
}
37+
38+
39+
- name: Auto Remove Label
40+
if: github.event.action == 'closed'
41+
uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd # v8
42+
continue-on-error: true
43+
with:
44+
script: |
45+
try {
46+
await github.rest.issues.removeLabel({
47+
issue_number: context.issue.number,
48+
owner: context.repo.owner,
49+
repo: context.repo.repo,
50+
name: 'Waiting On Review'
51+
});
52+
} catch (error) {
53+
console.log('Label "Waiting On Review" not found or could not be removed.');
54+
}
55+
56+
- name: Auto Assign Milestone
57+
if: github.event.action == 'opened'
58+
uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd # v8
59+
with:
60+
script: |
61+
// Fetch open milestones and assign the closest one
62+
const { data: milestones } = await github.rest.issues.listMilestones({
63+
owner: context.repo.owner,
64+
repo: context.repo.repo,
65+
state: 'open',
66+
sort: 'due_on',
67+
direction: 'asc'
68+
});
69+
70+
if (milestones.length > 0) {
71+
const latestMilestone = milestones[0];
72+
await github.rest.issues.update({
73+
issue_number: context.issue.number,
74+
owner: context.repo.owner,
75+
repo: context.repo.repo,
76+
milestone: latestMilestone.number
77+
});
78+
}

0 commit comments

Comments
 (0)