Add View AST Command to text editor where appropriate

Also, hide the `CodeQL: Run Queries` command inside of zip folders
since we do not allow queries to be in archives. I wish we could be more
specific about when to show that command, eg- only *.ql files and
directories, but I couldn't find a way to restrict a command to only
appear on directories.
This commit is contained in:
Andrew Eisenberg
2020-12-17 10:53:32 -08:00
parent e6eb914783
commit 5824e3607a
2 changed files with 7 additions and 1 deletions

View File

@@ -12,6 +12,7 @@
- Avoid error dialogs when QL test discovery or database cleanup encounters a missing directory. [#706](https://github.com/github/vscode-codeql/pull/706) - Avoid error dialogs when QL test discovery or database cleanup encounters a missing directory. [#706](https://github.com/github/vscode-codeql/pull/706)
- Add descriptive text and a link in the results view. [#711](https://github.com/github/vscode-codeql/pull/711) - Add descriptive text and a link in the results view. [#711](https://github.com/github/vscode-codeql/pull/711)
- Fix the _Set Label_ command in the query history view. [#710](https://github.com/github/vscode-codeql/pull/710) - Fix the _Set Label_ command in the query history view. [#710](https://github.com/github/vscode-codeql/pull/710)
- Add the _CodeQL: View AST_ directly to text editors of files in database archives. [#712](https://github.com/github/vscode-codeql/pull/712)
## 1.3.7 - 24 November 2020 ## 1.3.7 - 24 November 2020

View File

@@ -526,7 +526,8 @@
}, },
{ {
"command": "codeQL.runQueries", "command": "codeQL.runQueries",
"group": "9_qlCommands" "group": "9_qlCommands",
"when": "resourceScheme != codeql-zip-archive"
} }
], ],
"commandPalette": [ "commandPalette": [
@@ -656,6 +657,10 @@
"command": "codeQL.runQuery", "command": "codeQL.runQuery",
"when": "editorLangId == ql && resourceExtname == .ql" "when": "editorLangId == ql && resourceExtname == .ql"
}, },
{
"command": "codeQL.viewAst",
"when": "resourceScheme == codeql-zip-archive"
},
{ {
"command": "codeQL.quickEval", "command": "codeQL.quickEval",
"when": "editorLangId == ql" "when": "editorLangId == ql"