Skip to content

Commit

Permalink
LINT.md: Update super-linter version and escape find command
Browse files Browse the repository at this point in the history
Change-Id: If63b070d68b3ecf833ce94b03fabef045c15ac56
Signed-off-by: Joakim Roubert <[email protected]>
  • Loading branch information
joakimr-axis committed Feb 27, 2024
1 parent df0d07f commit c89b1a3
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
1 change: 1 addition & 0 deletions .github/super-linter.env
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
DEFAULT_BRANCH=main
LINTER_RULES_PATH=/
VALIDATE_ALL_CODEBASE=true
IGNORE_GITIGNORED_FILES=true
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on: push

jobs:
build_acap:
name: Build ACAPs
name: Build ACAP applications
runs-on: ubuntu-latest
env:
DEBIAN_FRONTEND: noninteractive
Expand Down
8 changes: 4 additions & 4 deletions LINT.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ docker run --rm \
-v "$PWD":/tmp/lint \
-e RUN_LOCAL=true \
--env-file .github/super-linter.env \
ghcr.io/super-linter/super-linter:slim-v5
ghcr.io/super-linter/super-linter:slim-v6
```

## Run super-linter interactively
Expand All @@ -36,7 +36,7 @@ docker run -it --rm \
-w /tmp/lint \
--env-file .github/super-linter.env \
--entrypoint /bin/bash \
ghcr.io/super-linter/super-linter:slim-v5
ghcr.io/super-linter/super-linter:slim-v6
```

Then from the container terminal, the following commands can lint the the code
Expand All @@ -47,10 +47,10 @@ base for different file types:
find "$PWD" \( -iname \*.c -or -iname \*.h \) -exec clang-format --dry-run --Werror --verbose {} +

# Lint Dockerfile files
hadolint $(find -type f -name Dockerfile*)
hadolint $(find -type f -name Dockerfile\*)

# Lint Dockerfile files (alternative command)
find -type f -name Dockerfile* -exec hadolint {} +
find -type f -name Dockerfile\* -exec hadolint {} +

# Lint JSON files
eslint --no-eslintrc -c /action/lib/.automation/.eslintrc.yml --ext .json .
Expand Down

0 comments on commit c89b1a3

Please sign in to comment.