middleman-favicon-maker 4.0.4 → 4.0.5

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: bdd17eda9ebc8d109239cf2172ce13406c06820a
4
- data.tar.gz: 49e20768684dc519ef933d2451243150c8ab1c65
3
+ metadata.gz: 57b0433e183c68686843e2d41299fdbe27cdb378
4
+ data.tar.gz: 40bc39f57dc5b71b30513e703b28ac84c1777e13
5
5
  SHA512:
6
- metadata.gz: 8f54f65fcef504219386f85c7c457193a577c2fa120485d8ca8b9e8fd544c206e0449ba5cc2ea0bc488af89a0e6c4367ebe273f32835cbd440fbd9946789e46d
7
- data.tar.gz: 4fba82f60b3b28acaeb9c30ad49d8ac0e7bc0013eace1fdf774e0f4ff2113c89cf60c53ab5a53b46a8ebae93cceb1154f39ff505857383cd0bb72a9535542caf
6
+ metadata.gz: 2f3d2a2d8436950b1dd5f0f1013c28d5ab01c666bcfda9c7135f901cf78b1ebd48692224aa4f4e517466ce88daed06da783263bfb0e032d627ea488df29e8168
7
+ data.tar.gz: ccca9560b23183d8770473189cd2595ce19fb498789072baf4262590300b416a389e7ab96aef61c01e1ab8a8e9df0d0ad7e472da34fc17828f4e35aa47b371c5
data/README.md CHANGED
@@ -1,4 +1,5 @@
1
1
  # middleman-favicon-maker
2
+
2
3
  [![Gem Version](https://badge.fury.io/rb/middleman-favicon-maker.svg)](http://badge.fury.io/rb/middleman-favicon-maker)
3
4
  [![Code Climate](https://codeclimate.com/github/follmann/middleman-favicon-maker.png)](https://codeclimate.com/github/follmann/middleman-favicon-maker)
4
5
 
@@ -8,28 +9,31 @@
8
9
 
9
10
  ### Dependencies
10
11
 
11
- Before you can use FaviconMaker, you need to install [ImageMagick](http://www.imagemagick.org/script/index.php). On OS X, the easiest way to do this is to run:
12
+ Before you can use FaviconMaker, you need to install [ImageMagick](http://www.imagemagick.org/script/index.php). On macOS, the easiest way to do this is to run:
12
13
 
13
- ``` shell
14
+ ```shell
14
15
  brew install imagemagick
15
16
  ```
16
17
 
17
18
  ### Using Bundler
18
19
 
19
- ``` ruby
20
+ ```ruby
20
21
  gem "middleman-favicon-maker", "~> 4.0"
21
22
  ```
22
23
 
23
24
  If you're using Middleman version 2.x, use version 0.0.6 of middleman-favicon-maker.
24
25
 
25
26
  ## Integrating with Middleman
27
+
26
28
  ### Templates
29
+
27
30
  Create an image e.g. named `_favicon_template.png` and place it in your source directory. The leading underscore prevents it from being copied into the build directory. Ideally, this image's dimensions would be 152 x 152 or have multiple templates for different ranges (small, medium, big). In your config.rb, extend the `configure :build` block. The image formats used for templates should be either PNG or SVG (since v3.6).
28
31
 
29
32
  ### Simple config
33
+
30
34
  This config assumes that a PNG file named `_favicon_template.png` lives in the source folder. The generated icons are stored in the build folder root.
31
35
 
32
- ``` ruby
36
+ ```ruby
33
37
  configure :build do
34
38
  ...
35
39
  activate :favicon_maker, :icons => {
@@ -44,9 +48,10 @@ end
44
48
  ```
45
49
 
46
50
  ### Advanced config
51
+
47
52
  Using all configuration options. The `template_dir` and `output_dir` point to source and build dir if not set, you can use absolute or relative paths. You can use multiple template files that suit the different resolutions better. `format` and `size` are optional and only required when the size of the icon and/or the file format is not encoded in the filename. Multiple resolutions in one file is only supported for the .ico format.
48
53
 
49
- ``` ruby
54
+ ```ruby
50
55
  configure :build do
51
56
  ...
52
57
  activate :favicon_maker do |f|
@@ -69,9 +74,10 @@ end
69
74
  ```
70
75
 
71
76
  ### List of icons you might be interested in
77
+
72
78
  This is a moving target. Feel free to extend it and submit the change.
73
79
 
74
- ``` ruby
80
+ ```ruby
75
81
  [
76
82
  { icon: "apple-touch-icon-180x180-precomposed.png" }, # Same as apple-touch-icon-57x57.png, for iPhone 6 Plus with @3× display
77
83
  { icon: "apple-touch-icon-152x152-precomposed.png" }, # Same as apple-touch-icon-57x57.png, for retina iPad with iOS7.
@@ -105,30 +111,45 @@ Specifying meta links is only necessary if you want to support non-iOS devices.
105
111
 
106
112
  ### HTML
107
113
 
108
- ``` html
109
- <link rel="apple-touch-icon-precomposed" sizes="180x180" href="apple-touch-icon-180x180-precomposed.png" />
110
- <link rel="apple-touch-icon-precomposed" sizes="152x152" href="apple-touch-icon-152x152-precomposed.png" />
111
- <link rel="apple-touch-icon-precomposed" sizes="144x144" href="apple-touch-icon-144x144-precomposed.png" />
112
- <link rel="apple-touch-icon-precomposed" sizes="114x114" href="apple-touch-icon-114x114-precomposed.png" />
113
- <link rel="apple-touch-icon-precomposed" sizes="72x72" href="apple-touch-icon-72x72-precomposed.png" />
114
- <link rel="apple-touch-icon-precomposed" href="apple-touch-icon-precomposed.png" />
115
- <link rel="shortcut icon" href="favicon.png" />
116
- <link rel="icon" type="image/ico" href="favicon.ico" />
114
+ ```html
115
+ <link rel="apple-touch-icon" sizes="180x180" href="apple-touch-icon-180x180-precomposed.png">
116
+ <link rel="apple-touch-icon" sizes="152x152" href="apple-touch-icon-152x152-precomposed.png">
117
+ <link rel="apple-touch-icon" sizes="144x144" href="apple-touch-icon-144x144-precomposed.png">
118
+ <link rel="apple-touch-icon" sizes="114x114" href="apple-touch-icon-114x114-precomposed.png">
119
+ <link rel="apple-touch-icon" sizes="72x72" href="apple-touch-icon-72x72-precomposed.png">
120
+ <link rel="apple-touch-icon" href="apple-touch-icon-precomposed.png">
121
+ <link rel="shortcut icon" href="favicon.png">
122
+ <link rel="icon" type="image/ico" href="favicon.ico">
123
+ ```
124
+
125
+ ### Haml
126
+
127
+ ```haml
128
+ %link{rel: "apple-touch-icon", sizes: "180x180", href: "apple-touch-icon-180x180-precomposed.png"}
129
+ %link{rel: "apple-touch-icon", sizes: "152x152", href: "apple-touch-icon-152x152-precomposed.png"}
130
+ %link{rel: "apple-touch-icon", sizes: "144x144", href: "apple-touch-icon-144x144-precomposed.png"}
131
+ %link{rel: "apple-touch-icon", sizes: "114x114", href: "apple-touch-icon-114x114-precomposed.png"}
132
+ %link{rel: "apple-touch-icon", sizes: "72x72", href: "apple-touch-icon-72x72-precomposed.png"}
133
+ %link{rel: "apple-touch-icon", href: "apple-touch-icon-precomposed.png"}
134
+ %link{rel: "shortcut icon", href: "favicon.png"}
135
+ %link{rel: "icon", type: "image/ico", href: "favicon.ico"}
117
136
  ```
118
137
 
119
- ### HAML
120
-
121
- ``` haml
122
- %link{ rel: "apple-touch-icon", sizes: "180x180", href: "apple-touch-icon-180x180-precomposed.png" }
123
- %link{ rel: "apple-touch-icon", sizes: "152x152", href: "apple-touch-icon-152x152-precomposed.png" }
124
- %link{ rel: "apple-touch-icon", sizes: "144x144", href: "apple-touch-icon-144x144-precomposed.png" }
125
- %link{ rel: "apple-touch-icon", sizes: "114x114", href: "apple-touch-icon-114x114-precomposed.png" }
126
- %link{ rel: "apple-touch-icon", sizes: "72x72", href: "apple-touch-icon-72x72-precomposed.png" }
127
- %link{ rel: "apple-touch-icon", href: "apple-touch-icon-precomposed.png" }
128
- %link{ rel: "shortcut icon", href: "favicon.png" }
129
- %link{ rel: "icon", type: "image/ico", href: "favicon.ico" }
138
+ ### Slim
139
+
140
+ ```slim
141
+ link href="apple-touch-icon-180x180-precomposed.png" rel="apple-touch-icon" sizes="180x180" /
142
+ link href="apple-touch-icon-152x152-precomposed.png" rel="apple-touch-icon" sizes="152x152" /
143
+ link href="apple-touch-icon-144x144-precomposed.png" rel="apple-touch-icon" sizes="144x144" /
144
+ link href="apple-touch-icon-114x114-precomposed.png" rel="apple-touch-icon" sizes="114x114" /
145
+ link href="apple-touch-icon-72x72-precomposed.png" rel="apple-touch-icon" sizes="72x72" /
146
+ link href="apple-touch-icon-precomposed.png" rel="apple-touch-icon" /
147
+ link href="favicon.png" rel=("shortcut icon") /
148
+ link href="favicon.ico" rel="icon" type="image/ico" /
130
149
  ```
150
+
131
151
  ## Contributing
152
+
132
153
  1. Fork it
133
154
  2. Create your feature branch (`git checkout -b my-new-feature`)
134
155
  3. Commit your changes (`git commit -am 'Add some feature'`)
@@ -51,7 +51,7 @@ module Middleman
51
51
  ::Middleman::Sitemap::Resource.new(
52
52
  app.sitemap,
53
53
  item[:icon],
54
- File.join(options[:template_dir], src)
54
+ File.join(app.root, options[:template_dir], src)
55
55
  )
56
56
  end
57
57
  end
@@ -2,7 +2,7 @@ module Middleman
2
2
  module FaviconMaker
3
3
  MAJOR = 4
4
4
  MINOR = 0
5
- PATCH = 4
5
+ PATCH = 5
6
6
  BUILD = nil
7
7
 
8
8
  VERSION = [MAJOR, MINOR, PATCH, BUILD].compact.join('.')
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: middleman-favicon-maker
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.4
4
+ version: 4.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andreas Follmann
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-07-15 00:00:00.000000000 Z
11
+ date: 2017-08-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: middleman-core