diff --git a/bootstrap.sh b/bootstrap.sh index 792a40f3..91fffe0c 100755 --- a/bootstrap.sh +++ b/bootstrap.sh @@ -3,28 +3,33 @@ # Configure the CSS. STATIC_FOLDER=lowfat/static/ -TMP_FOLDER=/tmp/ -BOOTSTRAP_ZIP=/tmp/bootstrap.zip -FONT_AWESOME_ZIP=/tmp/fontawesome.zip -ACADEMICONS_ZIP=/tmp/academicons.zip -GARLIC_ZIP=/tmp/garlic.zip +TMP_FOLDER=$(mktemp -d) +BOOTSTRAP_ZIP=${TMP_FOLDER}/bootstrap.zip +FONT_AWESOME_ZIP=${TMP_FOLDER}/fontawesome.zip +ACADEMICONS_ZIP=${TMP_FOLDER}/academicons.zip +GARLIC_ZIP=${TMP_FOLDER}/garlic.zip +DATETIME_WIDGET_ZIP=${TMP_FOLDER}/datetimewidget.zip # Bootstrap curl \ + --silent \ -L \ -o $BOOTSTRAP_ZIP \ https://github.com/twbs/bootstrap/releases/download/v3.3.6/bootstrap-3.3.6-dist.zip unzip \ + -q \ -u \ $BOOTSTRAP_ZIP \ -d $TMP_FOLDER # Font Awesome curl \ + --silent \ -L \ -o $FONT_AWESOME_ZIP \ https://github.com/FortAwesome/Font-Awesome/archive/v4.6.3.zip unzip \ + -q \ -u \ $FONT_AWESOME_ZIP \ -d $TMP_FOLDER @@ -33,10 +38,12 @@ unzip \ # # Supplement for Font Awesome curl \ + --silent \ -L \ -o $ACADEMICONS_ZIP \ https://github.com/jpswalsh/academicons/archive/v1.7.0.zip unzip \ + -q \ -u \ $ACADEMICONS_ZIP \ -d $TMP_FOLDER @@ -44,6 +51,7 @@ unzip \ # Sorttable mkdir -p $TMP_FOLDER/sorttable/js curl \ + --silent \ -L \ -o $TMP_FOLDER/sorttable/js/sorttable.js \ http://www.kryogenix.org/code/browser/sorttable/sorttable.js @@ -51,17 +59,32 @@ curl \ # Garlic.js mkdir -p $TMP_FOLDER/garlic/js curl \ + --silent \ -L \ -o $GARLIC_ZIP \ https://github.com/guillaumepotier/Garlic.js/archive/1.2.4.zip unzip \ + -q \ -p \ $GARLIC_ZIP \ Garlic.js-1.2.4/dist/garlic.min.js \ > $TMP_FOLDER/garlic/js/garlic.min.js +# Datetime Widget +curl \ + --silent \ + -L \ + -o $DATETIME_WIDGET_ZIP \ + https://github.com/asaglimbeni/django-datetime-widget/archive/master.zip +unzip \ + -q \ + -u \ + $DATETIME_WIDGET_ZIP \ + -d $TMP_FOLDER +mv $TMP_FOLDER/django-datetime-widget-master/datetimewidget/static $TMP_FOLDER/datetimewidget/ + # Copy files for folder in css fonts js do - cp -r $TMP_FOLDER/*/$folder $STATIC_FOLDER + cp -v -r $TMP_FOLDER/*/$folder $STATIC_FOLDER done