Skip to content

Commit

Permalink
Merge pull request #152 from github/vercel/pkg
Browse files Browse the repository at this point in the history
Add vercel/pkg to create standalone CLI
  • Loading branch information
robertbrignull authored Aug 25, 2020
2 parents c039c3b + 80a22f4 commit fe75660
Show file tree
Hide file tree
Showing 3,351 changed files with 4,750 additions and 444,081 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
16 changes: 12 additions & 4 deletions .github/workflows/cli.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,18 @@ jobs:
steps:
- uses: actions/checkout@v2

# Build the CLI
- name: Build CLI
run: npm run build-cli
run: |
cd packaging
npm install
npm run build-cli
# Upload an empty SARIF file
- name: Upload with CLI
run: node cli/code-scanning-cli.js 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 }}
run: |
packaging/dist/code-scanning-cli-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/

/packaging/dist/
/packaging/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 CLI

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

## Submitting a pull request

1. [Fork][fork] and clone the repository
Expand Down
1 change: 0 additions & 1 deletion node_modules/.bin/atob

This file was deleted.

1 change: 0 additions & 1 deletion node_modules/.bin/errno

This file was deleted.

1 change: 0 additions & 1 deletion node_modules/.bin/json5

This file was deleted.

1 change: 0 additions & 1 deletion node_modules/.bin/miller-rabin

This file was deleted.

1 change: 0 additions & 1 deletion node_modules/.bin/sha.js

This file was deleted.

1 change: 0 additions & 1 deletion node_modules/.bin/terser

This file was deleted.

1 change: 0 additions & 1 deletion node_modules/.bin/webpack

This file was deleted.

1 change: 0 additions & 1 deletion node_modules/.bin/webpack-cli

This file was deleted.

21 changes: 0 additions & 21 deletions node_modules/@webassemblyjs/ast/LICENSE

This file was deleted.

167 changes: 0 additions & 167 deletions node_modules/@webassemblyjs/ast/README.md

This file was deleted.

10 changes: 0 additions & 10 deletions node_modules/@webassemblyjs/ast/esm/clone.js

This file was deleted.

Loading

0 comments on commit fe75660

Please sign in to comment.