Skip to content

Commit 4c18ba1

Browse files
committed
make it so plugins can have their own package.json
closes CNVS-36896 test plan: check this out check out g/108509 in gems/plugins/analytics run `yarn` you should see it install graphael for analytics Change-Id: Iee6a2d8bb2ee46d1cddc596b972d447f9bb3b1d6 Reviewed-on: https://gerrit.instructure.com/111765 Tested-by: Jenkins Reviewed-by: Simon Williams <simon@instructure.com> Product-Review: Ryan Shaw <ryan@instructure.com> QA-Review: Ryan Shaw <ryan@instructure.com>
1 parent a0a0757 commit 4c18ba1

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

script/gem_npm

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,14 @@
77
# developing one of these, go into the dir and yarn there
88
export NODE_ENV=production
99

10-
for path in $(ls -1 gems/*/package.json); do
11-
cd ${path:0:${#path}-13}
10+
for path in $(ls -1 gems/{,plugins/}*/package.json 2> /dev/null); do
11+
pushd $(dirname $path) > /dev/null
1212
if hash yarn 2>/dev/null; then
1313
echo "running yarn $1 for $path"
1414
yarn $1
1515
else
1616
echo "npm is deprecated in canvas-lms. You should start using yarn instead. see https://yarnpkg.com. Running npm $1 for $path"
1717
npm $1
1818
fi
19-
cd ../..
19+
popd > /dev/null
2020
done

0 commit comments

Comments
 (0)