neo4j-asciidoctor-extensions 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (25) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +1 -1
  3. data/README.adoc +34 -28
  4. data/lib/neo4j/asciidoctor/extensions.rb +8 -0
  5. data/lib/{neo4j_asciidoctor_extensions → neo4j/asciidoctor/extensions}/course_document_attributes.rb +0 -0
  6. data/lib/{neo4j_asciidoctor_extensions → neo4j/asciidoctor/extensions}/course_document_attributes/extension.rb +0 -0
  7. data/lib/{neo4j_asciidoctor_extensions → neo4j/asciidoctor/extensions}/cypher_syntax_role.rb +0 -0
  8. data/lib/{neo4j_asciidoctor_extensions → neo4j/asciidoctor/extensions}/cypher_syntax_role/extension.rb +0 -0
  9. data/lib/{neo4j_asciidoctor_extensions → neo4j/asciidoctor/extensions}/document_metadata_generator.rb +0 -0
  10. data/lib/{neo4j_asciidoctor_extensions → neo4j/asciidoctor/extensions}/document_metadata_generator/extension.rb +0 -0
  11. data/lib/{neo4j_asciidoctor_extensions → neo4j/asciidoctor/extensions}/inline_highlighter_rouge.rb +0 -0
  12. data/lib/{neo4j_asciidoctor_extensions → neo4j/asciidoctor/extensions}/inline_highlighter_rouge/extension.rb +0 -0
  13. data/lib/{neo4j_asciidoctor_extensions → neo4j/asciidoctor/extensions}/revealjs_linear_navigation.rb +0 -0
  14. data/lib/{neo4j_asciidoctor_extensions → neo4j/asciidoctor/extensions}/revealjs_linear_navigation/extension.rb +0 -0
  15. data/lib/{neo4j_asciidoctor_extensions → neo4j/asciidoctor/extensions}/revealjs_speaker_notes_aggregator.rb +0 -0
  16. data/lib/{neo4j_asciidoctor_extensions → neo4j/asciidoctor/extensions}/revealjs_speaker_notes_aggregator/extension.rb +0 -0
  17. data/neo4j-asciidoctor-extensions.gemspec +1 -1
  18. data/spec/cypher_syntax_role_spec.rb +1 -1
  19. data/spec/document_metadata_generator_spec.rb +1 -1
  20. data/spec/inline_highlighter_rouge_spec.rb +1 -1
  21. data/spec/revealjs_linear_navigation_spec.rb +1 -1
  22. data/spec/revealjs_speaker_notes_aggregator_spec.rb +1 -1
  23. data/tasks/bundler.rake +2 -1
  24. metadata +14 -14
  25. data/lib/neo4j_asciidoctor_extensions.rb +0 -8
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2dac414fc3be4c6ceaf02e3e3a1eadcf080e2a46c87a8587da72a368e7087937
4
- data.tar.gz: e205eadc7743d01ecaf7f28ab7fd80eb6e0fc7717a4b7be1a4eb86fb3adc47b5
3
+ metadata.gz: 1ee63d095a6ddc2621c6a70a27e117360e43e9ae82c317f88168e165897103b7
4
+ data.tar.gz: d4fda2cdb54912ee593775587a0143e15938200938fafc53038651d456557eaa
5
5
  SHA512:
6
- metadata.gz: 1d1b053f42228a46e6e9786211b42b5ee7bd79e9a616986f1f8635c74b24354b31bb922f839de73185f410ba7e9fd52ffd3e845d34cbebf22d724b47e410f784
7
- data.tar.gz: 3517e30b390c9aeb4ec90da2041eb37f6b19da8fd754840b2b6b762d42225b2798c3c0790bef9a1458811ba3a4986086038188fe61a18ce6d64fdab30bd16295
6
+ metadata.gz: 2fe832f1eab6f10a280445cb1ebd69e860e69e3532de4e809843da531a9b37db2b186b7924d60af3d12f8ec35b795dec53617dcc86364feb2a8ee523f499b988
7
+ data.tar.gz: 57bd9149a7b881d1017af2e9925b88872f837abe8d1ba30891749bca8c988bbf608991502b7658be3d74d1595b7075de67f50b3a7c7d4fe242da67901140528a
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- neo4j-asciidoctor-extensions (0.0.1)
4
+ neo4j-asciidoctor-extensions (0.0.2)
5
5
  asciidoctor (~> 2.0.0)
6
6
  asciidoctor-pdf (= 1.5.3)
7
7
  rouge (~> 3.18.0)
data/README.adoc CHANGED
@@ -5,23 +5,47 @@ image:https://github.com/neo4j-contrib/neo4j-asciidoctor-extensions/workflows/CI
5
5
 
6
6
  This repository contains Asciidoctor extensions made by {uri-neo4j}[Neo4j] for processing and publishing AsciiDoc content.
7
7
 
8
- == Usage
8
+ == Install
9
9
 
10
10
  [source,console]
11
11
  ----
12
12
  $ gem install neo4j-asciidoctor-extensions
13
- $ asciidoctor -r neo4j-asciidoctor-extensions doc.adoc
14
13
  ----
15
14
 
15
+ == Usage
16
+
17
+ === CLI
18
+
19
+ [source,console]
20
+ ----
21
+ $ asciidoctor -r neo4j/asciidoctor/extensions doc.adoc
22
+ ----
23
+
24
+ === API
25
+
26
+ [source,ruby]
27
+ ----
28
+ require 'neo4j/asciidoctor/extensions'
29
+ ----
30
+
31
+ In addition, you can require individual extension:
32
+
33
+ [source,ruby]
34
+ ----
35
+ require 'neo4j/asciidoctor/extensions/revealjs_linear_navigation'
36
+ ----
37
+
38
+ See below for the complete list of extensions.
39
+
16
40
  == Extensions
17
41
 
18
- The Ruby Gem contains 6 distinct extensions:
42
+ The Ruby gem contains 6 distinct extensions:
19
43
 
20
- === `CourseDocumentAttributesPostProcessor`
44
+ === `course_document_attributes`
21
45
 
22
46
  A postprocessor that adds attributes about the course.
23
47
 
24
- === `CypherSyntaxRoleTreeProcessor`
48
+ === `cypher_syntax_role`
25
49
 
26
50
  A tree processor that adds a role on code blocks using "cypher-syntax" as a language.
27
51
 
@@ -38,7 +62,7 @@ A tree processor that adds a role on code blocks using "cypher-syntax" as a lang
38
62
  ----
39
63
  ....
40
64
 
41
- === `DocumentMetadataGeneratorPostProcessor`
65
+ === `document_metadata_generator`
42
66
 
43
67
  A postprocess that generates a metadata file (in YAML format) from a list of document attributes.
44
68
 
@@ -80,45 +104,27 @@ taxonomies:
80
104
  - 3-6
81
105
  ----
82
106
 
83
- === `InlineHighlighter::MonospacedTextInlineMacro`
107
+ === `inline_highlighter_rouge`
84
108
 
85
109
  Inline syntax highlighter based on Rouge.
86
- Apply syntax highlighting on monospaced text cypher:
110
+ It applies syntax highlighting on both monospaced text cypher and `src` inline macro:
87
111
 
88
112
  *Usage:*
89
113
 
90
114
  [source,adoc]
91
115
  ----
92
116
  [src-cypher]`MATCH (c:Customer {customerName: 'ABCCO'}) RETURN c.BOUGHT.productName`
93
- ----
94
-
95
- Apply syntax highlighting on src inline macro:
96
-
97
- *Usage:*
98
-
99
- [source,adoc]
100
- ----
101
- src:cypher[MATCH (c:Customer {customerName: 'ABCCO'}) RETURN c.BOUGHT.productName]
102
- ----
103
-
104
- === `InlineHighlighter::SrcInlineMacro`
105
-
106
- Apply syntax highlighting on src inline macro:
107
117
 
108
- *Usage:*
109
-
110
- [source,adoc]
111
- ----
112
118
  src:cypher[MATCH (c:Customer {customerName: 'ABCCO'}) RETURN c.BOUGHT.productName]
113
119
  ----
114
120
 
115
- === `RevealJsLinearNavigationTreeProcessor`
121
+ === `revealjs_linear_navigation`
116
122
 
117
123
  A tree process that "flatten" a reveal.js presentation to use a linear navigation.
118
124
  By default, the reveal.js converter will use a vertical navigation for the second levels of section titles (and below).
119
125
  This extension will effectively prevent that by using only first level section titles.
120
126
 
121
- === `RevealJsSpeakerNotesAggregatorTreeProcessor`
127
+ === `revealjs_speaker_notes_aggregator`
122
128
  A tree processor that aggregates multiple `[.notes]` blocks in a section (slide).
123
129
 
124
130
  *Usage:*
@@ -0,0 +1,8 @@
1
+ # frozen_string_literal: true
2
+
3
+ require_relative 'extensions/course_document_attributes'
4
+ require_relative 'extensions/cypher_syntax_role'
5
+ require_relative 'extensions/document_metadata_generator'
6
+ require_relative 'extensions/inline_highlighter_rouge'
7
+ require_relative 'extensions/revealjs_linear_navigation'
8
+ require_relative 'extensions/revealjs_speaker_notes_aggregator'
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = 'neo4j-asciidoctor-extensions'
5
- s.version = '0.0.1'
5
+ s.version = '0.0.2'
6
6
  s.summary = 'Asciidoctor extensions by Neo4j.'
7
7
  s.description = 'Asciidoctor extensions by Neo4j.'
8
8
 
@@ -1,7 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  require 'asciidoctor'
4
- require_relative '../lib/neo4j_asciidoctor_extensions/cypher_syntax_role'
4
+ require_relative '../lib/neo4j/asciidoctor/extensions/cypher_syntax_role'
5
5
 
6
6
  describe Neo4j::AsciidoctorExtensions::CypherSyntaxRoleTreeProcessor do
7
7
  context 'convert to html5' do
@@ -1,7 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  require 'asciidoctor'
4
- require_relative '../lib/neo4j_asciidoctor_extensions/document_metadata_generator'
4
+ require_relative '../lib/neo4j/asciidoctor/extensions/document_metadata_generator'
5
5
 
6
6
  RSpec.configure do |config|
7
7
  config.after(:each) do
@@ -1,7 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  require 'asciidoctor'
4
- require_relative '../lib/neo4j_asciidoctor_extensions/inline_highlighter_rouge'
4
+ require_relative '../lib/neo4j/asciidoctor/extensions/inline_highlighter_rouge'
5
5
 
6
6
  # rubocop:disable Metrics/LineLength
7
7
  describe Neo4j::AsciidoctorExtensions::InlineHighlighter::MonospacedTextInlineMacro do
@@ -2,7 +2,7 @@
2
2
 
3
3
  require 'asciidoctor'
4
4
  require 'asciidoctor-revealjs'
5
- require_relative '../lib/neo4j_asciidoctor_extensions/revealjs_linear_navigation'
5
+ require_relative '../lib/neo4j/asciidoctor/extensions/revealjs_linear_navigation'
6
6
 
7
7
  describe Neo4j::AsciidoctorExtensions::RevealJsLinearNavigationTreeProcessor do
8
8
  context 'convert to reveal.js' do
@@ -2,7 +2,7 @@
2
2
 
3
3
  require 'asciidoctor'
4
4
  require 'asciidoctor-revealjs'
5
- require_relative '../lib/neo4j_asciidoctor_extensions/revealjs_speaker_notes_aggregator'
5
+ require_relative '../lib/neo4j/asciidoctor/extensions/revealjs_speaker_notes_aggregator'
6
6
 
7
7
  describe Neo4j::AsciidoctorExtensions::RevealJsSpeakerNotesAggregatorTreeProcessor do
8
8
  context 'convert to reveal.js' do
data/tasks/bundler.rake CHANGED
@@ -1,6 +1,7 @@
1
1
  # frozen_string_literal: true
2
+
2
3
  begin
3
4
  require 'bundler/gem_tasks'
4
5
  rescue LoadError
5
- warn $!.message
6
+ warn $ERROR_INFO.message
6
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: neo4j-asciidoctor-extensions
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Guillaume Grossetie
@@ -125,19 +125,19 @@ files:
125
125
  - LICENSE
126
126
  - README.adoc
127
127
  - Rakefile
128
- - lib/neo4j_asciidoctor_extensions.rb
129
- - lib/neo4j_asciidoctor_extensions/course_document_attributes.rb
130
- - lib/neo4j_asciidoctor_extensions/course_document_attributes/extension.rb
131
- - lib/neo4j_asciidoctor_extensions/cypher_syntax_role.rb
132
- - lib/neo4j_asciidoctor_extensions/cypher_syntax_role/extension.rb
133
- - lib/neo4j_asciidoctor_extensions/document_metadata_generator.rb
134
- - lib/neo4j_asciidoctor_extensions/document_metadata_generator/extension.rb
135
- - lib/neo4j_asciidoctor_extensions/inline_highlighter_rouge.rb
136
- - lib/neo4j_asciidoctor_extensions/inline_highlighter_rouge/extension.rb
137
- - lib/neo4j_asciidoctor_extensions/revealjs_linear_navigation.rb
138
- - lib/neo4j_asciidoctor_extensions/revealjs_linear_navigation/extension.rb
139
- - lib/neo4j_asciidoctor_extensions/revealjs_speaker_notes_aggregator.rb
140
- - lib/neo4j_asciidoctor_extensions/revealjs_speaker_notes_aggregator/extension.rb
128
+ - lib/neo4j/asciidoctor/extensions.rb
129
+ - lib/neo4j/asciidoctor/extensions/course_document_attributes.rb
130
+ - lib/neo4j/asciidoctor/extensions/course_document_attributes/extension.rb
131
+ - lib/neo4j/asciidoctor/extensions/cypher_syntax_role.rb
132
+ - lib/neo4j/asciidoctor/extensions/cypher_syntax_role/extension.rb
133
+ - lib/neo4j/asciidoctor/extensions/document_metadata_generator.rb
134
+ - lib/neo4j/asciidoctor/extensions/document_metadata_generator/extension.rb
135
+ - lib/neo4j/asciidoctor/extensions/inline_highlighter_rouge.rb
136
+ - lib/neo4j/asciidoctor/extensions/inline_highlighter_rouge/extension.rb
137
+ - lib/neo4j/asciidoctor/extensions/revealjs_linear_navigation.rb
138
+ - lib/neo4j/asciidoctor/extensions/revealjs_linear_navigation/extension.rb
139
+ - lib/neo4j/asciidoctor/extensions/revealjs_speaker_notes_aggregator.rb
140
+ - lib/neo4j/asciidoctor/extensions/revealjs_speaker_notes_aggregator/extension.rb
141
141
  - neo4j-asciidoctor-extensions.gemspec
142
142
  - spec/.rubocop.yml
143
143
  - spec/cypher_syntax_role_spec.rb
@@ -1,8 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require_relative 'neo4j_asciidoctor_extensions/course_document_attributes'
4
- require_relative 'neo4j_asciidoctor_extensions/cypher_syntax_role'
5
- require_relative 'neo4j_asciidoctor_extensions/document_metadata_generator'
6
- require_relative 'neo4j_asciidoctor_extensions/inline_highlighter_rouge'
7
- require_relative 'neo4j_asciidoctor_extensions/revealjs_linear_navigation'
8
- require_relative 'neo4j_asciidoctor_extensions/revealjs_speaker_notes_aggregator'