LightGBM icon indicating copy to clipboard operation
LightGBM copied to clipboard

[ci] resolve shellcheck errors in .ci/check_python_dists.sh

Open kunalsinghdadhwal opened this issue 1 year ago • 0 comments

Contributing to #6498 , So in the file .ci/check_python_dists.sh the errors raise by shellcheck were

In .ci/check_python_dists.sh line 3:
set -e -E -u
       ^-- SC3041 (warning): In POSIX sh, set flag -E is undefined.

So I changes the shebang line from #!/bin/sh to #!/bin/bash

Then shellcheck was giving errors based on SC2086 i.e.

In .ci/check_python_dists.sh line 23:
    check-wheel-contents ${DIST_DIR}/*.whl || exit 1
                         ^---------^ SC2086 (info): Double quote to prevent globbing and word splitting.

The same errors were also on line 19,37,45,52 which can be resolved by changing ${DIST_DIR}/* to "${DIST_DIR}/*"

kunalsinghdadhwal avatar Jun 24 '24 05:06 kunalsinghdadhwal