format_fix -> format; rename svelte-check for consistency
This commit is contained in:
parent
bd6fb9b234
commit
5bb3d7c114
@ -60,14 +60,20 @@ bazel test //...
|
||||
|
||||
## Fixing formatting
|
||||
|
||||
If the format tests fail, most can be fixed by running format_fix
|
||||
in the relevant folder:
|
||||
If the format tests fail, most can be fixed by running `format`
|
||||
in the relevant package:
|
||||
|
||||
```
|
||||
bazel run //rslib:format_fix
|
||||
bazel run //pylib:format_fix
|
||||
bazel run //pylib/rsbridge:format_fix
|
||||
bazel run //qt:format_fix
|
||||
bazel run //rslib:format
|
||||
bazel run //pylib:format
|
||||
bazel run //pylib/rsbridge:format
|
||||
bazel run //qt:format
|
||||
```
|
||||
|
||||
If you're in one of those folders, you can use the short form:
|
||||
|
||||
```
|
||||
bazel run format
|
||||
```
|
||||
|
||||
Currently the typescript code needs to be formatted differently:
|
||||
|
@ -47,7 +47,7 @@ py_test(
|
||||
)
|
||||
|
||||
py_test(
|
||||
name = "format",
|
||||
name = "format_check",
|
||||
srcs = [
|
||||
"//pylib/tools:py_source_files",
|
||||
"//pylib/anki:py_source_files",
|
||||
@ -66,7 +66,7 @@ py_test(
|
||||
)
|
||||
|
||||
py_binary(
|
||||
name = "format_fix",
|
||||
name = "format",
|
||||
srcs = [
|
||||
"tests/run_format.py",
|
||||
],
|
||||
|
@ -33,14 +33,14 @@ rust_library(
|
||||
)
|
||||
|
||||
rustfmt_test(
|
||||
name = "format",
|
||||
name = "format_check",
|
||||
srcs = glob([
|
||||
"*.rs",
|
||||
]),
|
||||
)
|
||||
|
||||
rustfmt_fix(
|
||||
name = "format_fix",
|
||||
name = "format",
|
||||
srcs = glob([
|
||||
"*.rs",
|
||||
]),
|
||||
|
@ -82,7 +82,7 @@ py_test(
|
||||
)
|
||||
|
||||
py_test(
|
||||
name = "format",
|
||||
name = "format_check",
|
||||
srcs = glob([
|
||||
"**/*.py",
|
||||
]),
|
||||
@ -99,7 +99,7 @@ py_test(
|
||||
)
|
||||
|
||||
py_binary(
|
||||
name = "format_fix",
|
||||
name = "format",
|
||||
srcs = [
|
||||
"tests/run_format.py",
|
||||
],
|
||||
|
@ -42,7 +42,7 @@ filegroup(
|
||||
)
|
||||
|
||||
prettier_test(
|
||||
name = "format",
|
||||
name = "format_check",
|
||||
srcs = glob(["*.ts"]),
|
||||
)
|
||||
|
||||
|
@ -134,14 +134,14 @@ rust_test(
|
||||
)
|
||||
|
||||
rustfmt_test(
|
||||
name = "format",
|
||||
name = "format_check",
|
||||
srcs = glob([
|
||||
"src/**/*.rs",
|
||||
]),
|
||||
)
|
||||
|
||||
rustfmt_fix(
|
||||
name = "format_fix",
|
||||
name = "format",
|
||||
srcs = glob([
|
||||
"src/**/*.rs",
|
||||
]),
|
||||
|
@ -57,7 +57,7 @@ exports_files(["congrats.html"])
|
||||
################
|
||||
|
||||
prettier_test(
|
||||
name = "format",
|
||||
name = "format_check",
|
||||
srcs = glob([
|
||||
"*.ts",
|
||||
"*.svelte",
|
||||
@ -72,7 +72,7 @@ eslint_test(
|
||||
)
|
||||
|
||||
svelte_check(
|
||||
name = "svelte-check",
|
||||
name = "svelte_check",
|
||||
srcs = glob([
|
||||
"*.ts",
|
||||
"*.svelte",
|
||||
|
@ -99,7 +99,7 @@ exports_files(["graphs.html"])
|
||||
################
|
||||
|
||||
prettier_test(
|
||||
name = "format",
|
||||
name = "format_check",
|
||||
srcs = glob([
|
||||
"*.ts",
|
||||
"*.svelte",
|
||||
@ -117,7 +117,7 @@ eslint_test(
|
||||
)
|
||||
|
||||
svelte_check(
|
||||
name = "svelte-check",
|
||||
name = "svelte_check",
|
||||
srcs = glob([
|
||||
"*.ts",
|
||||
"*.svelte",
|
||||
|
@ -51,7 +51,7 @@ filegroup(
|
||||
################
|
||||
|
||||
prettier_test(
|
||||
name = "format",
|
||||
name = "format_check",
|
||||
srcs = glob(["*.ts"]),
|
||||
)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user