Created
October 10, 2018 23:13
-
-
Save cesasol/d57731cd767c47eb414a6b0a94714269 to your computer and use it in GitHub Desktop.
pnpm install solver
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
#!/bin/sh | |
# This is a simple hack to fix the pnpm module resolution, if you encounter "Module not found" in some deep dependency of your | |
# project, then use this script to add those not founded dependencies as a direct dev dependency. | |
# All credit goes to flaviut https://github.com/pnpm/pnpm/issues/1261 | |
while true; do pnpm install -D $(pnpm start 2>&1 | grep 'Error: Cannot find module' | sed "s/Error: Cannot find module '\([a-z.-]\+\)'/\1/g"); done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment