hammerlab / cycledash

Variant Caller Analysis Dashboard and Data Management System
Other
36 stars 2 forks source link

Rename and move Bootstrap files in a single step #817

Closed armish closed 9 years ago

armish commented 9 years ago

Previously the merged gulp tasks that suppose to prepare the Bootstrap files for importing within style.scss were failing to do so because one was depending on the other but they were being run synchronously. This was why we weren't seeing the error on the second run:

# clean-up
(venv)arman@narnia cycledash > rm -f cycledash/static/css/* && rm -f cycledash/static/fonts/* && rm -rf cycledash/static/lib/*

# First run fails to create bootstrap scss due to race condition
(venv)arman@narnia cycledash > gulp staticlibs
[15:10:46] Using gulpfile ~/Projects/cycledash/gulpfile.js
[15:10:46] Starting 'staticlibs'...
[15:10:47] Finished 'staticlibs' after 94 ms
(venv)arman@narnia cycledash > ls cycledash/static/lib/bootstrap/scss
ls: cycledash/static/lib/bootstrap/scss: No such file or directory

# Second run is OK
(venv)arman@narnia cycledash > gulp staticlibs
[15:11:25] Using gulpfile ~/Projects/cycledash/gulpfile.js
[15:11:25] Starting 'staticlibs'...
[15:11:25] Finished 'staticlibs' after 73 ms
(venv)arman@narnia cycledash > ls cycledash/static/lib/bootstrap/scss
bootstrap.scss

This collapses the two-step Bootstrap procedure into a single-step one, hence fixes #782.

# clean-up
(venv)arman@narnia cycledash > rm -f cycledash/static/css/* && rm -f cycledash/static/fonts/* && rm -rf cycledash/static/lib/*

# after this change
(venv)arman@narnia cycledash > gulp sass
[16:00:15] Using gulpfile ~/Projects/cycledash/gulpfile.js
[16:00:15] Starting 'staticlibs'...
[16:00:15] Finished 'staticlibs' after 97 ms
[16:00:15] Starting 'sass'...
[16:00:18] Finished 'sass' after 2.51 s
(venv)arman@narnia cycledash > 

Review on Reviewable

ihodes commented 9 years ago

Awesome, thank you!

@jaclynperrone as our resident SCSS expert, does this look good to you?

jaclynperrone commented 9 years ago

Looks great! Thanks so much for doing this.

armish commented 9 years ago

thanks a lot for the sanity check! Merging this one in.

Welcome back @jaclynperrone and @ihodes :tada: