From d4887daa3658b047324b3478bb5a8894a930acad Mon Sep 17 00:00:00 2001 From: lifeisfakenews <86294896+lifeisfakenews@users.noreply.github.com> Date: Mon, 13 May 2024 18:35:36 +0100 Subject: [PATCH] Add missing flags for the `astro check` command (#8237) Co-authored-by: Atharva Co-authored-by: Sarah Rainsberger --- .../docs/en/reference/cli-reference.mdx | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/src/content/docs/en/reference/cli-reference.mdx b/src/content/docs/en/reference/cli-reference.mdx index 43d1e07b55bd4..ae7f77e916c09 100644 --- a/src/content/docs/en/reference/cli-reference.mdx +++ b/src/content/docs/en/reference/cli-reference.mdx @@ -226,6 +226,30 @@ Use these flags to customize the behavior of the command. The command will watch for any changes in your project, and will report any errors. +#### `--root ` + +Specifies a different root directory to check. Uses the current working directory by default. + +#### `--tsconfig ` + +Specifies a `tsconfig.json` or `jsconfig.json` file to use manually. If not provided, Astro will attempt to find a config, or infer the project's config automatically. + +#### `--minimumFailingSeverity ` + +Specifies the minimum severity needed to exit with an error code. Defaults to `error`. + +For example, running `astro check --minimumFailingSeverity warning` will cause the command to exit with an error if any warnings are detected. + +#### `--minimumSeverity ` + +Specifies the minimum severity to output. Defaults to `hint`. + +For example, running `astro check --minimumSeverity warning` will show errors and warning, but not hints. + +#### `--preserveWatchOutput` + +Specifies not to clear the ouput between checks when in watch mode. + Read more about [type checking in Astro](/en/guides/typescript/#type-checking). ## `astro sync`