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
16 changes: 12 additions & 4 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,15 @@ jobs:
node-version: '10.18.1'

- name: Install dependencies
run: node common/scripts/install-run-rush.js install
run: |
cd extensions/ql-vscode
npm install
shell: bash

- name: Build
run: node common/scripts/install-run-rush.js build
run: |
cd extensions/ql-vscode
npm run build
shell: bash

- name: Prepare artifacts
Expand Down Expand Up @@ -57,11 +61,15 @@ jobs:

# We have to build the dependencies in `lib` before running any tests.
- name: Install dependencies
run: node common/scripts/install-run-rush.js install
run: |
cd extensions/ql-vscode
npm install
shell: bash

- name: Build
run: node common/scripts/install-run-rush.js build
run: |
cd extensions/ql-vscode
npm run build
shell: bash

- name: Lint
Expand Down
8 changes: 6 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,15 @@ jobs:
node-version: '10.18.1'

- name: Install dependencies
run: node common/scripts/install-run-rush.js install
run: |
cd extensions/ql-vscode
npm install
shell: bash

- name: Build
run: node common/scripts/install-run-rush.js build --release
run: |
cd extensions/ql-vscode
npm run build -- --release
shell: bash

- name: Prepare artifacts
Expand Down
16 changes: 6 additions & 10 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,12 @@
"request": "launch",
"runtimeExecutable": "${execPath}",
"args": [
"--extensionDevelopmentPath=${workspaceRoot}/dist/vscode-codeql"
"--extensionDevelopmentPath=${workspaceRoot}/extensions/ql-vscode"
],
"stopOnEntry": false,
"sourceMaps": true,
"outFiles": [
"${workspaceRoot}/dist/vscode-codeql/out/**/*.js",
"${workspaceRoot}/dist/vscode-codeql/node_modules/semmle-bqrs/out/**/*.js",
"${workspaceRoot}/dist/vscode-codeql/node_modules/semmle-io/out/**/*.js",
"${workspaceRoot}/dist/vscode-codeql/node_modules/semmle-io-node/out/**/*.js",
"${workspaceRoot}/dist/vscode-codeql/node_modules/@github/codeql-vscode-utils/out/**/*.js"
"${workspaceRoot}/extensions/ql-vscode/out/**/*.js",
],
"preLaunchTask": "Build"
},
Expand Down Expand Up @@ -54,13 +50,13 @@
"request": "launch",
"runtimeExecutable": "${execPath}",
"args": [
"--extensionDevelopmentPath=${workspaceRoot}/dist/vscode-codeql",
"${workspaceRoot}/extensions/ql-vscode/out/**/*.js",
"--extensionTestsPath=${workspaceRoot}/extensions/ql-vscode/out/vscode-tests/no-workspace/index"
],
"stopOnEntry": false,
"sourceMaps": true,
"outFiles": [
"${workspaceRoot}/dist/vscode-codeql/out/**/*.js",
"${workspaceRoot}/extensions/ql-vscode/out/**/*.js",
"${workspaceRoot}/extensions/ql-vscode/out/vscode-tests/**/*.js"
],
"preLaunchTask": "Build"
Expand All @@ -71,14 +67,14 @@
"request": "launch",
"runtimeExecutable": "${execPath}",
"args": [
"--extensionDevelopmentPath=${workspaceRoot}/dist/vscode-codeql",
"${workspaceRoot}/extensions/ql-vscode/out/**/*.js",
"--extensionTestsPath=${workspaceRoot}/extensions/ql-vscode/out/vscode-tests/minimal-workspace/index",
"${workspaceRoot}/extensions/ql-vscode/test/data"
],
"stopOnEntry": false,
"sourceMaps": true,
"outFiles": [
"${workspaceRoot}/dist/vscode-codeql/out/**/*.js",
"${workspaceRoot}/extensions/ql-vscode/out/**/*.js",
"${workspaceRoot}/extensions/ql-vscode/out/vscode-tests/**/*.js"
],
"preLaunchTask": "Build"
Expand Down
66 changes: 9 additions & 57 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,10 @@
"kind": "build",
"isDefault": true
},
"command": "node common/scripts/install-run-rush.js build --verbose",
"command": "npx gulp buildWithoutPackage --verbose",
Copy link
Copy Markdown
Contributor

@aeisenberg aeisenberg Jul 21, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I dont think we need npx here. We can assume users have already run npm run build -- buildWithoutPackage --verbose before running in vs code. So, just do the same, but remove npx. You may need to add a full path here, so ${workspaceRoot}/extensions/ql-vscode/node_modules/.bin/gulp.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I sort of like npx as a terse idiom here, but I don't mind being more explicit if you think it's better to avoid the magic of npx auto-downloading packages. I'm pretty sure we already need to be in the correct cwd to have gulp work, so a path relative to extensions/ql-vscode should work.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My concern with npx is with versioning. I've had situations before where people ran into different behaviour because npx had installed different versions. If we are running from the node_modules directory, this won't happen.

"options": {
"cwd": "extensions/ql-vscode/"
},
"presentation": {
"echo": true,
"reveal": "always",
Expand All @@ -33,64 +36,13 @@
"$ts-webpack"
]
},
{
"label": "Rebuild",
"type": "shell",
"group": "build",
"command": "node common/scripts/install-run-rush.js rebuild --verbose",
"presentation": {
"echo": true,
"reveal": "always",
"focus": false,
"panel": "shared",
"showReuseMessage": true,
"clear": true
},
"problemMatcher": [
{
"owner": "typescript",
"fileLocation": "absolute",
"pattern": {
"regexp": "^\\[gulp-typescript\\] ([^(]+)\\((\\d+|\\d+,\\d+|\\d+,\\d+,\\d+,\\d+)\\): error TS\\d+: (.*)$",
"file": 1,
"location": 2,
"message": 3
}
}
]
},
{
"label": "Update",
"type": "shell",
"command": "node common/scripts/install-run-rush.js update",
"presentation": {
"echo": true,
"reveal": "always",
"focus": false,
"panel": "shared",
"showReuseMessage": true,
"clear": true
},
"problemMatcher": []
},
{
"label": "Update (full)",
"type": "shell",
"command": "node common/scripts/install-run-rush.js update --full",
"presentation": {
"echo": true,
"reveal": "always",
"focus": false,
"panel": "shared",
"showReuseMessage": true,
"clear": true
},
"problemMatcher": []
},
{
"label": "Format",
"type": "shell",
"command": "node common/scripts/install-run-rush.js format",
"command": "npm run format",
"options": {
"cwd": "extensions/ql-vscode/"
},
"presentation": {
"echo": true,
"reveal": "always",
Expand All @@ -111,4 +63,4 @@
"group": "build"
}
]
}
}
28 changes: 0 additions & 28 deletions common/config/LICENSE

This file was deleted.

12 changes: 0 additions & 12 deletions common/config/rush/.npmrc

This file was deleted.

32 changes: 0 additions & 32 deletions common/config/rush/command-line.json

This file was deleted.

43 changes: 0 additions & 43 deletions common/config/rush/common-versions.json

This file was deleted.

Loading