-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add more notes on what's going on there
- Loading branch information
1 parent
40e3181
commit 96c68f2
Showing
1 changed file
with
16 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,21 @@ | ||
#!/bin/sh | ||
set -eu | ||
|
||
echo "* Build PrestaShop assets..." | ||
echo "* Download composer dependencies..." | ||
make composer | ||
|
||
echo "* Build PrestaShop assets..." | ||
# Disclaimer: it seems that the PrestaShop front-end assets currently require | ||
# to install Node.js dependencies globally. This is a bad pattern, which would | ||
# require this script to be run as root. | ||
# | ||
# As an alternative, we propose this NPM_PREFIX_DIR hack suggestion, which could | ||
# eventually help to avoid running init-scripts as root in the future | ||
# | ||
NPM_PREFIX_DIR=/tmp/npm | ||
mkdir -p $NPM_PREFIX_DIR | ||
npm prefix -g $NPM_PREFIX_DIR | ||
export PATH="$PATH:$NPM_PREFIX_DIR/bin" | ||
make assets | ||
echo "* Assets built!" | ||
|
||
echo "✅ Assets built!" |