Skip to content

Instantly share code, notes, and snippets.

@j-wang
Created May 8, 2017 17:07
Show Gist options
  • Save j-wang/688b27fb396a14b6c14f25bf0cb72073 to your computer and use it in GitHub Desktop.
Save j-wang/688b27fb396a14b6c14f25bf0cb72073 to your computer and use it in GitHub Desktop.
A little script to automate clearing node modules and packager cache for React Native.
#!/bin/bash
echo "Starting clearing watchman..."
watchman watch-del-all
echo "Removing and reinstall node modules"
rm -rf node_modules && npm install
echo "Clearing packager cache..."
rm -fr $TMPDIR/react-*
echo "Done."
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment