Skip to content

Commit 2cacba5

Browse files
authored
Apply suggestions to fix typos and formatting glitches
1 parent 634e883 commit 2cacba5

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

docs/codeql/codeql-cli/about-codeql-workspaces.rst

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ A CodeQL workspace is defined by a ``codeql-workspace.yml`` yaml file. This file
1919
* The ``provide`` block contains a list of glob patterns that define the CodeQL packs that are available in the workspace.
2020
* The ``ignore`` block contains a list of glob patterns that define CodeQL packs that are not available in the workspace.
2121

22-
Each entry in the ``provide`` or ``ignore`` section must map to the location of a ``qlpack.yml`` file. All glob patterns are defined relative to the directory that contains the workspace file. For a list of patterns accepted in this file, see" `@actions/glob <https://github.com/actions/toolkit/tree/main/packages/glob#patterns>`__ .
22+
Each entry in the ``provide`` or ``ignore`` section must map to the location of a ``qlpack.yml`` file. All glob patterns are defined relative to the directory that contains the workspace file. For a list of patterns accepted in this file, see "`@actions/glob <https://github.com/actions/toolkit/tree/main/packages/glob#patterns>`__ ."
2323

2424
For example, the following ``codeql-workspace.yml`` file defines a workspace that contains all the CodeQL packs recursively found in the ``codeql-packs`` directory, except for the packs in the ``experimental`` directory:
2525

@@ -30,13 +30,13 @@ For example, the following ``codeql-workspace.yml`` file defines a workspace tha
3030
ignore:
3131
- "*/codeql-packs/**/experimental/**/qlpack.yml"
3232
33-
To verify that your ``codeql-workspace.yml`` file includes the CodeQL packs that you expect, run ``codeql pack ls`` command in the same directory as your workspace. The result of the command is a list of all CodeQL packs in the workspace.
33+
To verify that your ``codeql-workspace.yml`` file includes the CodeQL packs that you expect, run the ``codeql pack ls`` command in the same directory as your workspace. The result of the command is a list of all CodeQL packs in the workspace.
3434

3535

3636
CodeQL workspaces and query resolution
3737
--------------------------------------
3838

39-
All CodeQL packs in a workspace are available as source dependencies for each other when you run any CodeQL command that resolves queries or packs. For example, when you run ``codeql pack install`` in a pack directory in a workspace, any dependency that can be found in the workspace will be instead of downloading that dependency to the package cache and adding it to the ``codeql-pack.lock.yml`` file. For more information, see `:ref:Adding and Installing Dependencies <adding-and-installing-dependencies>`__.
39+
All CodeQL packs in a workspace are available as source dependencies for each other when you run any CodeQL command that resolves queries or packs. For example, when you run ``codeql pack install`` in a pack directory in a workspace, any dependency that can be found in the workspace will be used instead of downloading that dependency to the package cache and adding it to the ``codeql-pack.lock.yml`` file. For more information, see ":ref:`Adding and Installing Dependencies <adding-and-installing-dependencies>`."
4040

4141
Similarly, when you publish a CodeQL query pack to the GitHub container registry using ``codeql pack publish`` the command will always use the dependencies from the workspace instead of using dependencies found in the local package cache.
4242

@@ -50,7 +50,7 @@ This ensures that any local changes you make to a query library in a dependency
5050

5151
This is particularly useful in the following situations:
5252

53-
- One of the dependencies of the query pack you are running is not yet published. Resolving from source is the only way to refernce that pack.
53+
- One of the dependencies of the query pack you are running is not yet published. Resolving from source is the only way to reference that pack.
5454
- You are making changes to multiple packs at the same time and want to test them together. Resolving from source ensures that you are using the version of the pack with your changes in it.
5555

5656
Example
@@ -81,7 +81,7 @@ And the following CodeQL query pack ``qlpack.yml`` file in the workspace:
8181
my-company/my-library: "*"
8282
codeql/cpp-all: ~0.2.0
8383
84-
Notice that the ``dependencies`` block for the CodeQL query pack,``my-company/my-queries``, specifies ``"*"`` as the version of the library pack. Since the library pack is already defined as a source dependency in ``codeql-workspace.yml``, the library pack's content is always resolved from inside the workspace. Any version constraint you define will be ignored in this case. We recommend that you use ``"*"`` for source dependencies to make it clear that the version is inherited from the workspace.
84+
Notice that the ``dependencies`` block for the CodeQL query pack, ``my-company/my-queries``, specifies ``"*"`` as the version of the library pack. Since the library pack is already defined as a source dependency in ``codeql-workspace.yml``, the library pack's content is always resolved from inside the workspace. Any version constraint you define will be ignored in this case. We recommend that you use ``"*"`` for source dependencies to make it clear that the version is inherited from the workspace.
8585

8686
When you execute ``codeql pack install`` from the query pack directory, an appropriate version of ``codeql/cpp-all`` is downloaded to the local package cache. Also, a ``codeql-pack.lock.yml`` file is created that contains the resolved version of ``codeql/cpp-all``. The lock file won't contain an entry for ``my-company/my-library`` since it is resolved from source dependencies. The ``codeql-pack.lock.yml`` file will look something like this:
8787

@@ -91,4 +91,4 @@ When you execute ``codeql pack install`` from the query pack directory, an appro
9191
codeql/cpp-all:
9292
version: 0.2.2
9393
94-
When you execute``codeql pack publish`` from the query pack directory, the ``codeql/cpp-all`` dependency from the package cache and the ``my-company/my-library`` from the workspace are bundled with ``my-company/my-queries`` and published to the GitHub container registry.
94+
When you execute ``codeql pack publish`` from the query pack directory, the ``codeql/cpp-all`` dependency from the package cache and the ``my-company/my-library`` from the workspace are bundled with ``my-company/my-queries`` and published to the GitHub container registry.

0 commit comments

Comments
 (0)