guess-js-deps-bash 0.1.52 → 0.1.53
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/guess-js-deps.sh +5 -1
- package/package.json +1 -1
package/guess-js-deps.sh
CHANGED
|
@@ -643,6 +643,9 @@ function guess_one_dep_type () {
|
|
|
643
643
|
fi
|
|
644
644
|
|
|
645
645
|
local SUBDIR=
|
|
646
|
+
local REQ_NORM_FEXT="$REQ_FILE"
|
|
647
|
+
REQ_NORM_FEXT="${REQ_NORM_FEXT/%.js/.%JS}"
|
|
648
|
+
REQ_NORM_FEXT="${REQ_NORM_FEXT/%.mjs/.%JS}"
|
|
646
649
|
if [ "$DEP_TYPE" == dep ]; then
|
|
647
650
|
SUBDIR="${REQ_FILE%%/*}"
|
|
648
651
|
case "${SUBDIR%s}" in
|
|
@@ -652,13 +655,14 @@ function guess_one_dep_type () {
|
|
|
652
655
|
doc | \
|
|
653
656
|
test ) DEP_TYPE=devDep;;
|
|
654
657
|
esac
|
|
655
|
-
case "$
|
|
658
|
+
case "$REQ_NORM_FEXT" in
|
|
656
659
|
*/webpack.config.js | \
|
|
657
660
|
manif://scripts/*lint* | \
|
|
658
661
|
manif://scripts/*test* | \
|
|
659
662
|
manif://lint ) DEP_TYPE=devDep;;
|
|
660
663
|
*/* ) ;; # files in subdirs are handled above
|
|
661
664
|
# below: top-level files
|
|
665
|
+
*[.-]test.%JS | \
|
|
662
666
|
test.* ) DEP_TYPE=devDep;;
|
|
663
667
|
esac
|
|
664
668
|
fi
|
package/package.json
CHANGED