middlemac 3.0.1 → 3.1.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 7317b985a597b76832c31022f3b9fe89ed88e59b
4
- data.tar.gz: 20edec01a9b12076dcef9149994305a015c835b4
2
+ SHA256:
3
+ metadata.gz: 577f3591f5f815b959d9a272ea275cbaa18b19996c4234312fcb177aa3b56df0
4
+ data.tar.gz: 4c6765e7f1d9a70043301616d7245deb167c1e87de787b8cd3e830298a112efe
5
5
  SHA512:
6
- metadata.gz: 139c7f24a3c4da6f58a8dc8ea5bd5ab726ea94dd646b868e690d098b11cf9af35957bccfccae6acf753bee26db227751439b5d8c2d42c06956589a3cb42f0af5
7
- data.tar.gz: cffd0b71199a96fa1df3d329c2f05f0eb841d2bfa7adf4d4aceec587784e5a1de5b3e6e6656509d5068a32bb3cb5ad57c1f497488637c443444b6b67d9eaddad
6
+ metadata.gz: 780edeb0005d4a5ce14210306b63b297518ba471c0904510260722de7155f1e0ec54141ab3cc310c1592b3da217377efec6bd71f5e9aa2610bf115769d7e2076
7
+ data.tar.gz: 8d1856e6b75850ca86e7bab12cb702e93f5af2536384798e1a5d656800c46813b5efee6c1d53f2506ba9c93da380ec6a36870eae389b64fd9c5975f9cbc8a741
@@ -0,0 +1,5 @@
1
+ *.html linguist-documentation
2
+ *.css linguist-documentation
3
+ *.erb linguist-documentation
4
+ *.js linguist-documentation
5
+ documentation_project/ linguist-documentation
@@ -1,12 +1,26 @@
1
1
  middlemac change log
2
2
  ====================
3
3
 
4
+ - Version 3.1.0 / 2019-October-11
5
+
6
+ - Version 3.1.0
7
+ - Introduce a couple of new options in order to influence the file name of the
8
+ help book.
9
+ - Added .gitattributes for proper language reporting in GitHub.
10
+ No version bump.
11
+ No new gem.
12
+
4
13
  - Version 3.0.1 / 2019-September-08
5
14
 
6
- - Updated documentation.
7
- - Added redirect files, and updated tests.
8
- - Fix YAML parsing issue for picky parsers.
9
- - Version bump.
15
+ - Bump to 3.0.1:
16
+ - Fix YAML parsing issue for picky parsers.
17
+ - Added redirect files, to avoid recent macOS issue where /Resources/index.html
18
+ and the language.lproj/index.html files would confuse help viewer.
19
+ - Updated tests
20
+ - Updated documentation in the documentation project.
21
+
22
+ - Version 3.0.0 / 2018-June-18
23
+
10
24
  - All new Middlemac 3.0.
11
25
  - Git Commit Issues Fix
12
26
  - Ensure that build.sh is captured in version control.
@@ -44,3 +58,4 @@ middlemac change log
44
58
  - README, getting started.
45
59
  - Overhaul of helpers and sitemap manipulators complete.
46
60
  - BRETHREN checkpoint
61
+ - Continued refactoring resources.
@@ -5,9 +5,53 @@
5
5
  <div id="instance_attr_details" class="attr_details">
6
6
 
7
7
 
8
- <span id="options[:help_output_location]=-instance_method"></span>
8
+ <span id="options[:help_output_avoid_spaces]=-instance_method"></span>
9
9
  <div class="method_details first">
10
- <h3 class="signature first" id="options[:help_output_location]=-instance_method">
10
+ <h3 class="signature first" id="options[:help_output_avoid_spaces]=-instance_method">
11
+
12
+ #<strong>options[:help_output_avoid_spaces]=</strong>(value) &#x21d2; <tt>Boolean</tt>
13
+
14
+
15
+
16
+
17
+
18
+ </h3><div class="docstring">
19
+ <div class="discussion">
20
+ <p>Indicates whethr or not the <code>help_output_location</code> includes spaces in its
21
+ filename or not. Some GNU tools, such as make, choke on spaces. The default
22
+ setting for this option is <em>yes</em> in order to maintain backward
23
+ compatibility.</p>
24
+
25
+
26
+ </div>
27
+ </div>
28
+ <div class="tags">
29
+
30
+ <p class="tag_title">Returns:</p>
31
+ <ul class="return">
32
+
33
+ <li>
34
+
35
+
36
+ <span class='type'>(<tt>Boolean</tt>)</span>
37
+
38
+
39
+
40
+ &mdash;
41
+ <div class='inline'><p><code>true</code> or <code>false</code> to enable or disable this behavior.</p>
42
+ </div>
43
+
44
+ </li>
45
+
46
+ </ul>
47
+
48
+ </div>
49
+ </div>
50
+
51
+
52
+ <span id="options[:help_output_location]=-instance_method"></span>
53
+ <div class="method_details ">
54
+ <h3 class="signature " id="options[:help_output_location]=-instance_method">
11
55
 
12
56
  #<strong>options[:help_output_location]=</strong>(value) &#x21d2; <tt>String</tt>
13
57
 
@@ -49,6 +93,52 @@ built.</p>
49
93
 
50
94
  </ul>
51
95
 
96
+ </div>
97
+ </div>
98
+
99
+
100
+ <span id="options[:help_output_use_target]=-instance_method"></span>
101
+ <div class="method_details ">
102
+ <h3 class="signature " id="options[:help_output_use_target]=-instance_method">
103
+
104
+ #<strong>options[:help_output_use_target]=</strong>(value) &#x21d2; <tt>Boolean</tt>
105
+
106
+
107
+
108
+
109
+
110
+ </h3><div class="docstring">
111
+ <div class="discussion">
112
+ <p>Indicates whether or not the <code>help_output_location</code> includes the <code>(target)</code>
113
+ prefix in the help book bundle name. The default, <code>true</code>, will result in
114
+ <code>#{CFBundleName} (target).help</code>, which is the historical behavior. Setting
115
+ this to <code>false</code> will result in a help book named <code>#{CFBundleName}.help</code>,
116
+ instead. This can be useful if you are building help books from scripts via
117
+ XCode, and you set <code>help_output_location</code> to <code>ENV['BUILT_PRODUCTS_DIR']</code>.</p>
118
+
119
+
120
+ </div>
121
+ </div>
122
+ <div class="tags">
123
+
124
+ <p class="tag_title">Returns:</p>
125
+ <ul class="return">
126
+
127
+ <li>
128
+
129
+
130
+ <span class='type'>(<tt>Boolean</tt>)</span>
131
+
132
+
133
+
134
+ &mdash;
135
+ <div class='inline'><p><code>true</code> or <code>false</code> to enable or disable this behavior.</p>
136
+ </div>
137
+
138
+ </li>
139
+
140
+ </ul>
141
+
52
142
  </div>
53
143
  </div>
54
144
 
@@ -143,7 +143,7 @@ config[:targets] = {
143
143
  :HPDBookIconPath => 'SharedGlobalArt/free-icon_32x32@2x.png',
144
144
  :CFBundleName => 'Middlemac',
145
145
  :ProductName => 'Middlemac',
146
- :ProductVersion => '3.0.0.wip',
146
+ :ProductVersion => '3.1.0',
147
147
  :ProductURI => 'http://www.balthisar.com/developer',
148
148
  :ProductCopyright => '© 2018 Jim Derry. All rights reserved.',
149
149
  :features =>
@@ -161,7 +161,7 @@ config[:targets] = {
161
161
  :HPDBookIconPath => 'SharedGlobalArt/pro-icon_32x32@2x.png',
162
162
  :CFBundleName => 'Middlemac',
163
163
  :ProductName => 'Middlemac Pro',
164
- :ProductVersion => '3.0.0.wip',
164
+ :ProductVersion => '3.1.0',
165
165
  :ProductURI => 'http://www.balthisar.com/developer',
166
166
  :ProductCopyright => '© 2018 Jim Derry. All rights reserved.',
167
167
  :features =>
@@ -39,7 +39,7 @@ of _Middlemac_ do not pretend to override.
39
39
 
40
40
  ### The MIT License (MIT)
41
41
 
42
- Copyright (c) 2014-2018 Jim Derry and balthisar.com
42
+ Copyright (c) 2014-2019 Jim Derry and balthisar.com
43
43
 
44
44
  Permission is hereby granted, free of charge, to any person obtaining a copy of
45
45
  this software and associated documentation files (the "Software"), to deal in
@@ -17,7 +17,7 @@ source 'https://rubygems.org'
17
17
  #######################################
18
18
  # Middlemac, natch.
19
19
  #######################################
20
- gem 'middlemac', '~> 3.0.1'
20
+ gem 'middlemac', '~> 3.1.0'
21
21
  gem 'middleman-targets', '~> 1.0.12'
22
22
 
23
23
 
@@ -94,9 +94,9 @@ config[:targets] = {
94
94
  :HPDBookIconPath => 'SharedGlobalArt/free-icon_32x32@2x.png',
95
95
  :CFBundleName => 'Middlemac',
96
96
  :ProductName => 'Middlemac',
97
- :ProductVersion => version_app || '3.0.0',
97
+ :ProductVersion => version_app || '3.1.0',
98
98
  :ProductURI => 'http://www.balthisar.com/developer',
99
- :ProductCopyright => '© 2018 Jim Derry. All rights reserved.',
99
+ :ProductCopyright => '© 2019 Jim Derry. All rights reserved.',
100
100
  :features =>
101
101
  {
102
102
  :feature_advertise_pro => true,
@@ -112,9 +112,9 @@ config[:targets] = {
112
112
  :HPDBookIconPath => 'SharedGlobalArt/pro-icon_32x32@2x.png',
113
113
  :CFBundleName => 'Middlemac',
114
114
  :ProductName => 'Middlemac Pro',
115
- :ProductVersion => version_app || '3.0.0',
115
+ :ProductVersion => version_app || '3.1.0',
116
116
  :ProductURI => 'http://www.balthisar.com/developer',
117
- :ProductCopyright => '© 2018 Jim Derry. All rights reserved.',
117
+ :ProductCopyright => '© 2019 Jim Derry. All rights reserved.',
118
118
  :features =>
119
119
  {
120
120
  :feature_advertise_pro => false,
@@ -152,6 +152,20 @@ activate :Middlemac do |options|
152
152
  # is always up to date.
153
153
  options.help_output_location = nil
154
154
 
155
+ # Indicates whether or not spaces should be avoided in the name of the help
156
+ # bundle. The default value for backwards compatibility is `true` because
157
+ # some tools, such a make, don't like spaces.
158
+ options.help_output_avoid_spaces = true
159
+
160
+ # Indicates whether or not the `help_output_location` includes the `(target)`
161
+ # prefix in the help book bundle name. The default, `true`, will result in
162
+ # `#{CFBundleName} (target).help`, which is the historical behavior. Setting
163
+ # this to `false` will result in a help book named `#{CFBundleName}.help`,
164
+ # instead. This can be useful if you are building help books from scripts via
165
+ # XCode, and you set `help_output_location` to `ENV['BUILT_PRODUCTS_DIR']`.
166
+ # @return [Boolean] `true` or `false` to enable or disable this behavior.
167
+ options.help_output_use_target = true
168
+
155
169
  # If set to true, then the enhanced image_tag helper will be used
156
170
  # to include @2x, @3x, and @4x srcset automatically, if the image assets
157
171
  # exist.
@@ -42,7 +42,7 @@ Feature: Middlemac produces plist and strings files, uses correct HTML formats,
42
42
  And the file "testing_world_file.html" should contain "com.sample.project.pro.help"
43
43
  And the file "testing_world_file.html" should contain "New Project"
44
44
  And the file "testing_world_file.html" should contain "New Project Pro"
45
- And the file "testing_world_file.html" should contain "3.0.1"
45
+ And the file "testing_world_file.html" should contain "3.1.0"
46
46
  And the file "testing_world_file.html" should contain "http://www.sample.com"
47
47
  And the file "testing_world_file.html" should contain "_new_style_partial"
48
48
  And the file "testing_world_file.html" should contain "_partials_dir_partial"
@@ -17,7 +17,7 @@ source 'https://rubygems.org'
17
17
  #######################################
18
18
  # Middlemac, natch.
19
19
  #######################################
20
- gem 'middlemac', '~> 3.0.1'
20
+ gem 'middlemac', '~> 3.1.0'
21
21
  gem 'middleman-targets', '~> 1.0.12'
22
22
 
23
23
 
@@ -94,7 +94,7 @@ config[:targets] = {
94
94
  :HPDBookIconPath => nil,
95
95
  :CFBundleName => 'New Project',
96
96
  :ProductName => 'New Project',
97
- :ProductVersion => version_app || '3.0.1',
97
+ :ProductVersion => version_app || '3.1.0',
98
98
  :ProductURI => 'http://www.sample.com',
99
99
  :ProductCopyright => '© 2018 Jim Derry. All rights reserved.',
100
100
  :features =>
@@ -112,7 +112,7 @@ config[:targets] = {
112
112
  :HPDBookIconPath => nil,
113
113
  :CFBundleName => 'New Project',
114
114
  :ProductName => 'New Project Pro',
115
- :ProductVersion => version_app || '3.0.1',
115
+ :ProductVersion => version_app || '3.1.0',
116
116
  :ProductURI => 'http://www.sample.com',
117
117
  :ProductCopyright => '© 2018 Jim Derry. All rights reserved.',
118
118
  :features =>
@@ -152,6 +152,20 @@ activate :Middlemac do |options|
152
152
  # is always up to date.
153
153
  options.help_output_location = nil
154
154
 
155
+ # Indicates whether or not spaces should be avoided in the name of the help
156
+ # bundle. The default value for backwards compatibility is `true` because
157
+ # some tools, such a make, don't like spaces.
158
+ options.help_output_avoid_spaces = true
159
+
160
+ # Indicates whether or not the `help_output_location` includes the `(target)`
161
+ # prefix in the help book bundle name. The default, `true`, will result in
162
+ # `#{CFBundleName} (target).help`, which is the historical behavior. Setting
163
+ # this to `false` will result in a help book named `#{CFBundleName}.help`,
164
+ # instead. This can be useful if you are building help books from scripts via
165
+ # XCode, and you set `help_output_location` to `ENV['BUILT_PRODUCTS_DIR']`.
166
+ # @return [Boolean] `true` or `false` to enable or disable this behavior.
167
+ options.help_output_use_target = true
168
+
155
169
  # If set to true, then the enhanced image_tag helper will be used
156
170
  # to include @2x, @3x, and @4x srcset automatically, if the image assets
157
171
  # exist.
@@ -53,6 +53,8 @@ class Middlemac < ::Middleman::Extension
53
53
  # as extension options.
54
54
  ############################################################
55
55
  option :help_output_location, nil, 'Directory to place the built helpbook.'
56
+ option :help_output_avoid_spaces, true, 'If true, spaces in the help book file name bundle will be replaced with underscores.'
57
+ option :help_output_use_target, true, 'If false, the help book will not include (target) in its bundle name.'
56
58
  option :img_auto_extensions, %w(.svg .png .jpg .jpeg .gif .tiff .tif), 'If not empty, then `image_tag` will work without filename extensions.'
57
59
  option :retina_srcset, true, 'If true then the image_tag helper will be extended to include automatic @2x images.'
58
60
  option :show_debug, false, 'If true, the main layout will show some debug information and site contents.'
@@ -72,6 +74,22 @@ class Middlemac < ::Middleman::Extension
72
74
  # Xcode project is automatically up to date every time a help project is
73
75
  # built.
74
76
  # @return [String] The directory where the final help bundle will be built.
77
+
78
+ # @!attribute [rw] options[:help_output_avoid_spaces]=
79
+ # Indicates whethr or not the `help_output_location` includes spaces in its
80
+ # filename or not. Some GNU tools, such as make, choke on spaces. The default
81
+ # setting for this option is *yes* in order to maintain backward
82
+ # compatibility.
83
+ # @return [Boolean] `true` or `false` to enable or disable this behavior.
84
+
85
+ # @!attribute [rw] options[:help_output_use_target]=
86
+ # Indicates whether or not the `help_output_location` includes the `(target)`
87
+ # prefix in the help book bundle name. The default, `true`, will result in
88
+ # `#{CFBundleName} (target).help`, which is the historical behavior. Setting
89
+ # this to `false` will result in a help book named `#{CFBundleName}.help`,
90
+ # instead. This can be useful if you are building help books from scripts via
91
+ # XCode, and you set `help_output_location` to `ENV['BUILT_PRODUCTS_DIR']`.
92
+ # @return [Boolean] `true` or `false` to enable or disable this behavior.
75
93
 
76
94
  # @!attribute [rw] options[:img_auto_extensions]=
77
95
  # This option determines whether or not to support specifying images without
@@ -136,14 +154,21 @@ class Middlemac < ::Middleman::Extension
136
154
  dir = options[:help_output_location] || File.expand_path('./')
137
155
  cf_bundle_name = app.config[:targets][app.config[:target]][:CFBundleName]
138
156
  target = app.config[:target]
139
- output_name = "#{cf_bundle_name} (#{target}).help".gsub(' ', '_')
157
+
158
+ if options[:help_output_use_target]
159
+ output_name = "#{cf_bundle_name} (#{target}).help"
160
+ else
161
+ output_name = "#{cf_bundle_name}.help"
162
+ end
163
+ output_name.gsub!(' ', '_') if options[:help_output_avoid_spaces]
164
+
140
165
  app.config[:build_dir] = File.join(dir, output_name, 'Contents')
141
166
 
142
167
  return if app.config[:exit_before_ready]
143
168
 
144
169
  # Set the other directories accordingly.
145
170
  app.config[:layouts_dir] = File.join(app.config[:assets_dir], app.config[:layouts_dir])
146
- app.config[:partials_dir] = File.join(app.config[:assets_dir], app.config[:partials_dir])
171
+ app.config[:partials_dir] = File.join(app.config[:assets_dir], app.config[:partials_dir])
147
172
  app.config[:convention_dir] = File.join(app.config[:assets_dir], app.config[:convention_dir])
148
173
  app.config[:css_dir] = File.join(app.config[:assets_dir], app.config[:css_dir])
149
174
  app.config[:fonts_dir] = File.join(app.config[:assets_dir], app.config[:fonts_dir])
@@ -1,5 +1,5 @@
1
1
  module Middleman
2
2
  module Middlemac
3
- VERSION = '3.0.1'
3
+ VERSION = '3.1.0'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,53 +1,53 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: middlemac
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.1
4
+ version: 3.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jim Derry
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-09-08 00:00:00.000000000 Z
11
+ date: 2019-10-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: middleman-core
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
19
  version: 4.2.0
20
- - - ">="
20
+ - - "~>"
21
21
  - !ruby/object:Gem::Version
22
22
  version: 4.2.0
23
23
  type: :runtime
24
24
  prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
26
26
  requirements:
27
- - - "~>"
27
+ - - ">="
28
28
  - !ruby/object:Gem::Version
29
29
  version: 4.2.0
30
- - - ">="
30
+ - - "~>"
31
31
  - !ruby/object:Gem::Version
32
32
  version: 4.2.0
33
33
  - !ruby/object:Gem::Dependency
34
34
  name: middleman-cli
35
35
  requirement: !ruby/object:Gem::Requirement
36
36
  requirements:
37
- - - "~>"
37
+ - - ">="
38
38
  - !ruby/object:Gem::Version
39
39
  version: 4.2.0
40
- - - ">="
40
+ - - "~>"
41
41
  - !ruby/object:Gem::Version
42
42
  version: 4.2.0
43
43
  type: :runtime
44
44
  prerelease: false
45
45
  version_requirements: !ruby/object:Gem::Requirement
46
46
  requirements:
47
- - - "~>"
47
+ - - ">="
48
48
  - !ruby/object:Gem::Version
49
49
  version: 4.2.0
50
- - - ">="
50
+ - - "~>"
51
51
  - !ruby/object:Gem::Version
52
52
  version: 4.2.0
53
53
  - !ruby/object:Gem::Dependency
@@ -116,20 +116,20 @@ dependencies:
116
116
  name: middleman
117
117
  requirement: !ruby/object:Gem::Requirement
118
118
  requirements:
119
- - - "~>"
119
+ - - ">="
120
120
  - !ruby/object:Gem::Version
121
121
  version: 4.2.0
122
- - - ">="
122
+ - - "~>"
123
123
  - !ruby/object:Gem::Version
124
124
  version: 4.2.0
125
125
  type: :development
126
126
  prerelease: false
127
127
  version_requirements: !ruby/object:Gem::Requirement
128
128
  requirements:
129
- - - "~>"
129
+ - - ">="
130
130
  - !ruby/object:Gem::Version
131
131
  version: 4.2.0
132
- - - ">="
132
+ - - "~>"
133
133
  - !ruby/object:Gem::Version
134
134
  version: 4.2.0
135
135
  - !ruby/object:Gem::Dependency
@@ -196,6 +196,7 @@ executables:
196
196
  extensions: []
197
197
  extra_rdoc_files: []
198
198
  files:
199
+ - ".gitattributes"
199
200
  - ".gitignore"
200
201
  - ".yardopts"
201
202
  - CHANGELOG.md
@@ -624,8 +625,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
624
625
  - !ruby/object:Gem::Version
625
626
  version: '0'
626
627
  requirements: []
627
- rubyforge_project:
628
- rubygems_version: 2.6.14
628
+ rubygems_version: 3.0.6
629
629
  signing_key:
630
630
  specification_version: 4
631
631
  summary: Build complete macOS application help books using Middleman.