kwanhur commented on a change in pull request #6428:
URL: https://github.com/apache/apisix/pull/6428#discussion_r817305089



##########
File path: .github/workflows/code-lint.yml
##########
@@ -28,3 +28,20 @@ jobs:
         . ./ci/common.sh
         export_or_prefix
         make lint
+
+  sc-lint:
+    runs-on: ubuntu-latest
+    timeout-minutes: 5
+    steps:
+      - name: Checkout code
+        uses: actions/[email protected]
+        with:
+          submodules: true
+
+      - name: Shellcheck code
+        run: |
+          scversion="latest"
+          wget -O- 
"https://github.com/koalaman/shellcheck/releases/download/${scversion?}/shellcheck-${scversion?}.linux.x86_64.tar.xz";
 | tar -xJv
+          cp -av "shellcheck-${scversion}/shellcheck" /usr/local/bin/
+          shellcheck --version
+          shellcheck **/*.sh

Review comment:
       Solution 1: not checkout submodule, then this won't lint shell files in 
submodule
   ```yaml
       steps:
         - name: Checkout code
           uses: actions/[email protected]
   ```
   
   Solution 2: specify shellcheck paths, exclude submodule, so it won't lint in 
submodule
   
   From this tip, I think you mean the solution 2.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to