run-dev: Automatically fixup missing handlebars binary.

This commit is contained in:
Tim Abbott 2016-09-07 19:35:25 -07:00
parent c9f9fb265e
commit 3c34264559
1 changed files with 6 additions and 0 deletions

View File

@ -87,6 +87,12 @@ os.chdir(os.path.join(os.path.dirname(__file__), '..'))
# Clean up stale .pyc files etc.
subprocess.check_call('./tools/clean-repo')
# HACK to fix up node_modules/.bin/handlebars deletion issue
if not os.path.exists("node_modules/.bin/handlebars") and os.path.exists("node_modules/handlebars"):
print("Handlebars binary missing due to rebase past .gitignore fixup; fixing...")
subprocess.check_call(["rm", "-rf", "node_modules/handlebars"])
subprocess.check_call(["npm", "install"])
if options.clear_memcached:
print("Clearing memcached ...")
subprocess.check_call('./scripts/setup/flush-memcached')