octopress-ink 1.0.0.rc.17 → 1.0.0.rc.18

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: 6d0c52dab77e717b45d38c2b9075f051127c028c
4
- data.tar.gz: 359b4225f4583027a5b60f56865bb5c2d91f6ac4
3
+ metadata.gz: 6d90edae371a19ba3eae21838264af5a68d4f3ed
4
+ data.tar.gz: 370c6b18cb9c0237726b3cd1d5c581521990ba40
5
5
  SHA512:
6
- metadata.gz: 39c441c385fca35b3c05df7266251b28f4c16dfd24ad93057e5a2bad55f43673be7fb897b4490154c43cbed1bb8489c4c086b023d2f5b129f6092ddb2fd6690f
7
- data.tar.gz: 9d150e3b9fa965e8f2e973026420ca57e5aeaf73babeb1048fb56ee395a46cd1523d9840f661711e9380f9597226d2b53f1da62da63b9114100698bc2d9b5849
6
+ metadata.gz: efc282ec1c33f693d3f32fbeaa384c10da418f42bff54eb4261e5655d18ebadbb809567d74a17f6be86a751b423deb4a48d8a4eb465f87a69fff80a9bf52cf74
7
+ data.tar.gz: fba7caea4927c363bff40f2d6055f2a15ba6cf9a350730bda18cab451351000de3d0ca6a73802e91ce25e092c3ddd11f349e9bc2f5b7601ebe052eeadb9e2fce
data/CHANGELOG.md ADDED
@@ -0,0 +1,84 @@
1
+ # Changelog
2
+
3
+ ### 1.0.0 RC18 - 2014-10-07
4
+
5
+ - Improved integration with octopress-docs for displaying plugin documentation.
6
+
7
+ ### 1.0.0 RC17 - 2014-09-01
8
+
9
+ - Fixed issue where Sass required a `_plugins/[plugin]/stylesheets` directory.
10
+
11
+ ### 1.0.0 RC16 - 2014-08-21
12
+
13
+ - New: Access the url for a plugin's page from anywhere with `{{ theme.permalinks.page_name }}` or `{{ plugins.pugin-name.permalinks.page_name }}`.
14
+ - Fix: Properly invalidate caches for `jekyll build --watch` support.
15
+
16
+ ### 1.0.0 RC15 - 2014-08-17
17
+
18
+ - Fixed an issue where Octopress would trigger site_payload too early.
19
+
20
+ ### 1.0.0 RC14 - 2014-08-11
21
+
22
+ - Reworked asset methods
23
+
24
+ ### 1.0.0 RC13 - 2014-08-11
25
+
26
+ - Fixed an issue with asset tags
27
+
28
+ ### 1.0.0 RC12 - 2014-08-03
29
+
30
+ - Extracted all tags to separate projects under [github.com/octopress](https://github.com/octopress).
31
+ - Now the only tag provided by default is [include-tag](https://github.com/octopress/include-tag).
32
+ - Switched from jekyll-page-hooks to octopress-hooks.
33
+ - Extracted link post feature as a separate plugin [octopress-linkblog](https://github.com/octopress/linkblog)
34
+ - Extracted page date feature as a separate plugin [octopress-date-format](https://github.com/octopress/date-format)
35
+ - Extracted Autoprefixer a separate plugin [octopress-autoprefixer](https://github.com/octopress/autoprefixer)
36
+
37
+ ### 1.0.0 RC11 - 2014-06-27
38
+
39
+ - Fixed: Render tag properly processes local variables.
40
+
41
+ ### 1.0.0 RC10 - 2014-06-26
42
+
43
+ - Render tag does a better job of preserving {% raw %} escaped content.
44
+
45
+ ### 1.0.0 RC9 - 2014-06-21
46
+
47
+ - Added jekyll-page-hooks as a dependency.
48
+ - Now processing partials as ConvertiblePartials
49
+
50
+ ### 1.0.0 RC8 - 2014-06-09
51
+
52
+ - Improved the way Ink manages the payload
53
+ - Added `linkposts` and `articles` methods to Ink
54
+
55
+ ### 1.0.0 RC7 - 2014-06-08
56
+
57
+ - New: Added `excerpted` post var, true if post.excerpt is shorted than post.content.
58
+
59
+ ### 1.0.0 RC6 - 2014-06-07
60
+
61
+ - Fixed: Gemspec scaffold does not include Ink's pre-release version numbers.
62
+ - Fixed: Better formatting for ordinal dates.
63
+ - Other minor bug fixes
64
+
65
+ ### 1.0.0 RC5 - 2014-06-06
66
+
67
+ - New: site.linkposts loops through linkposts
68
+ - New: site.articles loops through non-linkpost articles
69
+
70
+ ### 1.0.0 RC4 - 2014-05-28
71
+
72
+ - Improved: Plugin scaffold does a better job of handling gem names with dashes.
73
+
74
+ ### 1.0.0 RC3 - 2014-05-27
75
+
76
+ - Improved: Now copy and list commands use the flag --config-file instead of --defaults
77
+
78
+ ### 1.0.0 RC2 - 2014-05-26
79
+
80
+ - Fixed: Post and Page data is appended to at read time.
81
+
82
+ ### 1.0.0 RC1 - 2014-05-25
83
+
84
+ - Initial release candidate
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,36 @@
1
+ # Octopress Ink
2
+
3
+ Use Ink to help you build themes and plugins for Jekyll.
4
+
5
+ [![Gem Version](https://badge.fury.io/rb/octopress-ink.png)](http://badge.fury.io/rb/octopress-ink)
6
+ [![Build Status](https://travis-ci.org/octopress/ink.png?branch=master)](https://travis-ci.org/octopress/ink)
7
+
8
+ ### Features
9
+ - Installing Ink plugins is easy.
10
+ - Users won't need to install or manage plugin assets.
11
+ - Jekyll will read your plugin's layouts, javascripts, stylesheets and more directly from your gem.
12
+ - Ink allows users to modify a theme or plugin by adding a modified version to source/_custom directory.
13
+
14
+ ## Installation
15
+
16
+ Add this line to your application's Gemfile:
17
+
18
+ gem 'octopress-ink'
19
+
20
+ And then execute:
21
+
22
+ $ bundle
23
+
24
+ Or install it yourself as:
25
+
26
+ $ gem install octopress-ink
27
+
28
+ ## Usage
29
+
30
+ This is still evolving quite a bit. If you want to use it, you
31
+ should probably talk to me directly.
32
+
33
+ ## Contributing
34
+
35
+ For right now. Talk to me directly. I'd love help thinking
36
+ through some of this stuff. Pretty soon, build a theme or a plugin and tell me what's broken.
@@ -11,11 +11,31 @@ Octopress Ink plugins are distributed as ruby gems so you'll need to create an a
11
11
 
12
12
  Creating an Octopress Ink plugin is very simple. Here's the standard template.
13
13
 
14
- {% render ./_plugin-template.markdown %}
14
+ ```ruby
15
+ require "octopress-ink"
16
+
17
+ Octopress::Ink.add_plugin({
18
+ name: "My Plugin",
19
+ slug: "my-plugin",
20
+ assets_path: File.expand_path(File.join(File.dirname(__FILE__), '../assets')),
21
+ type: "plugin",
22
+ version: MyPlugin::VERSION,
23
+ description: "",
24
+ website: ""
25
+ })
26
+ ```
15
27
 
16
28
  The configuration options are as follows.
17
29
 
18
- {% render ./_configuration.markdown %}
30
+ | Configuration | Description |
31
+ |:--------------|:------------|
32
+ | name | The display name for your plugin, e.g. "My Plugin" |
33
+ | path | Path to your plugin's root directory |
34
+ | slug | Optional: The slug is how users will reference your plugin, (Default: sluggified name) |
35
+ | type | Optional: "plugin" or "theme" (Default: "plugin") |
36
+ | version | Optional: Version will be displayed with plugin info |
37
+ | description | Optional: Description will be displayed with plugin info |
38
+ | website | Optional: Website will be displayed with plugin info |
19
39
 
20
40
  Note: For themes, the slug will be set to `theme`. This makes it easy for users to work with any theme with a consistent slug name.
21
41
 
@@ -114,7 +134,7 @@ Note: Assets are copied at build time and assets will not overwrite an existing
114
134
  | Asset directory | Description |
115
135
  |:----------------|:------------------------------------------------|
116
136
  | layouts | Users can add layouts by setting `layout: plugin_slug:some_layout` in a page's YAML front-matter. |
117
- | includes | Includes are available to users by `{% raw %}{% include plugin_slug:some_file.html %}{% endraw %}`. |
137
+ | includes | Includes are available to users by `{% include plugin_slug:some_file.html %}`. |
118
138
  | pages | `pages/feed.xml` is processed and copied to `_site/feed.xml` at build time. Setting `permalink: feed/` renders to `_site/feed/index.xml`. |
119
139
  | files | `files/favicon.ico` is copied to `_site/favicon.ico`. |
120
140
  | fonts | `wingdings.ttf` is copied to `_site/fonts/plugin_slug/wingdings.ttf`. |
@@ -144,11 +164,11 @@ Here's a example of a simple `default.html` layout.
144
164
  <html>
145
165
  <head>
146
166
  <title>{{ page.title }} - {{ site.title }}</title>
147
- {% octopress_css %}
167
+ {% css_asset_tag %}
148
168
  </head>
149
169
  <body>
150
170
  {{ content }}
151
- {% octopress_js %}
171
+ {% js_asset_tag %}
152
172
  </body>
153
173
  </html>
154
174
  ```
@@ -9,13 +9,33 @@ Octopress Ink plugins should be distributed as Ruby gems. If you don't know how
9
9
 
10
10
  This is the basic template for creating an Octopress Ink plugin.
11
11
 
12
- {% render ./_plugin-template.markdown %}
12
+ ```ruby
13
+ require "octopress-ink"
14
+
15
+ Octopress::Ink.add_plugin({
16
+ name: "My Plugin",
17
+ slug: "my-plugin",
18
+ assets_path: File.expand_path(File.join(File.dirname(__FILE__), '../assets')),
19
+ type: "plugin",
20
+ version: MyPlugin::VERSION,
21
+ description: "",
22
+ website: ""
23
+ })
24
+ ```
13
25
 
14
26
  ### Configuration Reference
15
27
 
16
28
  The configuration options are as follows:
17
29
 
18
- {% render ./_configuration.markdown %}
30
+ | Configuration | Description |
31
+ |:--------------|:------------|
32
+ | name | The display name for your plugin, e.g. "My Plugin" |
33
+ | path | Path to your plugin's root directory |
34
+ | slug | Optional: The slug is how users will reference your plugin, (Default: sluggified name) |
35
+ | type | Optional: "plugin" or "theme" (Default: "plugin") |
36
+ | version | Optional: Version will be displayed with plugin info |
37
+ | description | Optional: Description will be displayed with plugin info |
38
+ | website | Optional: Website will be displayed with plugin info |
19
39
 
20
40
  ### Plugin Assets
21
41
 
data/lib/octopress-ink.rb CHANGED
@@ -5,9 +5,9 @@ require 'digest/md5'
5
5
  require 'octopress'
6
6
  require 'octopress-hooks'
7
7
  require 'octopress-filters'
8
+ require 'octopress-docs'
8
9
 
9
10
  require 'octopress-ink/version'
10
-
11
11
  require 'octopress-ink/configuration'
12
12
  require 'octopress-ink/jekyll/hooks'
13
13
 
@@ -67,10 +67,6 @@ module Octopress
67
67
  }
68
68
  }
69
69
 
70
- if Octopress.config['docs_mode']
71
- ink_payload['doc_pages'] = Ink::Plugins.doc_pages
72
- end
73
-
74
70
  ink_payload
75
71
  end
76
72
 
@@ -90,6 +86,10 @@ module Octopress
90
86
  Plugins.register_plugin Plugin, options
91
87
  end
92
88
 
89
+ def self.add_docs(options={})
90
+ Docs.register_docs options
91
+ end
92
+
93
93
  def self.config
94
94
  @config ||= Configuration.config
95
95
  end
@@ -229,8 +229,10 @@ end
229
229
 
230
230
  Liquid::Template.register_tag('css_asset_tag', Octopress::Ink::Tags::StylesheetTag)
231
231
  Liquid::Template.register_tag('js_asset_tag', Octopress::Ink::Tags::JavascriptTag)
232
- Liquid::Template.register_tag('doc_url', Octopress::Ink::Tags::DocUrlTag)
233
-
234
- require 'octopress-ink/plugins/ink'
235
232
 
236
- Octopress::Ink.register_plugin(Octopress::Ink::InkPlugin)
233
+ Octopress::Docs.add({
234
+ name: "Octopress Ink",
235
+ slug: "ink",
236
+ dir: File.expand_path(File.join(File.dirname(__FILE__), "../")),
237
+ base_url: "docs/ink"
238
+ })
@@ -5,7 +5,6 @@ module Octopress
5
5
  autoload :Config, 'octopress-ink/assets/config'
6
6
  autoload :FileAsset, 'octopress-ink/assets/file'
7
7
  autoload :PageAsset, 'octopress-ink/assets/page'
8
- autoload :DocPageAsset, 'octopress-ink/assets/doc_page'
9
8
  autoload :Javascript, 'octopress-ink/assets/javascript'
10
9
  autoload :Coffeescript, 'octopress-ink/assets/coffeescript'
11
10
  autoload :Stylesheet, 'octopress-ink/assets/stylesheet'
@@ -18,7 +18,7 @@ module Octopress
18
18
  end
19
19
 
20
20
  def add
21
- if !exists?(local_plugin_path) && !Octopress.config['docs_mode']
21
+ if !exists?(local_plugin_path)
22
22
  Plugins.static_files << StaticFile.new(File.join(source_dir, file), destination)
23
23
  end
24
24
  end
@@ -21,7 +21,7 @@ module Octopress
21
21
  # Add page to Jekyll pages if no other page has a conflicting destination
22
22
  #
23
23
  def add
24
- if page.url && !Octopress.config['docs_mode'] && !find_page(page)
24
+ if page.url && !find_page(page)
25
25
  Octopress.site.pages << page
26
26
  plugin.config['permalinks'] ||= {}
27
27
  plugin.config['permalinks'][File.basename(filename, '.*')] ||= page.url
@@ -8,7 +8,6 @@ module Octopress
8
8
  c.description "Get a list of installed octopress ink plugins for this site."
9
9
  c.option "all", "--all", "List all plugins and their assets."
10
10
  CommandHelpers.add_asset_options(c, 'List')
11
- c.option "docs", "--docs", "List documentation pages."
12
11
 
13
12
  c.action do |args, options|
14
13
  if args.empty?
@@ -43,6 +43,8 @@ module Octopress
43
43
  @settings = gem_settings(path_to_gem)
44
44
  @settings[:type] = @options['theme'] ? 'theme' : 'plugin'
45
45
 
46
+ fix_spec_files
47
+ add_to_gitignore
46
48
  add_dependency
47
49
  add_plugin
48
50
  add_assets
@@ -84,6 +86,24 @@ module Octopress
84
86
  new
85
87
  end
86
88
 
89
+ def self.fix_spec_files
90
+ @settings[:gemspec].sub! /(#{@settings[:spec_var]}\.files\s+=\s+)(.+)$/ do
91
+ $1+"`git ls-files -z`.split(\"\\x0\").grep(/^(bin\/|lib\/|assets\/|demo\/|changelog|readme|license)/i)"
92
+ end.sub!(/\s*#{@settings[:spec_var]}\.test_files.+$/, '')
93
+ end
94
+
95
+ def self.add_to_gitignore
96
+ path = File.join @settings[:path], '.gitignore'
97
+ content = File.open(path).read << <<-HERE
98
+ .*-cache
99
+ _site
100
+ HERE
101
+
102
+ File.open(path, 'w+') do |f|
103
+ f.write(content)
104
+ end
105
+ end
106
+
87
107
  # Create a new gem with Bundle's gem command
88
108
  #
89
109
  def self.create_gem(name)
@@ -115,7 +135,7 @@ module Octopress
115
135
  minor_version = VERSION.scan(/\d+\.\d/)[0]
116
136
  current_patch_version = VERSION.sub(/\.(alpha|rc).*/i, '')
117
137
  d = "#{@settings[:spec_var]}.add_development_dependency \"octopress\"\n\n"
118
- d += "#{@settings[:spec_var]}.add_runtime_dependency \"octopress-ink\", \"~> #{minor_version}\", \">= #{current_patch_version}\"\n"
138
+ d += "#{@settings[:spec_var]}.add_runtime_dependency \"octopress-ink\", \"~> #{minor_version}\"\n"
119
139
  end
120
140
 
121
141
  # Add Octopress Ink plugin to core module file
@@ -161,7 +181,7 @@ module Octopress
161
181
  config = <<-HERE
162
182
  name: "#{@settings[:module_name]}",
163
183
  slug: "#{@settings[:type] == 'theme' ? 'theme' : @settings[:name]}",
164
- assets_path: File.expand_path(File.join(File.dirname(__FILE__), "#{assets_path}")),
184
+ path: File.expand_path(File.join(File.dirname(__FILE__), "../")),
165
185
  type: "#{@settings[:type]}",
166
186
  version: #{@settings[:version]},
167
187
  description: "",
@@ -8,9 +8,9 @@ module Octopress
8
8
  type: 'plugin'
9
9
  }
10
10
 
11
- attr_reader :name, :type, :assets_path, :local, :website, :description, :version,
11
+ attr_reader :name, :type, :path, :assets_path, :local, :website, :description, :version,
12
12
  :layouts_dir, :stylesheets_dir, :javascripts_dir, :files_dir, :includes_dir, :images_dir,
13
- :layouts, :includes, :images, :fonts, :files, :pages, :docs
13
+ :layouts, :includes, :images, :fonts, :files, :pages, :docs, :docs_url
14
14
 
15
15
  def initialize(options)
16
16
  options = Jekyll::Utils.symbolize_hash_keys(options || configuration)
@@ -34,26 +34,32 @@ module Octopress
34
34
  @coffee = []
35
35
  @images = []
36
36
  @sass = []
37
- @docs = []
38
37
  @fonts = []
39
38
  @files = []
40
39
  @pages = []
41
40
  @slug ||= @name
41
+ @assets_path ||= File.join(@path, 'assets')
42
+ @docs_url ||= docs_url
42
43
  end
43
44
 
44
45
  def register
46
+
45
47
  unless @assets_path.nil?
46
48
  disable_assets
47
49
  add_assets
48
- add_layouts
49
- add_includes
50
- add_javascripts
51
- add_fonts
52
50
  add_images
53
- add_docs
54
- add_files
55
- add_pages
56
- add_stylesheets
51
+
52
+ if Octopress.config['docs_mode']
53
+ add_docs
54
+ elsif !Octopress.config['docs_site']
55
+ add_includes
56
+ add_layouts
57
+ add_javascripts
58
+ add_fonts
59
+ add_files
60
+ add_pages
61
+ add_stylesheets
62
+ end
57
63
  end
58
64
  end
59
65
 
@@ -67,36 +73,11 @@ module Octopress
67
73
  #
68
74
  # - returns: String, eg: docs/plugins/plugin-slug
69
75
  #
70
- def docs_base_path
71
-
76
+ def docs_url
72
77
  if @type == 'theme'
73
- base = 'theme'
78
+ File.join('docs', 'theme')
74
79
  else
75
- base = File.join('plugins', slug)
76
- end
77
-
78
- File.join('docs', base)
79
- end
80
-
81
- # Docs pages for easy listing in an index
82
- #
83
- # returns: Array of hashes including doc page title and url
84
- #
85
- def doc_pages
86
- if !@docs.empty?
87
- @doc_pages ||= @docs.clone.map { |d|
88
- page = d.page
89
- title = page.data['link_title'] || page.data['title'] || page.basename
90
- url = File.join('/', docs_base_path, page.url.sub('index.html', ''))
91
-
92
- {
93
- 'title' => title,
94
- 'url' => url
95
- }
96
- }.sort_by { |i|
97
- # Sort by depth of url
98
- i['url'].split('/').size
99
- }
80
+ File.join('docs', 'plugins', slug)
100
81
  end
101
82
  end
102
83
 
@@ -127,7 +108,6 @@ module Octopress
127
108
  copied = []
128
109
 
129
110
  select_assets(options).each do |name, assets|
130
- next if name == 'docs'
131
111
  assets.each { |a| copied << a.copy(path) }
132
112
  end
133
113
 
@@ -206,7 +186,6 @@ module Octopress
206
186
 
207
187
  def assets
208
188
  {
209
- 'docs' => @docs,
210
189
  'layouts' => @layouts,
211
190
  'includes' => @includes,
212
191
  'pages' => @pages,
@@ -233,9 +212,6 @@ module Octopress
233
212
  when 'pages'
234
213
  header = "pages:".ljust(36) + "urls"
235
214
  message += asset_list(assets, header)
236
- when 'docs'
237
- header = "documentation: /#{docs_base_path}/"
238
- message += asset_list(assets, header)
239
215
  when 'config-file'
240
216
  message += asset_list(assets, 'default configuration')
241
217
  else
@@ -373,11 +349,7 @@ module Octopress
373
349
  end
374
350
 
375
351
  def add_docs
376
- find_assets(@docs_dir).each do |asset|
377
- unless asset =~ /^_/
378
- @docs << Assets::DocPageAsset.new(self, @docs_dir, asset)
379
- end
380
- end
352
+ Octopress::Docs.add_plugin_docs(self)
381
353
  end
382
354
 
383
355
  def add_files
@@ -7,7 +7,7 @@ module Octopress
7
7
  def self.compile_css(content)
8
8
  configs = sass_converter.sass_configs
9
9
  configs[:syntax] = :scss
10
- configs[:style] = :compressed if Octopress.config['compress_css']
10
+ configs[:style] ||= :compressed if Octopress.config['compress_css']
11
11
 
12
12
  Sass.compile(content, configs)
13
13
  end
@@ -101,23 +101,6 @@ module Octopress
101
101
  end
102
102
  end
103
103
 
104
- # Docs pages for each plugin
105
- #
106
- # returns: Array of plugin doc pages
107
- #
108
- def self.doc_pages
109
- plugin_docs = {}
110
- plugins.clone.map do |p|
111
- if pages = p.doc_pages
112
- plugin_docs[p.slug] = {
113
- "name" => p.name,
114
- "pages" => pages
115
- }
116
- end
117
- end
118
- plugin_docs
119
- end
120
-
121
104
  # Inclue partials from plugins
122
105
  #
123
106
  def self.include(name, file)
@@ -3,7 +3,6 @@ module Octopress
3
3
  module Tags
4
4
  autoload :JavascriptTag, 'octopress-ink/tags/javascript'
5
5
  autoload :StylesheetTag, 'octopress-ink/tags/stylesheet'
6
- autoload :DocUrlTag, 'octopress-ink/tags/doc_url'
7
6
  end
8
7
  end
9
8
  end
@@ -1,5 +1,5 @@
1
1
  module Octopress
2
2
  module Ink
3
- VERSION = "1.0.0.rc.17"
3
+ VERSION = "1.0.0.rc.18"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: octopress-ink
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0.rc.17
4
+ version: 1.0.0.rc.18
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brandon Mathis
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-09-02 00:00:00.000000000 Z
11
+ date: 2014-10-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll
@@ -82,6 +82,20 @@ dependencies:
82
82
  version: '1.1'
83
83
  - !ruby/object:Gem::Dependency
84
84
  name: octopress
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - "~>"
88
+ - !ruby/object:Gem::Version
89
+ version: 3.0.0.rc
90
+ type: :runtime
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - "~>"
95
+ - !ruby/object:Gem::Version
96
+ version: 3.0.0.rc
97
+ - !ruby/object:Gem::Dependency
98
+ name: octopress-docs
85
99
  requirement: !ruby/object:Gem::Requirement
86
100
  requirements:
87
101
  - - ">="
@@ -109,39 +123,33 @@ dependencies:
109
123
  - !ruby/object:Gem::Version
110
124
  version: '0'
111
125
  - !ruby/object:Gem::Dependency
112
- name: bundler
126
+ name: clash
113
127
  requirement: !ruby/object:Gem::Requirement
114
128
  requirements:
115
- - - "~>"
116
- - !ruby/object:Gem::Version
117
- version: '1.6'
118
- - - "<="
129
+ - - ">="
119
130
  - !ruby/object:Gem::Version
120
- version: 1.6.2
131
+ version: '0'
121
132
  type: :development
122
133
  prerelease: false
123
134
  version_requirements: !ruby/object:Gem::Requirement
124
135
  requirements:
125
- - - "~>"
126
- - !ruby/object:Gem::Version
127
- version: '1.6'
128
- - - "<="
136
+ - - ">="
129
137
  - !ruby/object:Gem::Version
130
- version: 1.6.2
138
+ version: '0'
131
139
  - !ruby/object:Gem::Dependency
132
- name: clash
140
+ name: bundler
133
141
  requirement: !ruby/object:Gem::Requirement
134
142
  requirements:
135
- - - ">="
143
+ - - "~>"
136
144
  - !ruby/object:Gem::Version
137
- version: '0'
145
+ version: '1.7'
138
146
  type: :development
139
147
  prerelease: false
140
148
  version_requirements: !ruby/object:Gem::Requirement
141
149
  requirements:
142
- - - ">="
150
+ - - "~>"
143
151
  - !ruby/object:Gem::Version
144
- version: '0'
152
+ version: '1.7'
145
153
  - !ruby/object:Gem::Dependency
146
154
  name: pry-byebug
147
155
  requirement: !ruby/object:Gem::Requirement
@@ -163,6 +171,9 @@ executables: []
163
171
  extensions: []
164
172
  extra_rdoc_files: []
165
173
  files:
174
+ - CHANGELOG.md
175
+ - LICENSE.txt
176
+ - README.md
166
177
  - assets/docs/_configuration.markdown
167
178
  - assets/docs/_plugin-template.markdown
168
179
  - assets/docs/creating-a-plugin.markdown
@@ -174,7 +185,6 @@ files:
174
185
  - lib/octopress-ink/assets/asset.rb
175
186
  - lib/octopress-ink/assets/coffeescript.rb
176
187
  - lib/octopress-ink/assets/config.rb
177
- - lib/octopress-ink/assets/doc_page.rb
178
188
  - lib/octopress-ink/assets/file.rb
179
189
  - lib/octopress-ink/assets/javascript.rb
180
190
  - lib/octopress-ink/assets/layout.rb
@@ -195,18 +205,10 @@ files:
195
205
  - lib/octopress-ink/plugin.rb
196
206
  - lib/octopress-ink/plugin_asset_pipeline.rb
197
207
  - lib/octopress-ink/plugins.rb
198
- - lib/octopress-ink/plugins/ink.rb
199
208
  - lib/octopress-ink/tags.rb
200
- - lib/octopress-ink/tags/doc_url.rb
201
209
  - lib/octopress-ink/tags/javascript.rb
202
210
  - lib/octopress-ink/tags/stylesheet.rb
203
211
  - lib/octopress-ink/version.rb
204
- - test/_expected/test-plugin-expected/assets/config.yml
205
- - test/_expected/test-plugin-expected/lib/test-plugin.rb
206
- - test/_expected/test-plugin-expected/lib/test-plugin/version.rb
207
- - test/_expected/test-theme-expected/assets/config.yml
208
- - test/_expected/test-theme-expected/lib/test-theme.rb
209
- - test/_expected/test-theme-expected/lib/test-theme/version.rb
210
212
  homepage: https://github.com/octopress/ink
211
213
  licenses:
212
214
  - MIT
@@ -1,61 +0,0 @@
1
- module Octopress
2
- module Ink
3
- module Assets
4
- class DocPageAsset < Asset
5
- attr_reader :filename
6
-
7
- def initialize(plugin, base, file)
8
- @root = plugin.assets_path
9
- @plugin = plugin
10
- @base = base
11
- @filename = file
12
- @dir = File.dirname(file)
13
- @file = File.basename(file)
14
- @exists = {}
15
- file_check
16
- end
17
-
18
- def path
19
- File.join(plugin_dir, page_dir, file)
20
- end
21
-
22
- # Add doc page to Jekyll pages
23
- #
24
- def add
25
- if Octopress.config['docs_mode']
26
- Octopress.site.pages << page
27
- end
28
- end
29
-
30
- private
31
-
32
- def page
33
- return @page if @page
34
- @page = Page.new(Octopress.site, source_dir, page_dir, file, {'path'=>plugin.docs_base_path})
35
- @page.data['layout'] = 'docs'
36
- @page.data['plugin'] = {
37
- 'name' => @plugin.name,
38
- 'slug' => @plugin.slug,
39
- 'docs_base_path' => plugin.docs_base_path,
40
- }
41
- @page.data['dir'] = File.dirname(plugin_path)
42
- @page
43
- end
44
-
45
- def page_dir
46
- dir == '.' ? '' : dir
47
- end
48
-
49
- def plugin_path
50
- File.join(plugin_dir, page_dir, file)
51
- end
52
-
53
- def source_dir
54
- File.join root, base
55
- end
56
-
57
- end
58
- end
59
- end
60
- end
61
-
@@ -1,28 +0,0 @@
1
- module Octopress
2
- module Ink
3
- class InkPlugin < Octopress::Ink::Plugin
4
- def configuration
5
- {
6
- name: "Octopress Ink",
7
- slug: "ink",
8
- assets_path: Octopress::Ink.gem_dir('assets'),
9
- version: Octopress::Ink::VERSION,
10
- description: "Octopress Ink is a plugin framework for Jekyll",
11
- website: "http://octopress.org/docs/ink"
12
- }
13
- end
14
-
15
- def docs_base_path
16
- 'docs/ink'
17
- end
18
-
19
- def info(options)
20
- if options['docs']
21
- super
22
- else
23
- ''
24
- end
25
- end
26
- end
27
- end
28
- end
@@ -1,18 +0,0 @@
1
- # For plugin authors who need to generate urls pointing to ther doc pages.
2
-
3
- module Octopress
4
- module Ink
5
- module Tags
6
- class DocUrlTag < Liquid::Tag
7
- def initialize(tag_name, markup, tokens)
8
- super
9
- @url = markup.strip
10
- end
11
-
12
- def render(context)
13
- '/' + File.join(context['page']['plugin']['docs_base_path'], @url)
14
- end
15
- end
16
- end
17
- end
18
- end
@@ -1,4 +0,0 @@
1
- exclude:
2
- - Gemfile*
3
- gems:
4
- - test-plugin
@@ -1,12 +0,0 @@
1
- require 'test-plugin/version'
2
- require 'octopress-ink'
3
-
4
- Octopress::Ink.add_plugin({
5
- name: "Test Plugin",
6
- slug: "test-plugin",
7
- assets_path: File.expand_path(File.join(File.dirname(__FILE__), "../assets")),
8
- type: "plugin",
9
- version: TestPlugin::VERSION,
10
- description: "",
11
- website: ""
12
- })
@@ -1,3 +0,0 @@
1
- module TestPlugin
2
- VERSION = "0.0.1"
3
- end
@@ -1,4 +0,0 @@
1
- exclude:
2
- - Gemfile*
3
- gems:
4
- - test-theme
@@ -1,12 +0,0 @@
1
- require 'test-theme/version'
2
- require 'octopress-ink'
3
-
4
- Octopress::Ink.add_plugin({
5
- name: "Test Theme",
6
- slug: "theme",
7
- assets_path: File.expand_path(File.join(File.dirname(__FILE__), "../assets")),
8
- type: "theme",
9
- version: TestTheme::VERSION,
10
- description: "",
11
- website: ""
12
- })
@@ -1,3 +0,0 @@
1
- module TestTheme
2
- VERSION = "0.0.1"
3
- end