octopress-autoprefixer 1.0.0

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 ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 04be8ba61e950be92f64ad5833a2ab32638284aa
4
+ data.tar.gz: de99c2fa13d1b5c305db82206e65827e2ca66f9c
5
+ SHA512:
6
+ metadata.gz: f97ff70a2b9ed6f9f136be21388e2c4a7153aebe2bf8e7f832cc67da66a5f5feae3f7a0202d63793456b0c7dbde1de384de2396ddc316b2e1b240f95676531fe
7
+ data.tar.gz: bb926cf988a5f93e7dfd508adddad52f8924addf7f25164891bf3fab808b2be00ecd1cf3d3be1304112a498f12f7054c191dc343baa55555b1205b4fe2aeab16
data/.gitignore ADDED
@@ -0,0 +1,19 @@
1
+ *.gem
2
+ *.rbc
3
+ .bundle
4
+ .config
5
+ .yardoc
6
+ Gemfile.lock
7
+ InstalledFiles
8
+ _yardoc
9
+ coverage
10
+ doc/
11
+ lib/bundler/man
12
+ pkg
13
+ rdoc
14
+ spec/reports
15
+ test/tmp
16
+ test/version_tmp
17
+ tmp
18
+ .DS_Store
19
+ _site
data/.travis.yml ADDED
@@ -0,0 +1,5 @@
1
+ language: ruby
2
+ rvm:
3
+ - 2.0.0
4
+ - 1.9.3
5
+ script: cd test && bundle exec clash
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in octopress-dateformat.gemspec
4
+ gemspec
data/LICENSE.txt ADDED
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2013 Brandon Mathis
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,63 @@
1
+ # Octopress Date Format
2
+
3
+ Automatically adds CSS vendor prefixes to CSS and Sass files in any Jekyll site. This plugin uses the
4
+ [Autoprefixer-rails](https://github.com/ai/autoprefixer-rails) gem.
5
+
6
+ [![Build Status](https://travis-ci.org/octopress/autoprefixer.svg)](https://travis-ci.org/octopress/autoprefixer)
7
+ [![Gem Version](http://img.shields.io/gem/v/octopress-autoprefixer.svg)](https://rubygems.org/gems/octopress-autoprefixer)
8
+ [![License](http://img.shields.io/:license-mit-blue.svg)](http://octopress.mit-license.org)
9
+
10
+ ## Installation
11
+
12
+ Add this line to your application's Gemfile:
13
+
14
+ gem 'octopress-autoprefixer'
15
+
16
+ And then execute:
17
+
18
+ $ bundle
19
+
20
+ Or install it yourself as:
21
+
22
+ $ gem install octopress-autoprefixer
23
+
24
+ Next add it to your gems list in Jekyll's `_config.yml`
25
+
26
+ gems:
27
+ - octopress-autoprefixer
28
+
29
+ **That's it**. Now all CSS files in your site will be automatically prefixed after every build.
30
+
31
+ ## Contributing
32
+
33
+ 1. Fork it ( https://github.com/octopress/autoprefixer/fork )
34
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
35
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
36
+ 4. Push to the branch (`git push origin my-new-feature`)
37
+ 5. Create new Pull Request
38
+
39
+
40
+ ## License
41
+
42
+ Copyright (c) 2013 Brandon Mathis
43
+
44
+ MIT License
45
+
46
+ Permission is hereby granted, free of charge, to any person obtaining
47
+ a copy of this software and associated documentation files (the
48
+ "Software"), to deal in the Software without restriction, including
49
+ without limitation the rights to use, copy, modify, merge, publish,
50
+ distribute, sublicense, and/or sell copies of the Software, and to
51
+ permit persons to whom the Software is furnished to do so, subject to
52
+ the following conditions:
53
+
54
+ The above copyright notice and this permission notice shall be
55
+ included in all copies or substantial portions of the Software.
56
+
57
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
58
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
59
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
60
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
61
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
62
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
63
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/Rakefile ADDED
@@ -0,0 +1 @@
1
+ require "bundler/gem_tasks"
@@ -0,0 +1,5 @@
1
+ module Octopress
2
+ class Autoprefixer
3
+ VERSION = "1.0.0"
4
+ end
5
+ end
@@ -0,0 +1,34 @@
1
+ require 'octopress-hooks'
2
+ require 'octopress-autoprefixer/version'
3
+ require 'autoprefixer-rails'
4
+ require 'find'
5
+
6
+ module Octopress
7
+ module AutoPrefixer
8
+ class SiteHooks < Hooks::Site
9
+ @priority = :low
10
+
11
+ def post_write(site)
12
+ AutoPrefixer.process(site)
13
+ end
14
+ end
15
+
16
+ def self.find_stylesheets(dir)
17
+ return [] unless Dir.exist? dir
18
+ Find.find(dir).to_a.reject {|f| File.extname(f) != '.css' }
19
+ end
20
+
21
+ def self.process(site)
22
+ find_stylesheets(site.config['destination']).each do |file|
23
+ prefix(file)
24
+ end
25
+ end
26
+
27
+ def self.prefix(stylesheet)
28
+ content = File.open(stylesheet).read
29
+ File.open(stylesheet, 'w') do |f|
30
+ f.write(AutoprefixerRails.process(content))
31
+ end
32
+ end
33
+ end
34
+ end
@@ -0,0 +1,25 @@
1
+ # -*- encoding: utf-8 -*-
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'octopress-autoprefixer/version'
5
+
6
+ Gem::Specification.new do |gem|
7
+ gem.name = "octopress-autoprefixer"
8
+ gem.version = Octopress::Autoprefixer::VERSION
9
+ gem.authors = ["Brandon Mathis"]
10
+ gem.email = ["brandon@imathis.com"]
11
+ gem.description = %q{Automatically adds CSS vender prefixes for all CSS and Sass files in any Jekyll blog}
12
+ gem.summary = %q{Automatically adds CSS vender prefixes for all CSS and Sass files in any Jekyll blog}
13
+ gem.homepage = "https://github.com/octopress/autoprefixer"
14
+ gem.license = "MIT"
15
+
16
+ gem.add_runtime_dependency 'octopress-hooks', '~> 2.0'
17
+ gem.add_runtime_dependency "autoprefixer-rails", "~> 2.2"
18
+ gem.add_runtime_dependency 'jekyll', '~> 2.0'
19
+
20
+ gem.add_development_dependency 'clash', '~> 1.0'
21
+ gem.add_development_dependency 'pry-debugger'
22
+
23
+ gem.files = `git ls-files`.split($/)
24
+ gem.require_paths = ["lib"]
25
+ end
data/test/.clash.yml ADDED
@@ -0,0 +1,2 @@
1
+ build: true
2
+ compare: _expected _site
data/test/.gitignore ADDED
@@ -0,0 +1 @@
1
+ _site
data/test/Gemfile ADDED
@@ -0,0 +1,3 @@
1
+ source 'https://rubygems.org'
2
+
3
+ gemspec :path => '/gemspec/path', :path => '../'
data/test/_config.yml ADDED
@@ -0,0 +1,7 @@
1
+ name: Your New Jekyll Site
2
+ markdown: redcarpet
3
+ timezone: UTC
4
+ gems:
5
+ - octopress-autoprefixer
6
+ exclude:
7
+ - Gemfile*
@@ -0,0 +1,4 @@
1
+ body {
2
+ -webkit-box-shadow: #000 0px 0px 3px inset;
3
+ box-shadow: #000 0px 0px 3px inset;
4
+ }
@@ -0,0 +1,4 @@
1
+ body article {
2
+ background-image: -webkit-gradient(linear, left top, left bottom, from(white), to(#eeeeee));
3
+ background-image: -webkit-linear-gradient(white, #eeeeee);
4
+ background-image: linear-gradient(white, #eeeeee); }
data/test/test.css ADDED
@@ -0,0 +1,3 @@
1
+ body {
2
+ box-shadow: #000 0px 0px 3px inset;
3
+ }
data/test/test2.scss ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ ---
3
+ body {
4
+ article {
5
+ background-image: linear-gradient(#fff, #eee)
6
+ }
7
+ }
metadata ADDED
@@ -0,0 +1,133 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: octopress-autoprefixer
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.0.0
5
+ platform: ruby
6
+ authors:
7
+ - Brandon Mathis
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2014-08-03 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: octopress-hooks
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '2.0'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '2.0'
27
+ - !ruby/object:Gem::Dependency
28
+ name: autoprefixer-rails
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '2.2'
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '2.2'
41
+ - !ruby/object:Gem::Dependency
42
+ name: jekyll
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '2.0'
48
+ type: :runtime
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '2.0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: clash
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - "~>"
60
+ - !ruby/object:Gem::Version
61
+ version: '1.0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - "~>"
67
+ - !ruby/object:Gem::Version
68
+ version: '1.0'
69
+ - !ruby/object:Gem::Dependency
70
+ name: pry-debugger
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - ">="
74
+ - !ruby/object:Gem::Version
75
+ version: '0'
76
+ type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - ">="
81
+ - !ruby/object:Gem::Version
82
+ version: '0'
83
+ description: Automatically adds CSS vender prefixes for all CSS and Sass files in
84
+ any Jekyll blog
85
+ email:
86
+ - brandon@imathis.com
87
+ executables: []
88
+ extensions: []
89
+ extra_rdoc_files: []
90
+ files:
91
+ - ".gitignore"
92
+ - ".travis.yml"
93
+ - Gemfile
94
+ - LICENSE.txt
95
+ - README.md
96
+ - Rakefile
97
+ - lib/octopress-autoprefixer.rb
98
+ - lib/octopress-autoprefixer/version.rb
99
+ - octopress-autoprefixer.gemspec
100
+ - test/.clash.yml
101
+ - test/.gitignore
102
+ - test/Gemfile
103
+ - test/_config.yml
104
+ - test/_expected/test.css
105
+ - test/_expected/test2.css
106
+ - test/test.css
107
+ - test/test2.scss
108
+ homepage: https://github.com/octopress/autoprefixer
109
+ licenses:
110
+ - MIT
111
+ metadata: {}
112
+ post_install_message:
113
+ rdoc_options: []
114
+ require_paths:
115
+ - lib
116
+ required_ruby_version: !ruby/object:Gem::Requirement
117
+ requirements:
118
+ - - ">="
119
+ - !ruby/object:Gem::Version
120
+ version: '0'
121
+ required_rubygems_version: !ruby/object:Gem::Requirement
122
+ requirements:
123
+ - - ">="
124
+ - !ruby/object:Gem::Version
125
+ version: '0'
126
+ requirements: []
127
+ rubyforge_project:
128
+ rubygems_version: 2.2.2
129
+ signing_key:
130
+ specification_version: 4
131
+ summary: Automatically adds CSS vender prefixes for all CSS and Sass files in any
132
+ Jekyll blog
133
+ test_files: []