Skip to content

Commit f296cc7

Browse files
authored
Merge pull request #362 from github/merge-3.3-main
Merge 3.3 into main
2 parents 3acd718 + ceecb23 commit f296cc7

File tree

552 files changed

+102
-279
lines changed

Some content is hidden

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

552 files changed

+102
-279
lines changed

.devcontainer/Dockerfile

Lines changed: 0 additions & 15 deletions
This file was deleted.

.devcontainer/devcontainer.json

Lines changed: 0 additions & 39 deletions
This file was deleted.

.devcontainer/post_attach.sh

Lines changed: 0 additions & 37 deletions
This file was deleted.

.devcontainer/post_create.sh

Lines changed: 0 additions & 4 deletions
This file was deleted.

.github/actions/fetch-codeql/action.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,6 @@ runs:
99
LATEST=$(gh release list --repo https://github.com/github/codeql-cli-binaries | cut -f 1 | grep -v beta | sort --version-sort | tail -1)
1010
gh release download --repo https://github.com/github/codeql-cli-binaries --pattern codeql-linux64.zip "$LATEST"
1111
unzip -q codeql-linux64.zip
12+
echo "${{ github.workspace }}/codeql" >> $GITHUB_PATH
1213
env:
1314
GITHUB_TOKEN: ${{ github.token }}

.github/dependabot.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
11
version: 2
22
updates:
33
- package-ecosystem: "cargo"
4-
directory: "/node-types"
4+
directory: "ruby/node-types"
55
schedule:
66
interval: "daily"
77
- package-ecosystem: "cargo"
8-
directory: "/generator"
8+
directory: "ruby/generator"
99
schedule:
1010
interval: "daily"
1111
- package-ecosystem: "cargo"
12-
directory: "/extractor"
12+
directory: "ruby/extractor"
1313
schedule:
1414
interval: "daily"
1515
- package-ecosystem: "cargo"
16-
directory: "/autobuilder"
16+
directory: "ruby/autobuilder"
1717
schedule:
1818
interval: "daily"

.github/workflows/qhelp.yml renamed to .github/workflows/qhelp-pr-preview.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ on:
66
- main
77
- 'rc/*'
88
paths:
9-
- "**/*.qhelp"
9+
- "ruby/**/*.qhelp"
1010

1111
jobs:
1212
qhelp:
@@ -32,7 +32,7 @@ jobs:
3232
for path in ${{ steps.changes.outputs.qhelp_files }} ; do
3333
echo "<details> <summary>${path}</summary>"
3434
echo
35-
codeql/codeql generate query-help --format=markdown ${path}
35+
codeql generate query-help --format=markdown ${path}
3636
echo "</details>"
3737
done) | gh pr comment "${{ github.event.pull_request.number }}" -F -
3838
env:

.github/workflows/qltest.yml

Lines changed: 0 additions & 42 deletions
This file was deleted.

.github/workflows/build.yml renamed to .github/workflows/ruby-build.yml

Lines changed: 28 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,15 @@
1-
name: Build / Release
1+
name: "Ruby: Build"
22

33
on:
44
push:
5+
paths:
6+
- 'ruby/**'
57
branches:
68
- main
79
- 'rc/*'
810
pull_request:
11+
paths:
12+
- 'ruby/**'
913
branches:
1014
- main
1115
- 'rc/*'
@@ -18,6 +22,10 @@ on:
1822
env:
1923
CARGO_TERM_COLOR: always
2024

25+
defaults:
26+
run:
27+
working-directory: ruby
28+
2129
jobs:
2230
build:
2331
strategy:
@@ -39,7 +47,7 @@ jobs:
3947
path: |
4048
~/.cargo/registry
4149
~/.cargo/git
42-
target
50+
ruby/target
4351
key: ${{ runner.os }}-rust-cargo-${{ hashFiles('**/Cargo.lock') }}
4452
- name: Check formatting
4553
run: cargo fmt --all -- --check
@@ -56,20 +64,20 @@ jobs:
5664
if: ${{ matrix.os == 'ubuntu-latest' }}
5765
with:
5866
name: ruby.dbscheme
59-
path: ql/lib/ruby.dbscheme
67+
path: ruby/ql/lib/ruby.dbscheme
6068
- uses: actions/upload-artifact@v2
6169
if: ${{ matrix.os == 'ubuntu-latest' }}
6270
with:
6371
name: TreeSitter.qll
64-
path: ql/lib/codeql/ruby/ast/internal/TreeSitter.qll
72+
path: ruby/ql/lib/codeql/ruby/ast/internal/TreeSitter.qll
6573
- uses: actions/upload-artifact@v2
6674
with:
6775
name: extractor-${{ matrix.os }}
6876
path: |
69-
target/release/ruby-autobuilder
70-
target/release/ruby-autobuilder.exe
71-
target/release/ruby-extractor
72-
target/release/ruby-extractor.exe
77+
ruby/target/release/ruby-autobuilder
78+
ruby/target/release/ruby-autobuilder.exe
79+
ruby/target/release/ruby-extractor
80+
ruby/target/release/ruby-extractor.exe
7381
retention-days: 1
7482
compile-queries:
7583
runs-on: ubuntu-latest
@@ -106,7 +114,7 @@ jobs:
106114
with:
107115
name: codeql-ruby-queries
108116
path: |
109-
target/packs/*
117+
ruby/target/packs/*
110118
retention-days: 1
111119

112120
package:
@@ -117,19 +125,19 @@ jobs:
117125
- uses: actions/download-artifact@v2
118126
with:
119127
name: ruby.dbscheme
120-
path: ruby
128+
path: ruby/ruby
121129
- uses: actions/download-artifact@v2
122130
with:
123131
name: extractor-ubuntu-latest
124-
path: linux64
132+
path: ruby/linux64
125133
- uses: actions/download-artifact@v2
126134
with:
127135
name: extractor-windows-latest
128-
path: win64
136+
path: ruby/win64
129137
- uses: actions/download-artifact@v2
130138
with:
131139
name: extractor-macos-latest
132-
path: osx64
140+
path: ruby/osx64
133141
- run: |
134142
mkdir -p ruby
135143
cp -r codeql-extractor.yml tools ql/lib/ruby.dbscheme.stats ruby/
@@ -145,12 +153,12 @@ jobs:
145153
- uses: actions/upload-artifact@v2
146154
with:
147155
name: codeql-ruby-pack
148-
path: codeql-ruby.zip
156+
path: ruby/codeql-ruby.zip
149157
retention-days: 1
150158
- uses: actions/download-artifact@v2
151159
with:
152160
name: codeql-ruby-queries
153-
path: qlpacks
161+
path: ruby/qlpacks
154162
- run: |
155163
echo '{
156164
"provide": [
@@ -162,18 +170,13 @@ jobs:
162170
- uses: actions/upload-artifact@v2
163171
with:
164172
name: codeql-ruby-bundle
165-
path: codeql-ruby-bundle.zip
173+
path: ruby/codeql-ruby-bundle.zip
166174
retention-days: 1
167-
- if: ${{ github.event.inputs.tag }}
168-
run: |
169-
gh release create --prerelease \
170-
--title "CodeQL Ruby (${{ github.event.inputs.tag }})" \
171-
--target "${{ github.sha }}" \
172-
"${{ github.event.inputs.tag }}" \
173-
codeql-ruby-bundle.zip
174-
env:
175-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
175+
176176
test:
177+
defaults:
178+
run:
179+
working-directory: ${{ github.workspace }}
177180
strategy:
178181
fail-fast: false
179182
matrix:

.github/workflows/dataset_measure.yml renamed to .github/workflows/ruby-dataset-measure.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
1-
name: Collect database stats
1+
name: "Ruby: Collect database stats"
22

33
on:
44
push:
55
branches:
66
- main
77
- 'rc/*'
88
paths:
9-
- ql/lib/ruby.dbscheme
9+
- ruby/ql/lib/ruby.dbscheme
1010
pull_request:
1111
branches:
1212
- main
1313
- 'rc/*'
1414
paths:
15-
- ql/lib/ruby.dbscheme
15+
- ruby/ql/lib/ruby.dbscheme
1616
workflow_dispatch:
1717

1818
jobs:
@@ -29,7 +29,7 @@ jobs:
2929

3030
- uses: ./.github/actions/fetch-codeql
3131

32-
- uses: ./.github/actions/create-extractor-pack
32+
- uses: ./ruby/actions/create-extractor-pack
3333

3434
- name: Checkout ${{ matrix.repo }}
3535
uses: actions/checkout@v2
@@ -38,15 +38,15 @@ jobs:
3838
path: ${{ github.workspace }}/repo
3939
- name: Create database
4040
run: |
41-
codeql/codeql database create \
42-
--search-path "${{ github.workspace }}" \
41+
codeql database create \
42+
--search-path "${{ github.workspace }}/ruby" \
4343
--threads 4 \
4444
--language ruby --source-root "${{ github.workspace }}/repo" \
4545
"${{ runner.temp }}/database"
4646
- name: Measure database
4747
run: |
4848
mkdir -p "stats/${{ matrix.repo }}"
49-
codeql/codeql dataset measure --threads 4 --output "stats/${{ matrix.repo }}/stats.xml" "${{ runner.temp }}/database/db-ruby"
49+
codeql dataset measure --threads 4 --output "stats/${{ matrix.repo }}/stats.xml" "${{ runner.temp }}/database/db-ruby"
5050
- uses: actions/upload-artifact@v2
5151
with:
5252
name: measurements
@@ -64,8 +64,8 @@ jobs:
6464
path: stats
6565
- run: |
6666
python -m pip install --user lxml
67-
find stats -name 'stats.xml' | sort | xargs python scripts/merge_stats.py --output ql/lib/ruby.dbscheme.stats --normalise ruby_tokeninfo
67+
find stats -name 'stats.xml' | sort | xargs python ruby/scripts/merge_stats.py --output ruby/ql/lib/ruby.dbscheme.stats --normalise ruby_tokeninfo
6868
- uses: actions/upload-artifact@v2
6969
with:
7070
name: ruby.dbscheme.stats
71-
path: ql/lib/ruby.dbscheme.stats
71+
path: ruby/ql/lib/ruby.dbscheme.stats

0 commit comments

Comments
 (0)