Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
95cef22
Add support for basic query overriding in action file itself
sampart Jul 27, 2020
2da4570
Allow multiple overriding queries, comma-separated
sampart Jul 27, 2020
f03827d
Add new input to the init action configuration
sampart Jul 27, 2020
7b0f432
Add missing JavaScript
sampart Jul 30, 2020
ca2b74f
Make test name more descriptive
sampart Jul 30, 2020
f57bf21
Tidy up test
sampart Jul 31, 2020
d998a87
Fix typo
sampart Jul 31, 2020
443d18a
Improve variable name
sampart Jul 31, 2020
517d9fa
Improve description of queries property
sampart Aug 17, 2020
407ef0a
Break out tracer-config.ts
robertbrignull Aug 24, 2020
a6e6d4b
move dependencies needed to build CLI to separate package.json
robertbrignull Aug 24, 2020
3c5b7fb
update node_modules
robertbrignull Aug 24, 2020
88d9e95
add minimal instructions for building CLI
robertbrignull Aug 24, 2020
c6f0297
Prevent queries in workflow overriding default queries
sampart Aug 24, 2020
9e342a9
rename the action entrypoint files
robertbrignull Aug 24, 2020
4bc0c2b
clean the lib dir before building
robertbrignull Aug 24, 2020
9c015b7
cleanup lib
robertbrignull Aug 24, 2020
7f19f91
Refactor common code to function and add missing test
sampart Aug 24, 2020
129713f
Handle errors in workflow queries correctly
sampart Aug 24, 2020
45b9e96
support checkout of multiple refs for a single repository
esbena Aug 7, 2020
eecc25f
build typescript
esbena Aug 25, 2020
bdfd482
Merge branch 'main' into query-overriding
sampart Aug 25, 2020
82fb31e
make tests clearer
robertbrignull Aug 25, 2020
570a0d7
Merge pull request #161 from github/lib_clean
robertbrignull Aug 25, 2020
85c7ad0
Merge branch 'main' into rename_entrypoints
robertbrignull Aug 25, 2020
05f6207
Merge branch 'main' into support-multiple-checkouts
esbena Aug 25, 2020
e05e9e6
Merge pull request #160 from github/rename_entrypoints
robertbrignull Aug 25, 2020
8efabe9
Merge branch 'main' into tracer-config
robertbrignull Aug 25, 2020
c562bfb
Merge branch 'main' into support-multiple-checkouts
esbena Aug 25, 2020
0bb8872
remove build-cli from top-level package.json
robertbrignull Aug 25, 2020
d6daa45
update test workflow
robertbrignull Aug 25, 2020
ab457be
Merge pull request #139 from github/support-multiple-checkouts
esbena Aug 25, 2020
c3c86d8
Merge remote-tracking branch 'origin/main' into vercel/pkg
robertbrignull Aug 25, 2020
1fb8d3b
fix test workflow again
robertbrignull Aug 25, 2020
ab4e721
Don't refer to config file in contexts where it's not relevant
sampart Aug 25, 2020
e997bdf
Merge branch 'main' into query-overriding
sampart Aug 25, 2020
abddb8b
Merge pull request #127 from github/query-overriding
sampart Aug 25, 2020
2df51e0
Merge branch 'main' into tracer-config
robertbrignull Aug 25, 2020
c039c3b
Merge pull request #158 from github/tracer-config
robertbrignull Aug 25, 2020
80a22f4
Merge branch 'main' into vercel/pkg
robertbrignull Aug 25, 2020
fe75660
Merge pull request #152 from github/vercel/pkg
robertbrignull Aug 25, 2020
09677da
rename CLI to runner
robertbrignull Aug 24, 2020
aac5eb2
Merge pull request #159 from github/rename_cli
robertbrignull Aug 26, 2020
7e20774
Update defaults.json
marcogario Aug 26, 2020
b1aa99c
Merge branch 'main' into codeql_bundle_20200826
marcogario Aug 26, 2020
8229390
Merge pull request #163 from github/codeql_bundle_20200826
marcogario Aug 27, 2020
da1c00f
Run `npm test` on all operating systems
robertbrignull Aug 28, 2020
b1d719e
fix tests on non-linux
robertbrignull Aug 28, 2020
5bd2832
Merge pull request #164 from github/npm_test_os
robertbrignull Aug 28, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
18 changes: 0 additions & 18 deletions .github/workflows/cli.yml

This file was deleted.

9 changes: 7 additions & 2 deletions .github/workflows/pr-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ jobs:
>&2 echo "Failed: Repo should be clean before testing!"
exit 1
fi
# Wipe the lib directory incase there are extra unnecessary files in there
rm -rf lib
# Generate the JavaScript files
npm run-script build
# Check that repo is still clean
Expand Down Expand Up @@ -63,9 +65,12 @@ jobs:
echo "Success: node_modules are up to date"

npm-test:
runs-on: ubuntu-latest
strategy:
matrix:
os: [ubuntu-latest,macos-latest]
runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v1
- name: npm run-script test
run: npm run-script test
run: npm run-script test
26 changes: 26 additions & 0 deletions .github/workflows/runner.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: "CodeQL runner"

on: [push, pull_request]

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- name: Build runner
run: |
cd runner
npm install
npm run build-runner

- name: Upload with runner
run: |
runner/dist/codeql-runner-linux upload \
--sarif-file src/testdata/empty-sarif.sarif \
--repository $GITHUB_REPOSITORY \
--commit $GITHUB_SHA \
--ref $GITHUB_REF \
--github-url $GITHUB_API_URL \
--github-auth ${{ github.token }}
4 changes: 2 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
/cli/

/runner/dist/
/runner/node_modules/
4 changes: 4 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,10 @@ Running locally will generate the CodeQL database and run all the queries, but i

As well as the unit tests (see _Common tasks_ above), there are integration tests, defined in `.github/workflows/integration-testing.yml`. These are run by a CI check. Depending on the change you’re making, you may want to add a test to this file or extend an existing one.

### Building the CodeQL runner

Navigate to the `runner` directory and run `npm install` to install dependencies needed only for compiling the CodeQL runner. Run `npm run build-runner` to output files to the `runner/dist` directory.

## Submitting a pull request

1. [Fork][fork] and clone the repository
Expand Down
2 changes: 1 addition & 1 deletion analyze/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,4 @@ inputs:
default: ${{ toJson(matrix) }}
runs:
using: 'node12'
main: '../lib/finalize-db.js'
main: '../lib/analyze-action.js'
2 changes: 1 addition & 1 deletion autobuild/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ inputs:
default: ${{ toJson(matrix) }}
runs:
using: 'node12'
main: '../lib/autobuild.js'
main: '../lib/autobuild-action.js'
5 changes: 4 additions & 1 deletion init/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ inputs:
config-file:
description: Path of the config file to use
required: false
queries:
description: Comma-separated list of additional queries to run. By default, this overrides the same setting in a configuration file
required: false
runs:
using: 'node12'
main: '../lib/setup-tracer.js'
main: '../lib/init-action.js'
26 changes: 13 additions & 13 deletions lib/finalize-db.js → lib/analyze-action.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions lib/analyze-action.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion lib/autobuild.js → lib/autobuild-action.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions lib/autobuild-action.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion lib/autobuild.js.map

This file was deleted.

1 change: 0 additions & 1 deletion lib/cli.js.map

This file was deleted.

4 changes: 1 addition & 3 deletions lib/codeql.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading