styler-sass 0.1.2 → 0.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +5 -4
- data/Rakefile +7 -2
- data/bin/styler +6 -0
- data/lib/styler/engine.rb +1 -0
- data/lib/styler/generator.rb +16 -16
- data/lib/styler/version.rb +1 -1
- data/lib/styler.rb +2 -22
- data/lib/tasks/install.rake +1 -1
- metadata +2 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8768c92f6d978fd3850b95591fa544c91ccf68a6
|
4
|
+
data.tar.gz: ddeee8d33a990f59a741652d74e7b04e298cb6b3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 83d97d09095ff25979d0df4fe911f80300452ba7db7315a234380b48f8866dd0cb8f36d80785fbc85819b76b9fec2933db2e5dc23cebf56ecbce9554745bccf1
|
7
|
+
data.tar.gz: 681ab72b428c2fac2d731858c2a1f8182bb7508987662017177e723a5e0ab30a5204fa6996672f995fbfaa2dabde23388498e4ed16846818ce0a8fff4159db23
|
data/README.md
CHANGED
@@ -1,8 +1,8 @@
|
|
1
|
-
|
1
|
+
[](https://travis-ci.org/Alinuxfriend/Styler)
|
2
2
|
|
3
|
-
|
3
|
+
# Styler
|
4
4
|
|
5
|
-
|
5
|
+
This project help to have good of both world such as bootstrap-sass, bourbon, awesome-fonts, normalize in one single gem . Can use all bootstrap class and also bourbon mixins
|
6
6
|
|
7
7
|
## Installation
|
8
8
|
|
@@ -23,10 +23,11 @@ Or install it yourself as:
|
|
23
23
|
## Usage
|
24
24
|
|
25
25
|
Add This line to application.css.scss
|
26
|
+
``` css
|
26
27
|
@import "bourbon";
|
27
28
|
@import "normalize";
|
28
29
|
@import "bootstrap"
|
29
|
-
|
30
|
+
```
|
30
31
|
## Development
|
31
32
|
|
32
33
|
After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
|
data/Rakefile
CHANGED
@@ -1,6 +1,11 @@
|
|
1
|
-
|
1
|
+
# encoding: utf-8
|
2
|
+
require "rubygems"
|
3
|
+
require "bundler"
|
4
|
+
require "cucumber/rake/task"
|
2
5
|
require "rspec/core/rake_task"
|
3
6
|
|
7
|
+
Bundler::GemHelper.install_tasks
|
8
|
+
Cucumber::Rake::Task.new
|
4
9
|
RSpec::Core::RakeTask.new(:spec)
|
5
10
|
|
6
|
-
task :default => :spec
|
11
|
+
task :default => [:spec, :cucumber]
|
data/bin/styler
ADDED
data/lib/styler/engine.rb
CHANGED
data/lib/styler/generator.rb
CHANGED
@@ -6,45 +6,45 @@ module Styler
|
|
6
6
|
class Generator < Thor
|
7
7
|
map ['-v', '--version'] => :version
|
8
8
|
|
9
|
-
desc 'install', 'Install
|
9
|
+
desc 'install', 'Install styler into your project'
|
10
10
|
method_options :path => :string, :force => :boolean
|
11
11
|
def install
|
12
|
-
if
|
13
|
-
puts "
|
12
|
+
if styler_files_already_exist? && !options[:force]
|
13
|
+
puts "styler files already installed, doing nothing."
|
14
14
|
else
|
15
15
|
install_files
|
16
|
-
puts "
|
16
|
+
puts "styler files installed to #{install_path}/"
|
17
17
|
end
|
18
18
|
end
|
19
19
|
|
20
|
-
desc 'update', 'Update
|
20
|
+
desc 'update', 'Update styler'
|
21
21
|
method_options :path => :string
|
22
22
|
def update
|
23
|
-
if
|
24
|
-
|
23
|
+
if styler_files_already_exist?
|
24
|
+
remove_styler_directory
|
25
25
|
install_files
|
26
|
-
puts "
|
26
|
+
puts "styler files updated."
|
27
27
|
else
|
28
|
-
puts "No existing
|
28
|
+
puts "No existing styler installation. Doing nothing."
|
29
29
|
end
|
30
30
|
end
|
31
31
|
|
32
|
-
desc 'version', 'Show
|
32
|
+
desc 'version', 'Show styler version'
|
33
33
|
def version
|
34
|
-
say "
|
34
|
+
say "Styler #{styler::VERSION}"
|
35
35
|
end
|
36
36
|
|
37
37
|
private
|
38
38
|
|
39
|
-
def
|
39
|
+
def styler_files_already_exist?
|
40
40
|
install_path.exist?
|
41
41
|
end
|
42
42
|
|
43
43
|
def install_path
|
44
44
|
@install_path ||= if options[:path]
|
45
|
-
Pathname.new(File.join(options[:path], '
|
45
|
+
Pathname.new(File.join(options[:path], 'styler'))
|
46
46
|
else
|
47
|
-
Pathname.new('
|
47
|
+
Pathname.new('styler')
|
48
48
|
end
|
49
49
|
end
|
50
50
|
|
@@ -53,8 +53,8 @@ module Styler
|
|
53
53
|
copy_in_scss_files
|
54
54
|
end
|
55
55
|
|
56
|
-
def
|
57
|
-
FileUtils.rm_rf("
|
56
|
+
def remove_styler_directory
|
57
|
+
FileUtils.rm_rf("styler")
|
58
58
|
end
|
59
59
|
|
60
60
|
def make_install_directory
|
data/lib/styler/version.rb
CHANGED
data/lib/styler.rb
CHANGED
@@ -1,9 +1,8 @@
|
|
1
|
-
require "styler/version"
|
2
|
-
require "styler/generator"
|
3
|
-
|
4
1
|
dir = File.dirname(__FILE__)
|
5
2
|
$LOAD_PATH.unshift dir unless $LOAD_PATH.include?(dir)
|
6
3
|
|
4
|
+
require "styler/generator"
|
5
|
+
|
7
6
|
|
8
7
|
unless defined?(Sass)
|
9
8
|
require 'sass'
|
@@ -28,24 +27,5 @@ module Styler
|
|
28
27
|
ENV["SASS_PATH"] = [ENV["SASS_PATH"], bourbon_path].compact.join(File::PATH_SEPARATOR)
|
29
28
|
end
|
30
29
|
|
31
|
-
def gem_path
|
32
|
-
@gem_path ||= File.expand_path '..', File.dirname(__FILE__)
|
33
|
-
end
|
34
|
-
|
35
|
-
def stylesheets_path
|
36
|
-
File.join assets_path, 'stylesheets'
|
37
|
-
end
|
38
|
-
|
39
|
-
def fonts_path
|
40
|
-
File.join assets_path, 'fonts'
|
41
|
-
end
|
42
|
-
|
43
|
-
def javascripts_path
|
44
|
-
File.join assets_path, 'javascripts'
|
45
|
-
end
|
46
|
-
|
47
|
-
def assets_path
|
48
|
-
@assets_path ||= File.join gem_path, 'assets'
|
49
|
-
end
|
50
30
|
|
51
31
|
end
|
data/lib/tasks/install.rake
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: styler-sass
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alinuxfriend
|
@@ -336,6 +336,7 @@ files:
|
|
336
336
|
- app/assets/stylesheets/settings/_px-to-em.scss
|
337
337
|
- bin/console
|
338
338
|
- bin/setup
|
339
|
+
- bin/styler
|
339
340
|
- lib/styler.rb
|
340
341
|
- lib/styler/engine.rb
|
341
342
|
- lib/styler/generator.rb
|