middleman-slim 0.1.2 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 9797498ef1f23c32c3d8df898cf03a611ea76862
4
- data.tar.gz: 4d919141b346d82a41dfad068f59a51b339360ee
3
+ metadata.gz: 63837fa8dc2f7233c9f30c433cc616b236583bfc
4
+ data.tar.gz: 79857195db72167bf1501cda4a9c1d20d1d42643
5
5
  SHA512:
6
- metadata.gz: 069dd9c3eb47093af5567fa717073ec9c1a4435222480be7894124029662da035447359bbe4c4579d154bb9fbd58145a5968771e75883b1a9ffe2c07178ebc58
7
- data.tar.gz: f698a14c36d8714e6bddff650db6a613cfc4989d3862d158aae9470f1805949d39483b8dd3245130c418494593c171b0a977c2e562907cef430991fa982ddc2d
6
+ metadata.gz: 46ee52bdf864a5131c53fd06b2f19bc0932aa2e4deeb84f7ed15c0cc2d7b858ca0236d8c9c25d9cba4e9073e8b0d5985d296a254c620672dfb82c305b588c1ec
7
+ data.tar.gz: 4ebf663e5ae08c4e7d6720875fc18b9266573753a6a7f318d1a7e24235facac196acf80b5225461f44c7c46467d1ac70a26325bc97dbd9384cec4ac5b60fa36d
@@ -1,15 +1,23 @@
1
1
  language: ruby
2
2
  rvm:
3
3
  - ruby-head
4
- - 2.1.1
5
- - 2.1.0
6
- - 2.0.0
7
- - 1.9.3
4
+ - jruby-head
8
5
  - jruby-19mode
6
+ - 2.2
7
+ - 2.1
8
+ - 2.0
9
+ - 1.9.3
10
+ os:
11
+ - linux
12
+ - osx
9
13
  matrix:
10
14
  fast_finish: true
11
15
  allow_failures:
12
16
  - rvm: ruby-head
13
17
  - rvm: jruby-19mode
18
+ - rvm: jruby-head
14
19
  script: bundle exec cucumber
15
20
  env: TEST=true
21
+ notifications:
22
+ webhooks:
23
+ - https://idobata.io/hook/792c4ace-c92f-44e3-b70b-b2584c40b800
@@ -1,4 +1,4 @@
1
- Copyright (c) 2013 yterajima
1
+ Copyright (c) 2013 Yuya Terajima
2
2
 
3
3
  MIT License
4
4
 
data/README.md CHANGED
@@ -3,18 +3,22 @@
3
3
  [![Gem Version](https://badge.fury.io/rb/middleman-slim.svg)][gem]
4
4
  [![Build Status](https://travis-ci.org/yterajima/middleman-slim.svg)][travis]
5
5
 
6
- middleman-slim is an extension for the Middleman static site generator that adds support for Slim.
6
+ middleman-slim is an template for Middleman. This template provides Default Template using Slim.
7
7
 
8
8
  ## Installation
9
9
 
10
- gem install middleman
11
- gem install middleman-slim
12
- middleman init PROJECT_NAME --template slim
10
+ ```
11
+ $ gem install middleman
12
+ $ gem install middleman-slim
13
+ $ middleman init PROJECT_NAME --template slim
14
+ ```
13
15
 
14
16
  ## Run
15
17
 
16
- cd PROJECT_NAME
17
- middleman server
18
+ ```
19
+ $ cd PROJECT_NAME
20
+ $ middleman server
21
+ ```
18
22
 
19
23
  ## Learn more
20
24
 
@@ -0,0 +1,28 @@
1
+ Feature: Middleman-Slim Build
2
+
3
+ Scenario: Build a new project
4
+ Given I run `middleman init MY_PROJECT --template slim`
5
+ And I cd to "MY_PROJECT"
6
+ When I run `middleman build`
7
+ Then the exit status should be 0
8
+ And the following files should exist:
9
+ | build/index.html |
10
+ | build/images/background.png |
11
+ | build/images/middleman.png |
12
+ | build/javascripts/all.js |
13
+ | build/stylesheets/all.css |
14
+ | build/stylesheets/normalize.css |
15
+ And the file "build/stylesheets/all.css" should contain "../images/"
16
+
17
+ Scenario: Build a new project with --images-dir option
18
+ Given I run `middleman init MY_PROJECT --template slim --images-dir img`
19
+ And I cd to "MY_PROJECT"
20
+ When I run `middleman build`
21
+ Then the exit status should be 0
22
+ And the following files should exist:
23
+ | build/img/background.png |
24
+ | build/img/middleman.png |
25
+ | build/stylesheets/all.css |
26
+ And the file "build/stylesheets/all.css" should contain "../img/"
27
+ And the file "build/stylesheets/all.css" should not contain "../images/"
28
+
@@ -2,7 +2,7 @@ Feature: Middleman-Slim CLI
2
2
 
3
3
  Scenario: Create a new project
4
4
  Given I run `middleman init MY_PROJECT --template slim`
5
- Then the exit status should be 0
5
+ And the exit status should be 0
6
6
  When I cd to "MY_PROJECT"
7
7
  Then the following files should exist:
8
8
  | Gemfile |
@@ -19,7 +19,7 @@ Feature: Middleman-Slim CLI
19
19
 
20
20
  Scenario: Create a new project with --images-dir option
21
21
  Given I run `middleman init MY_PROJECT --template slim --images-dir img`
22
- Then the exit status should be 0
22
+ And the exit status should be 0
23
23
  When I cd to "MY_PROJECT"
24
24
  Then the following files should exist:
25
25
  | source/img/background.png |
@@ -1,5 +1,4 @@
1
1
  require 'middleman-core'
2
-
3
2
  require 'middleman-slim/version'
4
3
  require 'middleman-slim/template'
5
4
 
@@ -39,9 +39,7 @@ module Middleman
39
39
 
40
40
  private
41
41
  def replace_images_dir
42
- if options[:images_dir] == 'images'
43
- return
44
- end
42
+ return if options[:images_dir] == 'images'
45
43
 
46
44
  open(File.join(location, 'source', options[:css_dir], 'all.css'), 'r+') {|f|
47
45
  f.flock(File::LOCK_EX)
@@ -55,5 +53,3 @@ module Middleman
55
53
  end
56
54
  end
57
55
  end
58
-
59
- Middleman::Templates.register :slim, Middleman::Slim::Template
@@ -1,15 +1,15 @@
1
- # If you have OpenSSL installed, we recommend updating
2
- # the following line to use "https"
3
- source 'http://rubygems.org'
1
+ # If you do not have OpenSSL installed, update
2
+ # the following line to use "http://" instead
3
+ source 'https://rubygems.org'
4
4
 
5
5
  gem "middleman", "~><%= Middleman::VERSION %>"
6
- gem "slim", "~> 2.0"
6
+ gem "slim", "=> 2.0"
7
7
 
8
8
  # Live-reloading plugin
9
9
  gem "middleman-livereload", "~> 3.1.0"
10
10
 
11
- # For faster file watcher updates on Windows:
11
+ # for faster file watcher updates on windows:
12
12
  gem "wdm", "~> 0.1.0", :platforms => [:mswin, :mingw]
13
13
 
14
- # Windows does not come with time zone data
14
+ # windows does not come with time zone data
15
15
  gem "tzinfo-data", platforms: [:mswin, :mingw]
@@ -1,3 +1,5 @@
1
+ require "slim"
2
+
1
3
  ###
2
4
  # Compass
3
5
  ###
@@ -47,31 +49,11 @@
47
49
  # end
48
50
  # end
49
51
 
50
- ###
51
- # Gem
52
- ###
53
- require 'slim'
54
-
55
- <% if options[:css_dir] -%>
56
- set :css_dir, '<%= options[:css_dir] -%>'
57
- <% else -%>
58
- # Change the CSS directory
59
- # set :css_dir, "alternative_css_directory"
60
- <% end -%>
61
-
62
- <% if options[:js_dir] -%>
63
- set :js_dir, '<%= options[:js_dir] -%>'
64
- <% else -%>
65
- # Change the JS directory
66
- # set :js_dir, "alternative_js_directory"
67
- <% end -%>
68
-
69
- <% if options[:images_dir] -%>
70
- set :images_dir, '<%= options[:images_dir] -%>'
71
- <% else -%>
72
- # Change the images directory
73
- # set :images_dir, "alternative_image_directory"
74
- <% end -%>
52
+ set :css_dir, 'stylesheets'
53
+
54
+ set :js_dir, 'javascripts'
55
+
56
+ set :images_dir, 'images'
75
57
 
76
58
  # Build-specific configuration
77
59
  configure :build do
@@ -7,7 +7,7 @@ html
7
7
  meta content="IE=edge,chrome=1" http-equiv="X-UA-Compatible"
8
8
 
9
9
  /! Use title if it's in the page YAML frontmatter
10
- title == data.page.title || "The Middleman"
10
+ title = data.page.title || "The Middleman"
11
11
 
12
12
  == stylesheet_link_tag "normalize", "all"
13
13
  == javascript_include_tag "all"
@@ -1,5 +1,5 @@
1
1
  module Middleman
2
2
  module Slim
3
- VERSION = "0.1.2"
3
+ VERSION = "0.2.0"
4
4
  end
5
5
  end
@@ -6,7 +6,7 @@ require 'middleman-slim/version'
6
6
  Gem::Specification.new do |spec|
7
7
  spec.name = "middleman-slim"
8
8
  spec.version = Middleman::Slim::VERSION
9
- spec.authors = ["yterajima"]
9
+ spec.authors = ["Yuya Terajima"]
10
10
  spec.email = ["terra@e2esound.com"]
11
11
  spec.description = %q{A Middleman template using Slim. You can use Slim as easy in Middleman Project}
12
12
  spec.summary = %q{A Middleman template using Slim.}
@@ -18,9 +18,9 @@ Gem::Specification.new do |spec|
18
18
  spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
19
  spec.require_paths = ["lib"]
20
20
 
21
- spec.add_runtime_dependency "slim", "~> 2.0"
22
- spec.add_runtime_dependency "middleman", "~>3.2"
21
+ spec.add_runtime_dependency "slim", ">= 2.0"
22
+ spec.add_runtime_dependency "middleman", ">= 3.2"
23
23
 
24
- spec.add_development_dependency "cucumber", "~> 1.3"
25
- spec.add_development_dependency "aruba", "~> 0.5"
24
+ spec.add_development_dependency "cucumber", ">= 1.3"
25
+ spec.add_development_dependency "aruba", ">= 0.6"
26
26
  end
metadata CHANGED
@@ -1,71 +1,71 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: middleman-slim
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
- - yterajima
7
+ - Yuya Terajima
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-04-21 00:00:00.000000000 Z
11
+ date: 2015-01-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: slim
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
19
  version: '2.0'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - "~>"
24
+ - - ">="
25
25
  - !ruby/object:Gem::Version
26
26
  version: '2.0'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: middleman
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - "~>"
31
+ - - ">="
32
32
  - !ruby/object:Gem::Version
33
33
  version: '3.2'
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - "~>"
38
+ - - ">="
39
39
  - !ruby/object:Gem::Version
40
40
  version: '3.2'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: cucumber
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - "~>"
45
+ - - ">="
46
46
  - !ruby/object:Gem::Version
47
47
  version: '1.3'
48
48
  type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - "~>"
52
+ - - ">="
53
53
  - !ruby/object:Gem::Version
54
54
  version: '1.3'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: aruba
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
- - - "~>"
59
+ - - ">="
60
60
  - !ruby/object:Gem::Version
61
- version: '0.5'
61
+ version: '0.6'
62
62
  type: :development
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
- - - "~>"
66
+ - - ">="
67
67
  - !ruby/object:Gem::Version
68
- version: '0.5'
68
+ version: '0.6'
69
69
  description: A Middleman template using Slim. You can use Slim as easy in Middleman
70
70
  Project
71
71
  email:
@@ -80,6 +80,7 @@ files:
80
80
  - LICENSE.txt
81
81
  - README.md
82
82
  - Rakefile
83
+ - features/build.feature
83
84
  - features/cli_init.feature
84
85
  - features/support/env.rb
85
86
  - lib/middleman-slim.rb
@@ -120,10 +121,11 @@ required_rubygems_version: !ruby/object:Gem::Requirement
120
121
  version: '0'
121
122
  requirements: []
122
123
  rubyforge_project:
123
- rubygems_version: 2.0.3
124
+ rubygems_version: 2.4.5
124
125
  signing_key:
125
126
  specification_version: 4
126
127
  summary: A Middleman template using Slim.
127
128
  test_files:
129
+ - features/build.feature
128
130
  - features/cli_init.feature
129
131
  - features/support/env.rb