giblish 0.8.2 → 1.0.0.rc2

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.
Files changed (113) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/unit_tests.yml +30 -0
  3. data/.gitignore +7 -3
  4. data/.ruby-version +1 -1
  5. data/Changelog.adoc +61 -0
  6. data/README.adoc +267 -0
  7. data/docs/concepts/text_search.adoc +213 -0
  8. data/docs/concepts/text_search_im/cgi-search_request.puml +35 -0
  9. data/docs/concepts/text_search_im/cgi-search_request.svg +397 -0
  10. data/docs/concepts/text_search_im/search_request.puml +40 -0
  11. data/docs/concepts/text_search_im/search_request.svg +408 -0
  12. data/docs/howtos/trigger_generation.adoc +180 -0
  13. data/docs/{setup_server_assets → howtos/trigger_generation_im}/Render Documents.png +0 -0
  14. data/docs/{setup_server_assets → howtos/trigger_generation_im}/View Documents.png +0 -0
  15. data/docs/{setup_server_assets → howtos/trigger_generation_im}/deploy_with_hooks.graphml +0 -0
  16. data/docs/{setup_server_assets → howtos/trigger_generation_im}/deploy_with_hooks.svg +0 -0
  17. data/docs/{setup_server_assets → howtos/trigger_generation_im}/deploy_with_jenkins.graphml +0 -0
  18. data/docs/{setup_server_assets → howtos/trigger_generation_im}/deploy_with_jenkins.svg +0 -0
  19. data/docs/howtos/trigger_generation_im/docgen_github.puml +51 -0
  20. data/docs/{setup_server_assets → howtos/trigger_generation_im}/giblish_deployment.graphml +0 -0
  21. data/docs/howtos/trigger_generation_im/post-receive-example.sh +50 -0
  22. data/docs/reference/box_flow_spec.adoc +22 -0
  23. data/docs/reference/search_spec.adoc +185 -0
  24. data/giblish.gemspec +47 -29
  25. data/lib/giblish/adocsrc_providers.rb +23 -0
  26. data/lib/giblish/application.rb +214 -41
  27. data/lib/giblish/cmdline.rb +273 -259
  28. data/lib/giblish/config_utils.rb +41 -0
  29. data/lib/giblish/configurator.rb +163 -0
  30. data/lib/giblish/conversion_info.rb +120 -0
  31. data/lib/giblish/docattr_providers.rb +125 -0
  32. data/lib/giblish/docid/docid.rb +181 -0
  33. data/lib/giblish/github_trigger/webhook_manager.rb +64 -0
  34. data/lib/giblish/gitrepos/checkoutmanager.rb +124 -0
  35. data/lib/giblish/{gititf.rb → gitrepos/gititf.rb} +30 -4
  36. data/lib/giblish/gitrepos/gitsummary.erb +61 -0
  37. data/lib/giblish/gitrepos/gitsummaryprovider.rb +78 -0
  38. data/lib/giblish/gitrepos/history_pb.rb +41 -0
  39. data/lib/giblish/indexbuilders/d3treegraph.rb +88 -0
  40. data/lib/giblish/indexbuilders/depgraphbuilder.rb +109 -0
  41. data/lib/giblish/indexbuilders/dotdigraphadoc.rb +174 -0
  42. data/lib/giblish/indexbuilders/standard_index.erb +10 -0
  43. data/lib/giblish/indexbuilders/subtree_indices.rb +132 -0
  44. data/lib/giblish/indexbuilders/templates/circles.html.erb +111 -0
  45. data/lib/giblish/indexbuilders/templates/flame.html.erb +61 -0
  46. data/lib/giblish/indexbuilders/templates/tree.html.erb +366 -0
  47. data/lib/giblish/indexbuilders/templates/treemap.html.erb +127 -0
  48. data/lib/giblish/indexbuilders/verbatimtree.rb +94 -0
  49. data/lib/giblish/pathtree.rb +473 -74
  50. data/lib/giblish/resourcepaths.rb +150 -0
  51. data/lib/giblish/search/expand_adoc.rb +55 -0
  52. data/lib/giblish/search/headingindexer.rb +312 -0
  53. data/lib/giblish/search/request_manager.rb +110 -0
  54. data/lib/giblish/search/searchquery.rb +68 -0
  55. data/lib/giblish/search/textsearcher.rb +349 -0
  56. data/lib/giblish/subtreeinfobuilder.rb +77 -0
  57. data/lib/giblish/treeconverter.rb +272 -0
  58. data/lib/giblish/utils.rb +142 -294
  59. data/lib/giblish/version.rb +1 -1
  60. data/lib/giblish.rb +10 -7
  61. data/scripts/hooks/post-receive.example +66 -0
  62. data/{docgen/scripts/githook_examples → scripts/hooks}/post-update.example +0 -0
  63. data/{docgen → scripts}/resources/css/adoc-colony.css +0 -0
  64. data/scripts/resources/css/giblish-serif.css +419 -0
  65. data/scripts/resources/css/giblish.css +1979 -419
  66. data/{docgen → scripts}/resources/fonts/Ubuntu-B.ttf +0 -0
  67. data/{docgen → scripts}/resources/fonts/Ubuntu-BI.ttf +0 -0
  68. data/{docgen → scripts}/resources/fonts/Ubuntu-R.ttf +0 -0
  69. data/{docgen → scripts}/resources/fonts/Ubuntu-RI.ttf +0 -0
  70. data/{docgen → scripts}/resources/fonts/mplus1p-regular-fallback.ttf +0 -0
  71. data/{docgen → scripts}/resources/images/giblish_logo.png +0 -0
  72. data/{docgen → scripts}/resources/images/giblish_logo.svg +0 -0
  73. data/{docgen → scripts}/resources/themes/giblish.yml +0 -0
  74. data/scripts/wserv_development.rb +32 -0
  75. data/web_apps/cgi_search/gibsearch.rb +43 -0
  76. data/web_apps/gh_webhook_trigger/config.ru +2 -0
  77. data/web_apps/gh_webhook_trigger/gh_webhook_trigger.rb +73 -0
  78. data/web_apps/gh_webhook_trigger/public/dummy.txt +3 -0
  79. data/web_apps/sinatra_search/config.ru +2 -0
  80. data/web_apps/sinatra_search/public/dummy.txt +3 -0
  81. data/web_apps/sinatra_search/sinatra_search.rb +34 -0
  82. data/web_apps/sinatra_search/tmp/restart.txt +0 -0
  83. metadata +168 -73
  84. data/.rubocop.yml +0 -7
  85. data/.travis.yml +0 -3
  86. data/Changelog +0 -16
  87. data/Gemfile +0 -4
  88. data/README.adoc +0 -1
  89. data/Rakefile +0 -41
  90. data/bin/console +0 -14
  91. data/bin/setup +0 -8
  92. data/data/testdocs/malformed/no_header.adoc +0 -5
  93. data/data/testdocs/toplevel.adoc +0 -19
  94. data/data/testdocs/wellformed/adorned_purpose.adoc +0 -17
  95. data/data/testdocs/wellformed/docidtest/docid_1.adoc +0 -24
  96. data/data/testdocs/wellformed/docidtest/docid_2.adoc +0 -8
  97. data/data/testdocs/wellformed/simple.adoc +0 -14
  98. data/data/testdocs/wellformed/source_highlighting/highlight_source.adoc +0 -38
  99. data/docgen/resources/css/giblish.css +0 -1979
  100. data/docgen/scripts/Jenkinsfile +0 -18
  101. data/docgen/scripts/gen_adoc_org.sh +0 -58
  102. data/docs/README.adoc +0 -387
  103. data/docs/setup_server.adoc +0 -202
  104. data/lib/giblish/buildgraph.rb +0 -216
  105. data/lib/giblish/buildindex.rb +0 -459
  106. data/lib/giblish/core.rb +0 -451
  107. data/lib/giblish/docconverter.rb +0 -308
  108. data/lib/giblish/docid.rb +0 -180
  109. data/lib/giblish/docinfo.rb +0 -75
  110. data/lib/giblish/indexheadings.rb +0 -251
  111. data/lib/giblish-search.cgi +0 -459
  112. data/scripts/hooks/post-receive +0 -57
  113. data/scripts/publish_html.sh +0 -99
data/Rakefile DELETED
@@ -1,41 +0,0 @@
1
- require "rake/testtask"
2
-
3
- Rake::TestTask.new(:test) do |t|
4
- t.libs << "test"
5
- t.libs << "lib"
6
- t.test_files = FileList["test/**/*_test.rb"]
7
- end
8
-
9
- Rake::TestTask.new(:current) do |t|
10
- t.libs << "test"
11
- t.libs << "lib"
12
- t.test_files = FileList["test/**/index_heading_test.rb"]
13
- end
14
-
15
- Rake::TestTask.new(:paths) do |t|
16
- t.libs << "test"
17
- t.libs << "lib"
18
- t.test_files = FileList["test/**/pathmanager_test.rb"]
19
- end
20
-
21
- Rake::TestTask.new(:graph) do |t|
22
- t.libs << "test"
23
- t.libs << "lib"
24
- t.test_files = FileList["test/**/depgraph_test.rb"]
25
- end
26
-
27
- Rake::TestTask.new(:css) do |t|
28
- t.libs << "test"
29
- t.libs << "lib"
30
- t.test_files = FileList["test/**/linkcss_test.rb"]
31
- end
32
-
33
- Rake::TestTask.new(:sandbox) do |t|
34
- t.libs << "test"
35
- t.libs << "lib"
36
- t.test_files = FileList["test/**/sandbox_test.rb"]
37
- end
38
-
39
-
40
- # task :default => :spec
41
- task :default => :test
data/bin/console DELETED
@@ -1,14 +0,0 @@
1
- #!/usr/bin/env ruby
2
-
3
- require "bundler/setup"
4
- require "giblish"
5
-
6
- # You can add fixtures and/or initialization code here to make experimenting
7
- # with your gem easier. You can also use a different console, if you like.
8
-
9
- # (If you use this, don't forget to add pry to your Gemfile!)
10
- # require "pry"
11
- # Pry.start
12
-
13
- require "irb"
14
- IRB.start
data/bin/setup DELETED
@@ -1,8 +0,0 @@
1
- #!/usr/bin/env bash
2
- set -euo pipefail
3
- IFS=$'\n\t'
4
- set -vx
5
-
6
- bundle install
7
-
8
- # Do any other automated setup that you need to do here
@@ -1,5 +0,0 @@
1
- This document does not have any title and sections. Only a couple of plain text paragraphs. It does however, contain a docid which should not be parsed.
2
- :docid: MF-001
3
-
4
-
5
- Lets see if that will mess anything up
@@ -1,19 +0,0 @@
1
- = Toplevel document for Giblish test suite
2
- :toc: left
3
- :docid: GT-001
4
- :imagesdir: images
5
- :numbered:
6
-
7
- This is the preamble
8
-
9
- == Purpose
10
-
11
- This doc tests some aspects of giblish.
12
-
13
- == Another section
14
-
15
- With some text...
16
-
17
- === A sub-section
18
-
19
- With some more text...
@@ -1,17 +0,0 @@
1
- = Testing the 'purpose' section
2
- :toc:
3
- :docid: WF-002
4
- :numbered:
5
-
6
- == Purpose
7
-
8
- To test how asciidoc formatting in the *_purpose_* section are shown in the index page.
9
-
10
- List item::
11
- Item one
12
-
13
- * Unordered item 1
14
- * Unordered item 2
15
-
16
- . Ordered item 1
17
- . Ordered item 2
@@ -1,24 +0,0 @@
1
- = Testing document ids
2
- :toc:
3
- :docid: WF-013
4
-
5
- == Purpose
6
-
7
- To test the basic functionality of document id references.
8
-
9
- Other valid docid references::
10
-
11
- * << :docid:WF-022,Using space before>>
12
- * << :docid: WF-022,Using space and tabs>>
13
- * <<:docid:WF-022#Testing Document ids>> No title but hash and section.
14
- * <<:docid:WF-022>> No title and no hash
15
- * <<:docid:WF-022,docid_2 adoc>> Another document within the tree.
16
- * <<:docid:WF-022#Purpose, Purpose in WF-022>> Reference a section in another document
17
- * <<:docid:WF-022>> Two references on the same line <<:docid:WF-013>>.
18
-
19
- Invalid docid references::
20
-
21
- * <<:DOCID:WF-022>> Wrong case
22
- * <<:docid:WF-013 No ending signs
23
- * <<:docid:WF-0134567890123>> Doc id longer than max chars
24
- * <<:docid:W>> Doc id too short
@@ -1,8 +0,0 @@
1
- = Docid test doc 2
2
- :toc: left
3
- :numbered:
4
- :docid: WF-022
5
-
6
- == Purpose
7
-
8
- To test that Giblish can use <<:docid: WF-013, doc-id references>> to refer to external documents.
@@ -1,14 +0,0 @@
1
- = A simple Ascidoc document
2
- Using the author line as sub-title
3
- :toc:
4
- :docid: WF-001
5
- :imagesdir: images
6
- :numbered:
7
-
8
- == Purpose
9
-
10
- To provide a barebone, wellformed asciidoc document.
11
-
12
- == The gist
13
-
14
- This paragraph is the only content.
@@ -1,38 +0,0 @@
1
- = Simple Source highlighting
2
- giblish test suite
3
-
4
- == Purpose
5
-
6
- To check that source code is correctly highlighted when generating docs.
7
-
8
- == Examples
9
-
10
-
11
- [source,ruby]
12
- .A ruby example
13
- ....
14
- require 'asciidoctor'
15
- #Some comment
16
- a = Asciidoctor::load("mydoc.txt")
17
- ....
18
-
19
- [source,cs]
20
- .A C# example
21
- ----
22
- class MyFancyClass
23
- {
24
- ///
25
- /// Documentation goes here...
26
- public MyFancyClass()
27
- {
28
- var x = DoIt();
29
- }
30
- }
31
- ----
32
-
33
- [source,bash]
34
- .A Bash Example
35
- ----
36
- myVar="${?}"
37
- git pull ${myVar}
38
- ----