When a user goes through the Code Tour, we select a dummy `csv` database for them to get them up and running. Once they complete the code tour and would like to continue writing queries, they will need to add their own database. After they do that, we check the language of their new database and generate a skeleton QL pack for them so that they don't need to create these files by hand. See [1] for details. This skeleton pack folder will be called `codeql-custom-queries-<language>` and it comes with its own example query: `example.ql`. When we try to run this example query, the query gets confused about which `dbscheme` to pick, as it sees a `qlpack.yml` file in the new skeleton pack folder, as well as one in the existing `tutorial-lib` folder. So we'll need to get rid of the `tutorial-lib` folder in order to make room for new queries to be run once the tour is complete. This commit introduces a `handleTourDependencies` step which will trigger a `codeql pack install` command in order to install real library dependencies for `tutorial-queries`, since we no longer have the dummy library in `tutorial-lib`.
CodeQL for Visual Studio Code
This project is an extension for Visual Studio Code that adds rich language support for CodeQL. It's used to find problems in code bases using CodeQL. It's written primarily in TypeScript.
The extension is released. You can download it from the Visual Studio Marketplace.
To see what has changed in the last few versions of the extension, see the Changelog.
Features
- Enables you to use CodeQL to query databases and discover problems in codebases.
- Shows the flow of data through the results of path queries, which is essential for triaging security results.
- Provides an easy way to run queries from the large, open source repository of CodeQL security queries.
- Adds IntelliSense to support you writing and editing your own CodeQL query and library files.
Project goals and scope
This project will track new feature development in CodeQL and, whenever appropriate, bring that functionality to the Visual Studio Code experience.
Dependencies
This extension depends on the following two extensions for required functionality. They will be installed automatically when you install VS Code CodeQL.
Contributing
This project welcomes contributions. See CONTRIBUTING.md for details on how to build, install, and contribute.
License
The CodeQL extension for Visual Studio Code is licensed under the MIT License. The version of CodeQL used by the CodeQL extension is subject to the CodeQL Research Terms & Conditions.
When using the GitHub logos, be sure to follow the GitHub logo guidelines.