Skip to content

Commit 18760b4

Browse files
authored
Merge pull request #10923 from dscho/patch-1
Download GitHub database: fix `gh` invocation
2 parents 7c5cdd9 + 3bff6c4 commit 18760b4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

docs/codeql/reusables/download-github-database.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@ GitHub stores CodeQL databases for over 200,000 repos on GitHub.com, which you c
33
You can check if a repository has any CodeQL databases available for download using the ``/repos/<owner>/<repo>/code-scanning/codeql/databases`` endpoint.
44
For example, to check for CodeQL databases using the `GitHub CLI <https://cli.github.com/manual/gh_api>`__ you would run::
55

6-
gh api /repos/<owner>/<repo>/code-scanning/codeql/databases
6+
gh api repos/<owner>/<repo>/code-scanning/codeql/databases
77

88
This command returns information about any CodeQL databases that are available for a repository, including the language the database represents, and when the database was last updated. If no CodeQL databases are available, the response is empty.
99

1010
When you have confirmed that a CodeQL database exists for the language you are interested in, you can download it using the following command::
1111

12-
gh api /repos/<owner>/<repo>/code-scanning/codeql/databases/<language> -H 'Accept: application/zip' > path/to/local/database.zip
12+
gh api repos/<owner>/<repo>/code-scanning/codeql/databases/<language> -H 'Accept: application/zip' > path/to/local/database.zip
1313

1414
For more information, see the documentation for the `Get CodeQL database <https://docs.github.com/en/rest/code-scanning#get-a-codeql-database-for-a-repository>`__ endpoint in the GitHub REST API documentation.

0 commit comments

Comments
 (0)