Skip to content

Commit

Permalink
Gemify for a Rails app.
Browse files Browse the repository at this point in the history
  • Loading branch information
mike-burns committed Jun 30, 2011
1 parent b10279e commit f32f026
Show file tree
Hide file tree
Showing 17 changed files with 48 additions and 3 deletions.
2 changes: 2 additions & 0 deletions .gitignore
@@ -0,0 +1,2 @@
*swp
*gem
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
9 changes: 9 additions & 0 deletions lib/sass-mixins.rb
@@ -0,0 +1,9 @@
module SassMixins
module Rails
class Railtie < ::Rails::Railtie
rake_tasks do
load "tasks/install.rake"
end
end
end
end
9 changes: 9 additions & 0 deletions lib/tasks/install.rake
@@ -0,0 +1,9 @@
# Needed for pre-3.1.
namespace :sass_mixins do
desc "Move files to the Rails assets directory."
task :install do
source_root = File.expand_path(File.join(File.dirname(__FILE__), '..', '..'))
`mkdir #{Rails.root}/public/stylesheets/sass`
`cp -a #{source_root}/app/assets/* #{Rails.root}/public/stylesheets/sass`
end
end
12 changes: 9 additions & 3 deletions readme.md
Expand Up @@ -7,15 +7,21 @@ Sass 3.1+


##Install
**Clone the Repo**
**Update your Gemfile**

git clone git@github.com:plapier/sass-mixins.git
gem 'sass-mixins'

bundle install

**For Rails < 3.1 you must run the installation rake task. This will copy the
Sass files into your project's public/stylesheets/sass directory.**

rake sass_mixins:install

**Import the mixins at the beginning of your stylesheet**

@import 'sass-mixins/mixins';


##Usage
Below are a few examples of mixin usage. Note that these are just a few, explore the repo to find out more.

Expand Down
19 changes: 19 additions & 0 deletions sass-mixins.gemspec
@@ -0,0 +1,19 @@
Gem::Specification.new do |s|
s.name = 'sass-mixins'
s.version = '0.0.1'
s.summary = "Vanilla Sass Mixins using SCSS syntax."
s.description = <<-DESC
The purpose of Vanilla Sass Mixins is to provide a comprehensive framework of
sass mixins that are designed to be as vanilla as possible. Meaning they
should not deter from the original CSS syntax. The mixins contain vendor
specific prefixes for all CSS3 properties for support amongst modern
browsers. The prefixes also ensure graceful degradation for older browsers
that support only CSS3 prefixed properties.
DESC
s.authors = ["Phil LaPier", "Chad Mazzola", "Mike Burns"]
s.email = 'support@thoughtbot.com'
s.files = Dir['**/*']
s.homepage = 'https://github.com/thoughtbot/sass-mixins'

s.add_dependency('sass', '>= 3.1')
end

0 comments on commit f32f026

Please sign in to comment.