Skip to content

Commit

Permalink
chore(docs): fix eslint copy-pasta (#345)
Browse files Browse the repository at this point in the history
Also add spell checker like we have now in bazel-lib
  • Loading branch information
alexeagle authored Jul 21, 2024
1 parent 0c0360b commit 5d4a14c
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 6 deletions.
4 changes: 4 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,7 @@ repos:
rev: "v2.4.0"
hooks:
- id: prettier
- repo: https://github.com/crate-ci/typos
rev: v1.23.2
hooks:
- id: typos
4 changes: 2 additions & 2 deletions docs/stylelint.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion example/src/cpp/lib/get/.clang-tidy
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# https://clang.llvm.org/extra/clang-tidy/
# this is an example of a .clang-tidy file in a subdirectory that overrides
# the configuration for files in this directory and below. It must be made
# visibile through an export_files declaration in this package and added
# visible through an export_files declaration in this package and added
# to the 'configs' attribute in clang_tidy aspect.
Checks: "-*, misc-const-correctness"
2 changes: 1 addition & 1 deletion example/src/cpp/lib/get/get-time.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

const char* get_localtime_impl();

// Deliberatly bad code
// Deliberately bad code
inline char* get_localtime() {
const char* time = get_localtime_impl();
char timebuf[20];
Expand Down
4 changes: 2 additions & 2 deletions lint/stylelint.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ def stylelint_action(ctx, executable, srcs, config, stderr, exit_code = None, en
config: js_library representing the config file (and its dependencies)
stderr: output file containing the stderr or --output-file of stylelint
exit_code: output file containing the exit code of stylelint.
If None, then fail the build when eslint exits non-zero.
If None, then fail the build when stylelint exits non-zero.
Exit codes may be:
1 - fatal error
2 - lint problem
Expand Down Expand Up @@ -100,7 +100,7 @@ def stylelint_fix(ctx, executable, srcs, config, patch, stderr, exit_code, env =
patch: output file containing the applied fixes that can be applied with the patch(1) command.
stderr: output file containing the stderr or --output-file of stylelint
exit_code: output file containing the exit code of stylelint
env: environment variaables for eslint
env: environment variables for stylelint
options: additional command line options
"""
patch_cfg = ctx.actions.declare_file("_{}.patch_cfg".format(ctx.label.name))
Expand Down

0 comments on commit 5d4a14c

Please sign in to comment.