Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Asset:Precompile too verbose

I am new to JRuby and Rails. When I precompile my assets it fills my logs with junk that I am not interested in.

(in /srv/test/releases/cba9797f510b211ff3568c9bb800ee7a7366c319) mkdir -p /srv/test/releases/cba9797f510b211ff3568c9bb800ee7a7366c319/public/assets mkdir -p /srv/test/releases/cba9797f510b211ff3568c9bb800ee7a7366c319/public/assets/controllers mkdir -p /srv/test/releases/cba9797f510b211ff3568c9bb800ee7a7366c319/public/assets/controllers mkdir -p /srv/test/releases/cba9797f510b211ff3568c9bb800ee7a7366c319/public/assets/controllers mkdir -p /srv/test/releases/cba9797f510b211ff3568c9bb800ee7a7366c319/public/assets/controllers mkdir -p /srv/test/releases/cba9797f510b211ff3568c9bb800ee7a7366c319/public/assets/controllers mkdir -p /srv/test/releases/cba9797f510b211ff3568c9bb800ee7a7366c319/public/assets/controllers

I have tried --quiet, i have turned logging off.

Any ideas?

Thanks!

like image 599
user985839 Avatar asked Oct 08 '11 21:10

user985839


People also ask

What is assets Precompile?

rails assets:precompile is the task that does the compilation (concatenation, minification, and preprocessing). When the task is run, Rails first looks at the files in the config.assets.precompile array. By default, this array includes application.js and application.css .

What does Rails assets Precompile do?

The Rails asset pipeline provides an assets:precompile rake task to allow assets to be compiled and cached up front rather than compiled every time the app boots. There are two ways you can use the asset pipeline on Heroku. Compiling assets locally. Compiling assets during slug compilation.

What does require_ tree do?

The require_tree directive tells Sprockets to recursively include all JavaScript files in the specified directory into the output. These paths must be specified relative to the manifest file.


1 Answers

There are two main output suppressor options that you might want to consider.

Do not log messages to standard output.

-q, --quiet     

Also suppresses the 'in directory' announcement.

-s, --silent

Silent is probably the option you were looking for. You can view all the options for most rake tasks by adding the --help option. For example:

rake assets:precompile --help

Hope this helps. For more info on precompiling assets see this post.

like image 97
Phil Bottomley Avatar answered Sep 22 '22 14:09

Phil Bottomley