aboutsummaryrefslogtreecommitdiffstats
path: root/bin/install-as-user
diff options
context:
space:
mode:
authorMatthew Somerville <matthew-github@dracos.co.uk>2016-05-31 08:58:54 +0100
committerMatthew Somerville <matthew-github@dracos.co.uk>2016-05-31 15:36:08 +0100
commit38e2918987677253b6a337f5287c2e29685b9c78 (patch)
tree730f88f1cdef16d2e3c95cd6b95972277cb6b158 /bin/install-as-user
parenta2b2bdd3813ad60c97269147efb8f0353becb66c (diff)
Improve CSS compilation.
Move to using libsass via CSS::Sass, and stop using compass, supplying any used mixins directly. This removes the need for any ruby/gem based installation, and greatly increases the speed of compilation. make_css is also enhanced, bringing in the file monitoring previously done by a separate script and improving its dependency monitoring.
Diffstat (limited to 'bin/install-as-user')
-rwxr-xr-xbin/install-as-user33
1 files changed, 7 insertions, 26 deletions
diff --git a/bin/install-as-user b/bin/install-as-user
index 297efc1f3..99eca0b82 100755
--- a/bin/install-as-user
+++ b/bin/install-as-user
@@ -71,32 +71,6 @@ if [ ! "$DEVELOPMENT_INSTALL" = true ]; then
echo $DONE_MSG
fi
-# Install the compass gem locally - it's required for generating the
-# CSS. Don't trust the bundled bundler in e.g. precise.
-echo "Setting up CSS... "
-gem1.9.1 install --user-install --no-ri --no-rdoc bundler
-FMS_GEMPATH="$DIRECTORY/gem-bin"
-FMS_GEMPATH="$FMS_GEMPATH:$(ruby1.9.1 -rubygems -e 'puts Gem.user_dir')/bin"
-export PATH="$FMS_GEMPATH:$PATH"
-
-if ! grep -q 'Set up local PATH for FixMyStreet' $HOME/.bashrc; then
- cat >>$HOME/.bashrc <<EOBRC
-
-# Set up local PATH for FixMyStreet
-export PATH="$FMS_GEMPATH:\$PATH"
-EOBRC
-fi
-
-bundle install --deployment --path "$DIRECTORY/gems" --binstubs "$DIRECTORY/gem-bin"
-
-# Use compass to generate the CSS, if it doesn't seem to already
-# exist:
-if [ ! -f web/cobrands/default/base.css ]
-then
- bin/make_css
-fi
-echo $DONE_MSG
-
# Write sensible values into the config file, if it doesn't already exist
if [ ! -f conf/general.yml ]; then
echo -n "Setting up default conf/general.yml file... "
@@ -117,6 +91,13 @@ cd "$REPOSITORY"
bin/install_perl_modules
echo $DONE_MSG
+echo "Setting up CSS... "
+if [ ! -f web/cobrands/default/base.css ]
+then
+ bin/make_css
+fi
+echo $DONE_MSG
+
# Create the database if it doesn't exist:
echo -n "Setting up database... "
if ! psql -l | egrep "^ *$DB_NAME *\|" > /dev/null