mirror of
https://github.com/LaCasemate/fab-manager.git
synced 2025-01-30 19:52:20 +01:00
Disable assets debug on development environment only when running with Vagrant
This commit is contained in:
parent
eb91d02ebe
commit
e342a070de
2
Vagrantfile
vendored
2
Vagrantfile
vendored
@ -28,7 +28,7 @@ Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
|
||||
config.vm.synced_folder '.', '/vagrant', type: 'virtualbox'
|
||||
|
||||
# Provisioning
|
||||
config.vm.provision "shell", privileged: true, run: "always" do |s|
|
||||
config.vm.provision "shell", privileged: true, run: "once" do |s|
|
||||
s.inline = "export LC_ALL=en_US.UTF-8\n" \
|
||||
"export LANG=en_US.UTF-8\n" \
|
||||
"export LANGUAGE=en_US.UTF-8"
|
||||
|
@ -4,7 +4,7 @@ Rails.application.configure do
|
||||
# In the development environment your application's code is reloaded on
|
||||
# every request. This slows down response time but is perfect for development
|
||||
# since you don't have to restart the web server when you make code changes.
|
||||
config.cache_classes = true
|
||||
config.cache_classes = false
|
||||
|
||||
# Do not eager load code on boot.
|
||||
config.eager_load = false
|
||||
@ -25,7 +25,8 @@ Rails.application.configure do
|
||||
# Debug mode disables concatenation and preprocessing of assets.
|
||||
# This option may cause significant delays in view rendering with a large
|
||||
# number of complex assets.
|
||||
config.assets.debug = false
|
||||
# Set to false when running with Vagrant to speed up response time.
|
||||
config.assets.debug = ENV['VIRTUAL_DEV_ENV'] ? false : true
|
||||
|
||||
# Asset digests allow you to set far-future HTTP expiration dates on all assets,
|
||||
# yet still be able to expire them through the digest params.
|
||||
|
@ -1,5 +1,19 @@
|
||||
#!/usr/bin/env zsh
|
||||
|
||||
# Set environmen values #######################################################
|
||||
|
||||
# Virtual environment flag
|
||||
echo '# Set virtual environment flag' >> ~/.profile
|
||||
echo 'export VIRTUAL_DEV_ENV=true' >> ~/.profile
|
||||
echo "\n" >> ~/.profile
|
||||
|
||||
# Language configuration
|
||||
echo '# Set locale configuration' >> ~/.profile
|
||||
echo 'export LC_ALL=en_US.UTF-8' >> ~/.profile
|
||||
echo 'export LANG=en_US.UTF-8' >> ~/.profile
|
||||
echo 'export LANGUAGE=en_US.UTF-8' >> ~/.profile
|
||||
echo "\n" >> ~/.profile
|
||||
|
||||
# Install and setup PostgreSQL ################################################
|
||||
|
||||
echo "***************************************************"
|
||||
@ -93,14 +107,6 @@ echo "***************************************************"
|
||||
echo "Checking for NVM... "
|
||||
echo "***************************************************"
|
||||
if [[ ! -x "$HOME/.nvm" ]]; then
|
||||
|
||||
# Set language configuration
|
||||
echo '# Set locale configuration' >> ~/.profile
|
||||
echo 'export LC_ALL=en_US.UTF-8' >> ~/.profile
|
||||
echo 'export LANG=en_US.UTF-8' >> ~/.profile
|
||||
echo 'export LANGUAGE=en_US.UTF-8' >> ~/.profile
|
||||
echo "\n" >> ~/.profile
|
||||
|
||||
wget -qO- https://raw.githubusercontent.com/creationix/nvm/v0.33.2/install.sh | bash
|
||||
|
||||
echo '# Node Version Manager' >> ~/.profile
|
||||
|
Loading…
x
Reference in New Issue
Block a user