Skip to content

Instantly share code, notes, and snippets.

@mattbrictson
Created January 26, 2012 23:02
Show Gist options
  • Select an option

  • Save mattbrictson/1685685 to your computer and use it in GitHub Desktop.

Select an option

Save mattbrictson/1685685 to your computer and use it in GitHub Desktop.

Revisions

  1. mattbrictson revised this gist Dec 12, 2012. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion application.scss
    Original file line number Diff line number Diff line change
    @@ -7,7 +7,7 @@

    // Include some nice mixins
    @import "compass/css3";
    @import "sassybuttons";
    @import "sassy-buttons";

    // Example: import partial stylesheet named "_users.scss"
    @import "users";
  2. mattbrictson revised this gist Feb 3, 2012. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion application.rb
    Original file line number Diff line number Diff line change
    @@ -1,2 +1,2 @@
    # Specify this within the application class of config/application.rb
    # Precompile *all* assets, except those that start with underscore
    config.assets.precompile << /(^[^_\/]|\/[^_])[^\/]*$/
  3. mattbrictson revised this gist Feb 3, 2012. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion Gemfile
    Original file line number Diff line number Diff line change
    @@ -3,5 +3,5 @@ group :assets do
    gem 'compass-colors'
    gem 'sassy-buttons'
    gem 'sass-rails', '~> 3.2.3'
    # non-compass gems omitted for clarity
    # non-compass gems omitted for brevity
    end
  4. mattbrictson revised this gist Feb 3, 2012. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions Gemfile
    Original file line number Diff line number Diff line change
    @@ -1,7 +1,7 @@
    group :assets do
    gem 'compass', '>= 0.12.alpha.1'
    gem 'compass-rails','~> 1.0.0.rc.2'
    gem 'compass-colors'
    gem 'sass-rails', '~> 3.2.3'
    gem 'sassy-buttons'
    gem 'sass-rails', '~> 3.2.3'
    # non-compass gems omitted for clarity
    end
  5. mattbrictson revised this gist Feb 3, 2012. 2 changed files with 5 additions and 0 deletions.
    1 change: 1 addition & 0 deletions Gemfile
    Original file line number Diff line number Diff line change
    @@ -1,6 +1,7 @@
    group :assets do
    gem 'compass', '>= 0.12.alpha.1'
    gem 'compass-colors'
    gem 'sass-rails', '~> 3.2.3'
    gem 'sassy-buttons'
    # non-compass gems omitted for clarity
    end
    4 changes: 4 additions & 0 deletions digest_for-error
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,4 @@
    A ActionView::Template::Error occurred in sessions#new:

    1024.css isn't precompiled
    .bundle/bundle/gems/actionpack-3.2.0/lib/sprockets/helpers/rails_helper.rb:142:in `digest_for'
  6. mattbrictson revised this gist Jan 26, 2012. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion tree
    Original file line number Diff line number Diff line change
    @@ -11,4 +11,4 @@
    │ └── application.scss
    └── config
    ├── application.rb
    └── compass.rb
    └── compass.rb
  7. mattbrictson revised this gist Jan 26, 2012. 1 changed file with 14 additions and 0 deletions.
    14 changes: 14 additions & 0 deletions tree
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,14 @@
    .
    ├── Gemfile
    ├── app
    │ └── assets
    │ ├── images
    │ │ └── logo-small.png
    │ ├── javascripts
    │ │ └── application.js
    │ └── stylesheets
    │ ├── _users.scss
    │ └── application.scss
    └── config
    ├── application.rb
    └── compass.rb
  8. mattbrictson revised this gist Jan 26, 2012. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion rake-output
    Original file line number Diff line number Diff line change
    @@ -2,7 +2,7 @@ $ bundle exec rake assets:precompile
    /Users/mbrictson/.rbenv/versions/1.9.3-p0/bin/ruby script/rake assets:precompile:all RAILS_ENV=production RAILS_GROUPS=assets
    rake aborted!
    Undefined variable: "$body-text-line-height".
    (in /Users/mbrictson/Work/devicescout/app/app/assets/stylesheets/basics/_grid.scss)
    (in /Users/mbrictson/Work/rails-project/app/assets/stylesheets/basics/_grid.scss)

    Tasks: TOP => assets:precompile:primary
    (See full trace by running task with --trace)
  9. mattbrictson created this gist Jan 26, 2012.
    6 changes: 6 additions & 0 deletions Gemfile
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,6 @@
    group :assets do
    gem 'compass', '>= 0.12.alpha.1'
    gem 'compass-colors'
    gem 'sassy-buttons'
    # non-compass gems omitted for clarity
    end
    2 changes: 2 additions & 0 deletions application.rb
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,2 @@
    # Specify this within the application class of config/application.rb
    config.assets.precompile << /(^[^_\/]|\/[^_])[^\/]*$/
    13 changes: 13 additions & 0 deletions application.scss
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,13 @@
    /*
    * application.scss
    *
    * Important! Do *not* use Sprockets "require" syntax.
    * Use @import to include other stylesheets and Compass mixins.
    */

    // Include some nice mixins
    @import "compass/css3";
    @import "sassybuttons";

    // Example: import partial stylesheet named "_users.scss"
    @import "users";
    2 changes: 2 additions & 0 deletions compass.rb
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,2 @@
    # config/compass.rb
    additional_import_paths = ["app/assets/stylesheets/basics", "app/assets/stylesheets/shared"]
    4 changes: 4 additions & 0 deletions example.scss
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,4 @@
    .logo
    {
    background: image-url("logo-small.png") no-repeat;
    }
    13 changes: 13 additions & 0 deletions rake-output
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,13 @@
    $ bundle exec rake assets:precompile
    /Users/mbrictson/.rbenv/versions/1.9.3-p0/bin/ruby script/rake assets:precompile:all RAILS_ENV=production RAILS_GROUPS=assets
    rake aborted!
    Undefined variable: "$body-text-line-height".
    (in /Users/mbrictson/Work/devicescout/app/app/assets/stylesheets/basics/_grid.scss)

    Tasks: TOP => assets:precompile:primary
    (See full trace by running task with --trace)
    rake aborted!
    Command failed with status (1): [/Users/mbrictson/.rbenv/versions/1.9.3-p0/...]

    Tasks: TOP => assets:precompile
    (See full trace by running task with --trace)