Less parser error while precompiling assets rails

83 Views Asked by At

Here is my Gemfile.

source 'https://rubygems.org'


# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
gem 'rails', '4.1.1'
# Use mysql as the database for Active Record
gem 'mysql2'
# Use SCSS for stylesheets
gem 'pg'
gem 'rails_12factor', group: :production
gem 'sass-rails', '~> 4.0.3'

gem 'uglifier', '>= 1.3.0'

gem 'coffee-rails', '~> 4.0.0'
gem 'geocoder'
gem 'geocomplete_rails'
gem 'google_timezone'

gem 'jquery-rails'

gem 'tag-it-rails'
gem 'turbolinks'
gem 'rails4-autocomplete'
gem 'jbuilder', '~> 2.0'
gem 'sdoc', '~> 0.4.0',          group: :doc
gem 'will_paginate', '~> 3.0'
gem 'devise'
gem 'pry'
gem 'friendly_id'
gem "paperclip"
gem 'aws-sdk'
gem 'best_in_place'
gem "nested_form"
gem 'acts-as-taggable-on'
gem 'bootstrap-timepicker-rails'
gem 'mandrill_mailer'
gem 'bootstrap-sass'
gem "font-awesome-rails"
gem 'phony_rails'
gem 'twilio-ruby'
gem 'gmaps4rails'
gem "stripe"
gem "humanize"
gem "prawn"
gem 'activeadmin', github: 'gregbell/active_admin'

gem 'spring',        group: :development



gem "therubyracer"
gem "less-rails"
gem "twitter-bootstrap-rails"

and I have this in my application.rb file

config.assets.paths << File.join(Rails.root, "/vendor/pages")

I have both scss and less files in my assets when I try to precompile my assets with rake assets:precompile I get this error

Less::ParseError: .padding-right is undefined

what I am doing wrong here any help?

1

There are 1 best solutions below

0
On

I was able to precompile my assets in production mode with

RAILS_ENV=production rake assets:precompile

I am not sure why it worked may be because of rails_12factor gem but it solved my problem.