fix: sharp cache restore path (remove fragile find+xargs)
This commit is contained in:
5
.github/workflows/deploy.yml
vendored
5
.github/workflows/deploy.yml
vendored
@@ -20,9 +20,8 @@ jobs:
|
||||
CACHE_FILE=/usr/local/git/.cache/sharp-freebsd/sharp-freebsd-x64-${SHARP_VER}.node
|
||||
if [ -f "$CACHE_FILE" ]; then
|
||||
echo "Restoring cached sharp ${SHARP_VER}"
|
||||
DEST=$(find node_modules/sharp -name "build.js" -path "*/install/*" | head -1 | xargs dirname | xargs dirname)
|
||||
mkdir -p "$DEST/build/Release"
|
||||
cp "$CACHE_FILE" "$DEST/build/Release/sharp-freebsd-x64.node"
|
||||
mkdir -p node_modules/sharp/build/Release
|
||||
cp "$CACHE_FILE" node_modules/sharp/build/Release/sharp-freebsd-x64.node
|
||||
else
|
||||
echo "Building sharp ${SHARP_VER} from source..."
|
||||
npm install node-addon-api node-gyp
|
||||
|
||||
Reference in New Issue
Block a user