Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ensure CI is checking formatting #54

Merged
merged 4 commits into from
Jan 4, 2024
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
142 changes: 71 additions & 71 deletions docs/docs/using-pants/key-concepts/backends.mdx

Large diffs are not rendered by default.

10 changes: 5 additions & 5 deletions docs/docs/using-pants/key-concepts/goals.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,11 @@ Most goals require arguments to know what to work on.

You can use several argument types:

| Argument type | Semantics | Example |
| ------------------------------- | ------------------------------------------- | ----------------------------- |
| File path | Match the file | `pants test project/tests.py` |
| Directory path | Match everything in the directory | `pants test project/utils` |
| `::` globs | Match everything in the directory and below | `pants test project::` |
| Argument type | Semantics | Example |
| ------------------------------------------------- | ------------------------------------------- | ----------------------------- |
| File path | Match the file | `pants test project/tests.py` |
| Directory path | Match everything in the directory | `pants test project/utils` |
| `::` globs | Match everything in the directory and below | `pants test project::` |
| [Target addresses](./targets-and-build-files.mdx) | Match the target | `pants package project:tests` |

You can combine argument types, e.g. `pants fmt src/go:: src/py/app.py`.
Expand Down
10 changes: 3 additions & 7 deletions docs/reference/global-options.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import styles from "@site/src/components/reference/styles.module.css";

---


Options to control the overall behavior of Pants.

Backend: <span className="color--primary">pants.core</span>
Expand All @@ -17,7 +16,6 @@ Config section: <span className="color--primary">[GLOBAL]</span>

## Basic options


### `level`

<Option
Expand Down Expand Up @@ -213,7 +211,6 @@ Run goals continuously as file changes are detected.

## Advanced options


### `backend_packages`

<Option
Expand Down Expand Up @@ -299,6 +296,7 @@ Whether to show/hide logging done by 3rdparty Rust crates used by the Pants engi
Ignore logs and warnings matching these strings.

Normally, Pants will look for literal matches from the start of the log/warning message, but you can prefix the ignore with `$regex$` for Pants to instead treat your string as a regex pattern. For example:

```
ignore_warnings = [
"DEPRECATED: option 'config' in scope 'flake8' will be removed",
Expand Down Expand Up @@ -456,7 +454,7 @@ Verify that all config file values correspond to known options.
]`}
>

Option scopes to record in stats on run completion. Options may be selected by joining the scope and the option with a ^ character, i.e. to get option `pantsd` in the GLOBAL scope, you&#x27;d pass `GLOBAL^pantsd`. Add a &#x27;*&#x27; to the list to capture all known scopes.
Option scopes to record in stats on run completion. Options may be selected by joining the scope and the option with a ^ character, i.e. to get option `pantsd` in the GLOBAL scope, you&#x27;d pass `GLOBAL^pantsd`. Add a &#x27;\*&#x27; to the list to capture all known scopes.

</Option>

Expand Down Expand Up @@ -1303,7 +1301,6 @@ If you are using the `remote_environment` target mechanism, set this value as a

## Deprecated options


### `process_cleanup`

<Option
Expand Down Expand Up @@ -1334,5 +1331,4 @@ If specified, Pants will add a header in the format `authorization: Bearer <toke

</Option>


</span>
</span>
6 changes: 4 additions & 2 deletions docs/reference/goals/_category_.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,7 @@
"label": "Goals",
"link": {
"type": "generated-index",
"slug": "/reference/goals", "title": "Goals"
}}
"slug": "/reference/goals",
"title": "Goals"
}
}
4 changes: 1 addition & 3 deletions docs/reference/goals/check.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ Config section: <span className="color--primary">[check]</span>

## Basic options


### `only`

<Option
Expand All @@ -45,5 +44,4 @@ None

None


</span>
</span>
3 changes: 1 addition & 2 deletions docs/reference/goals/count-loc.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,4 @@ None

None


</span>
</span>
4 changes: 1 addition & 3 deletions docs/reference/goals/dependees.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ Config section: <span className="color--primary">[dependees]</span>

## Basic options


### `output_file`

<Option
Expand Down Expand Up @@ -77,5 +76,4 @@ None

None


</span>
</span>
4 changes: 1 addition & 3 deletions docs/reference/goals/dependencies.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ Config section: <span className="color--primary">[dependencies]</span>

## Basic options


### `output_file`

<Option
Expand Down Expand Up @@ -77,5 +76,4 @@ None

None


</span>
</span>
4 changes: 1 addition & 3 deletions docs/reference/goals/dependents.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ Config section: <span className="color--primary">[dependents]</span>

## Basic options


### `output_file`

<Option
Expand Down Expand Up @@ -77,5 +76,4 @@ None

None


</span>
</span>
6 changes: 2 additions & 4 deletions docs/reference/goals/experimental-bsp.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ Config section: <span className="color--primary">[experimental-bsp]</span>

## Basic options


### `groups_config_files`

<Option
Expand All @@ -34,6 +33,7 @@ A list of config files that define groups of Pants targets to expose to IDEs via
Pants generally uses fine-grained targets to define the components of a build (in many cases on a file-by-file basis). Many IDEs, however, favor coarse-grained targets that contain large numbers of source files. To accommodate this distinction, the Pants BSP server will compute a set of BSP build targets to use from the groups specified in the config files set for this option. Each group will become one or more BSP build targets.

Each config file is a TOML file with a `groups` dictionary with the following format for an entry:

```
# The dictionary key is used to identify the group. It must be unique.
[groups.ID1]:
Expand All @@ -57,7 +57,6 @@ Pants will merge the contents of the config files together. If the same ID is us

## Advanced options


### `server`

<Option
Expand Down Expand Up @@ -92,5 +91,4 @@ Note: The environment variables passed to the Pants BSP server will be those set

None


</span>
</span>
3 changes: 1 addition & 2 deletions docs/reference/goals/experimental-deploy.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,4 @@ None

None


</span>
</span>
4 changes: 1 addition & 3 deletions docs/reference/goals/experimental-explorer.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ Config section: <span className="color--primary">[experimental-explorer]</span>

## Basic options


### `address`

<Option
Expand Down Expand Up @@ -53,5 +52,4 @@ None

None


</span>
</span>
3 changes: 1 addition & 2 deletions docs/reference/goals/export-codegen.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,4 @@ None

None


</span>
</span>
12 changes: 6 additions & 6 deletions docs/reference/goals/export.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ Config section: <span className="color--primary">[export]</span>

## Basic options


### `resolve`

<Option
Expand All @@ -43,12 +42,15 @@ Export the specified resolve(s). The export format is backend-specific, e.g., Py
>

Export Python resolves using this format. Options are:
- `mutable_virtualenv`: Export a standalone mutable virtualenv that you can

- `mutable_virtualenv`: Export a standalone mutable virtualenv that you can

```
further modify.
```

- `symlinked_immutable_virtualenv`: Export a symlink into a cached Python virtualenv.
- `symlinked_immutable_virtualenv`: Export a symlink into a cached Python virtualenv.

```
This virtualenv will have no pip binary, and will be immutable. Any attempt to
modify it will corrupt the cache! It may, however, take significantly less time
Expand All @@ -59,7 +61,6 @@ to export than a standalone, mutable virtualenv.

## Advanced options


### `py_editable_in_resolve`

<Option
Expand All @@ -82,5 +83,4 @@ NOTE: If you are using legacy exports (not using the &#x27;--resolve&#x27; optio

None


</span>
</span>
4 changes: 1 addition & 3 deletions docs/reference/goals/filedeps.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ Config section: <span className="color--primary">[filedeps]</span>

## Basic options


### `output_file`

<Option
Expand Down Expand Up @@ -89,5 +88,4 @@ None

None


</span>
</span>
11 changes: 4 additions & 7 deletions docs/reference/goals/fix.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ Config section: <span className="color--primary">[fix]</span>

## Basic options


### `only`

<Option
Expand Down Expand Up @@ -53,7 +52,6 @@ FYI: when running `scie-pants-linux-x86_64 fix fmt ::`, there should be diminish

## Advanced options


### `batch_size`

<Option
Expand All @@ -66,9 +64,9 @@ The target number of files to be included in each fixer batch.

Fixer processes are batched for a few reasons:

1. to avoid OS argument length limits (in processes which don&#x27;t support argument files)
2. to support more stable cache keys than would be possible if all files were operated on in a single batch.
3. to allow for parallelism in fixer processes which don&#x27;t have internal parallelism, or -- if they do support internal parallelism -- to improve scheduling behavior when multiple processes are competing for cores and so internal parallelism cannot be used perfectly.
1. to avoid OS argument length limits (in processes which don&#x27;t support argument files)
2. to support more stable cache keys than would be possible if all files were operated on in a single batch.
3. to allow for parallelism in fixer processes which don&#x27;t have internal parallelism, or -- if they do support internal parallelism -- to improve scheduling behavior when multiple processes are competing for cores and so internal parallelism cannot be used perfectly.

In order to improve cache hit rates (see 2.), batches are created at stable boundaries, and so this value is only a &#x22;target&#x22; batch size (rather than an exact value).

Expand All @@ -78,5 +76,4 @@ In order to improve cache hit rates (see 2.), batches are created at stable boun

None


</span>
</span>
11 changes: 4 additions & 7 deletions docs/reference/goals/fmt.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ Config section: <span className="color--primary">[fmt]</span>

## Basic options


### `only`

<Option
Expand All @@ -39,7 +38,6 @@ You can repeat this option, e.g. `fmt --only=isort --only=shfmt` or `fmt --only=

## Advanced options


### `batch_size`

<Option
Expand All @@ -52,9 +50,9 @@ The target number of files to be included in each formatter batch.

Formatter processes are batched for a few reasons:

1. to avoid OS argument length limits (in processes which don&#x27;t support argument files)
2. to support more stable cache keys than would be possible if all files were operated on in a single batch.
3. to allow for parallelism in formatter processes which don&#x27;t have internal parallelism, or -- if they do support internal parallelism -- to improve scheduling behavior when multiple processes are competing for cores and so internal parallelism cannot be used perfectly.
1. to avoid OS argument length limits (in processes which don&#x27;t support argument files)
2. to support more stable cache keys than would be possible if all files were operated on in a single batch.
3. to allow for parallelism in formatter processes which don&#x27;t have internal parallelism, or -- if they do support internal parallelism -- to improve scheduling behavior when multiple processes are competing for cores and so internal parallelism cannot be used perfectly.

In order to improve cache hit rates (see 2.), batches are created at stable boundaries, and so this value is only a &#x22;target&#x22; batch size (rather than an exact value).

Expand All @@ -64,5 +62,4 @@ In order to improve cache hit rates (see 2.), batches are created at stable boun

None


</span>
</span>
5 changes: 1 addition & 4 deletions docs/reference/goals/generate-lockfiles.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ Config section: <span className="color--primary">[generate-lockfiles]</span>

## Basic options


### `resolve`

<Option
Expand Down Expand Up @@ -67,7 +66,6 @@ Include unchanged distributions in the diff summary output. Implies `diff=true`.

## Advanced options


### `custom_command`

<Option
Expand All @@ -84,5 +82,4 @@ If set, lockfile headers will say to run this command to regenerate the lockfile

None


</span>
</span>
3 changes: 1 addition & 2 deletions docs/reference/goals/generate-snapshots.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,4 @@ None

None


</span>
</span>
4 changes: 1 addition & 3 deletions docs/reference/goals/go-generate.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ None

## Advanced options


### `env_vars`

<Option
Expand All @@ -46,5 +45,4 @@ Environment variables to set when invoking generator programs. Entries are eithe

None


</span>
</span>
Loading