madman 0.2.2 → 0.2.9

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
  SHA256:
3
- metadata.gz: 7e1113b347b10a4315da7bf0c27322724f470d18788f4cd29e55ff08d20e386d
4
- data.tar.gz: 612124a4e5f5fc1620e9a620cb5a626d7ebd8e3403ecd23098de0556b68c0452
3
+ metadata.gz: 60c061af738d6d3b7230deb983106d9f7048a7e37f8eaf0c26d5aac99c41af9e
4
+ data.tar.gz: 9080e9b62319d7038f5847e49aa0bc799f7da36aa665e345e962b6e528449b36
5
5
  SHA512:
6
- metadata.gz: 6f70d18a985aefdd93bb1d1be78b3374725aa7f90267f2f3feac3e462f016e55e30ca6b9995cb2bc276db92daea97e76ffacbb6506d0ae16198fb273a8b33347
7
- data.tar.gz: d9fafb6da92cb704d5431b59d3424d71e25a5a4965afed3e258fb65e948c39be490dd430ce9e7e209a6c0ad09c215e7a354d606d009465818cda683f354178b8
6
+ metadata.gz: 4c0144818df47c80e9e8758fb932cd1238eccea30615a68413e434d9b49da1d7b64e9ed02ab763c4214aa478e1d4a3d1f49a0e3634e83f83d30586c7914b121c
7
+ data.tar.gz: 934dbe15c427f51d1638b3aff0c9e653001f8eef3407133a62947232ab4305b57aafe82b9f8b50ad4314abf2512f1e8f213a01930377349396d3f95950156250
data/README.md CHANGED
@@ -2,9 +2,8 @@ Madman
2
2
  ==================================================
3
3
 
4
4
  [![Gem Version](https://badge.fury.io/rb/madman.svg)](https://badge.fury.io/rb/madman)
5
- [![Build Status](https://travis-ci.com/DannyBen/madman.svg?branch=master)](https://travis-ci.com/DannyBen/madman)
5
+ [![Build Status](https://github.com/DannyBen/madman/workflows/Test/badge.svg)](https://github.com/DannyBen/madman/actions?query=workflow%3ATest)
6
6
  [![Maintainability](https://api.codeclimate.com/v1/badges/506449ea988f5518425d/maintainability)](https://codeclimate.com/github/DannyBen/madman/maintainability)
7
- [![Test Coverage](https://api.codeclimate.com/v1/badges/506449ea988f5518425d/test_coverage)](https://codeclimate.com/github/DannyBen/madman/test_coverage)
8
7
 
9
8
 
10
9
  ---
@@ -41,6 +40,7 @@ Features
41
40
  compatibility.
42
41
  - [x] Automatic detection of Right-to-Left markdown files for HTML rendering.
43
42
  - [x] Generate navigation README in folders without one.
43
+ - [x] Convert YAML file to an interactive HTML with collapsible sections.
44
44
  - [ ] Generate breadcrumbs.
45
45
  - [ ] Combine multiple markdown files to one.
46
46
  - [ ] Table of Contents generation for a single file.
@@ -56,15 +56,15 @@ Usage
56
56
  $ madman
57
57
  Commands:
58
58
  nav Add site-wide navigation links to README files
59
- preview Serve a markdown file using a local server
59
+ preview Serve a markdown or YAML file using a local server
60
60
  readme Create README in all qualified sub directories
61
- render Render markdown to HTML
61
+ render Render markdown or YAML to HTML
62
62
  serve Serve a markdown directory using a local server
63
63
  ```
64
64
 
65
65
  <!-- usage -->
66
66
 
67
- ### Render Markdown to File
67
+ ### Render Markdown or YAML to HTML
68
68
 
69
69
  <!-- render -->
70
70
 
@@ -82,7 +82,7 @@ Usage:
82
82
 
83
83
  ```
84
84
  $ madman render --help
85
- Render markdown to HTML
85
+ Render markdown or YAML to HTML
86
86
 
87
87
  Usage:
88
88
  madman render FILE [--github --save OUTFILE]
@@ -101,7 +101,7 @@ Options:
101
101
 
102
102
  Parameters:
103
103
  FILE
104
- The input markdown file
104
+ The input markdown or YAML file
105
105
 
106
106
  Environment Variables:
107
107
  GITHUB_ACCESS_TOKEN
@@ -112,12 +112,13 @@ Examples:
112
112
  madman render README.md
113
113
  madman render README.md --github
114
114
  madman render README.md --save out.html
115
+ madman render file.yml --save out.html
115
116
  ```
116
117
 
117
118
  <!-- render-help -->
118
119
  </details>
119
120
 
120
- ### Preview Markdown in Browser
121
+ ### Preview Markdown or HTML in Browser
121
122
 
122
123
  <!-- preview -->
123
124
 
@@ -134,7 +135,7 @@ Usage:
134
135
 
135
136
  ```
136
137
  $ madman preview --help
137
- Serve a markdown file using a local server
138
+ Serve a markdown or YAML file using a local server
138
139
 
139
140
  This command will start a local server with two endpoints:
140
141
  / will render the markdown with the default renderer
@@ -156,7 +157,7 @@ Options:
156
157
 
157
158
  Parameters:
158
159
  FILE
159
- The input markdown file
160
+ The input markdown or YAML file
160
161
 
161
162
  Environment Variables:
162
163
  GITHUB_ACCESS_TOKEN
@@ -167,6 +168,7 @@ Environment Variables:
167
168
  Examples:
168
169
  madman preview README.md
169
170
  madman preview README.md -p4000
171
+ madman preview file.yml
170
172
  ```
171
173
 
172
174
  <!-- preview-help --></details>
data/bin/madman CHANGED
@@ -1,6 +1,8 @@
1
1
  #!/usr/bin/env ruby
2
2
  require 'madman'
3
3
  require 'madman/cli'
4
+ require 'colsole'
5
+ include Colsole
4
6
 
5
7
  runner = Madman::CLI.runner
6
8
 
@@ -1,23 +1,12 @@
1
+ require 'byebug' if ENV['BYEBUG']
1
2
  require 'commonmarker'
3
+ require 'mister_bin'
2
4
  require 'octokit'
5
+ require 'requires'
3
6
  require 'sinatra/base'
4
- require 'sinatra/reloader'
7
+ # require 'sinatra/reloader'
5
8
  require 'slim'
6
9
  require 'string-direction'
10
+ require 'yaml'
7
11
 
8
- require 'madman/version'
9
- require 'madman/cli'
10
- require 'madman/injector'
11
-
12
- require 'madman/directory'
13
- require 'madman/document'
14
- require 'madman/item'
15
- require 'madman/renderers'
16
- require 'madman/navigation'
17
-
18
- require 'madman/server_base'
19
- require 'madman/preview_server'
20
- require 'madman/dir_server'
21
-
22
-
23
- require 'byebug' if ENV['BYEBUG']
12
+ requires 'madman'
@@ -1,4 +1,3 @@
1
- require 'mister_bin'
2
1
  require 'madman/commands'
3
2
 
4
3
  module Madman
@@ -26,9 +26,7 @@ module Madman
26
26
  example "madman nav path/to/docs --force --marker toc"
27
27
  example "madman nav path/to/docs --dry -v -d2"
28
28
 
29
- def run(args)
30
- @args = args
31
-
29
+ def run
32
30
  if recursive?
33
31
  Dir["#{dir}/**/#{target}"].each { |file| update_file file }
34
32
  else
@@ -55,15 +53,14 @@ module Madman
55
53
 
56
54
  # CLI Arguments
57
55
 
58
- def args; @args; end
59
- def dir; args['DIR'] || '.'; end
60
- def depth; args['--depth'].to_i; end
61
- def marker; args['--marker']; end
62
- def target; args['--target']; end
63
- def force?; args['--force']; end
64
- def dry?; args['--dry']; end
65
- def verbose?; args['--verbose']; end
66
- def recursive?; args['--recursive']; end
56
+ def dir; args['DIR'] || '.'; end
57
+ def depth; args['--depth'].to_i; end
58
+ def marker; args['--marker']; end
59
+ def target; args['--target']; end
60
+ def force?; args['--force']; end
61
+ def dry?; args['--dry']; end
62
+ def verbose?; args['--verbose']; end
63
+ def recursive?; args['--recursive']; end
67
64
 
68
65
  end
69
66
  end
@@ -3,7 +3,7 @@ module Madman
3
3
  class Preview < MisterBin::Command
4
4
  include Colsole
5
5
 
6
- summary "Serve a markdown file using a local server"
6
+ summary "Serve a markdown or YAML file using a local server"
7
7
 
8
8
  help "This command will start a local server with two endpoints:\n / will render the markdown with the default renderer\n /github will render with the GitHub API"
9
9
 
@@ -13,14 +13,15 @@ module Madman
13
13
  option "-p --port N", "Set server port [default: 3000]"
14
14
  option "-b --bind ADDRESS", "Set server listen address [default: 0.0.0.0]"
15
15
 
16
- param "FILE", "The input markdown file"
16
+ param "FILE", "The input markdown or YAML file"
17
17
 
18
18
  environment "GITHUB_ACCESS_TOKEN", "Your GitHub API access token\nRequired only if you wish to use the '/github' endpoint\nGenerate one here: https://github.com/settings/tokens"
19
19
 
20
20
  example "madman preview README.md"
21
21
  example "madman preview README.md -p4000"
22
+ example "madman preview file.yml"
22
23
 
23
- def run(args)
24
+ def run
24
25
  file = args['FILE']
25
26
  port = args['--port']
26
27
  bind = args['--bind']
@@ -17,9 +17,9 @@ module Madman
17
17
  example "madman readme ."
18
18
  example "madman readme path/to/docs --dry"
19
19
 
20
- def run(args)
20
+ def run
21
21
  dir = args['DIR']
22
- basedir = Madman::Directory.new dir, dir
22
+ basedir = Madman::Directory.new dir
23
23
 
24
24
  dirs = basedir.deep_list.select { |i| i.dir? }.map { |i| i.path }
25
25
  dirs.each do |dir|
@@ -3,7 +3,7 @@ module Madman
3
3
  class Render < MisterBin::Command
4
4
  include Colsole
5
5
 
6
- help "Render markdown to HTML"
6
+ help "Render markdown or YAML to HTML"
7
7
 
8
8
  usage "madman render FILE [--github --save OUTFILE]"
9
9
  usage "madman render (-h|--help)"
@@ -11,15 +11,16 @@ module Madman
11
11
  option "--github", "Render using the GitHub API\nRequires setting the GITHUB_ACCESS_TOKEN environment variable"
12
12
  option "--save OUTFILE", "Save the output to a file"
13
13
 
14
- param "FILE", "The input markdown file"
14
+ param "FILE", "The input markdown or YAML file"
15
15
 
16
16
  environment "GITHUB_ACCESS_TOKEN", "Your GitHub API access token\nGenerate one here: https://github.com/settings/tokens"
17
17
 
18
18
  example "madman render README.md"
19
19
  example "madman render README.md --github"
20
20
  example "madman render README.md --save out.html"
21
+ example "madman render file.yml --save out.html"
21
22
 
22
- def run(args)
23
+ def run
23
24
  infile = args['FILE']
24
25
  outfile = args['--save']
25
26
  renderer = args['--github'] ? :github : :default
@@ -19,7 +19,7 @@ module Madman
19
19
  example "madman serve"
20
20
  example "madman serve path/to/docs -p4000 --github"
21
21
 
22
- def run(args)
22
+ def run
23
23
  dir = args['DIR']
24
24
  port = args['--port']
25
25
  bind = args['--bind']
@@ -1,3 +1,5 @@
1
+ require 'madman/server_base'
2
+
1
3
  module Madman
2
4
  class DirServer < ServerBase
3
5
  set :public_folder, -> { File.expand_path(settings.dir) }
@@ -6,17 +8,31 @@ module Madman
6
8
  @renderer = settings.respond_to?(:renderer) ? settings.renderer : :default
7
9
  end
8
10
 
11
+ not_found do
12
+ content_type :text
13
+ "4O4 Not Found"
14
+ end
15
+
16
+ get '/favicon.ico' do
17
+ content_type :text
18
+ '(oOo)'
19
+ end
20
+
9
21
  get '/*' do
10
22
  path = params[:splat].first
11
23
 
12
24
  type, file = find_file(path)
13
25
  redirect "#{path}/" if type == :dir and path[-1] != '/'
14
26
 
15
- @doc = Document.from_file file
16
- slim :template
27
+ if File.exist? file
28
+ @doc = Document.from_file file
29
+ slim :template
30
+ else
31
+ halt 404
32
+ end
17
33
  end
18
34
 
19
- private
35
+ private
20
36
 
21
37
  def find_file(path)
22
38
  type = :file
@@ -1,9 +1,9 @@
1
1
  module Madman
2
- # Represents a directory with markdown file sand subflders.
2
+ # Represents a directory with markdown files and subflders.
3
3
  class Directory
4
4
  attr_reader :dir, :basedir
5
5
 
6
- def initialize(dir, basedir=nil)
6
+ def initialize(dir, basedir = nil)
7
7
  @dir = dir
8
8
  @basedir = basedir || dir
9
9
  end
@@ -20,7 +20,7 @@ module Madman
20
20
  result
21
21
  end
22
22
 
23
- private
23
+ private
24
24
 
25
25
  def files
26
26
  result = Dir["#{dir}/*.md"]
@@ -1,12 +1,21 @@
1
+ require 'madman/injector'
2
+ require 'madman/renderers'
3
+
1
4
  module Madman
2
5
  class Document
3
6
  include Injector
4
7
 
5
8
  attr_reader :filename
6
- attr_accessor :text
9
+ attr_accessor :text, :yaml_mode
7
10
 
8
11
  def self.from_file(file)
9
- new File.read(file), file
12
+ if File.extname(file) == '.yml'
13
+ result = new YAML.load_file(file), file
14
+ result.yaml_mode = true
15
+ result
16
+ else
17
+ new File.read(file), file
18
+ end
10
19
  end
11
20
 
12
21
  def initialize(text, filename=nil)
@@ -15,7 +24,11 @@ module Madman
15
24
  end
16
25
 
17
26
  def render(renderer=:default)
18
- renderers[renderer].render text
27
+ if yaml_mode
28
+ renderers[:yaml].render text, title: File.basename(filename, '.yml')
29
+ else
30
+ renderers[renderer].render text
31
+ end
19
32
  end
20
33
 
21
34
  def rtl?
@@ -28,7 +41,7 @@ module Madman
28
41
  File.write save_as, text
29
42
  end
30
43
 
31
- private
44
+ private
32
45
 
33
46
  def detector
34
47
  @detector ||= StringDirection::Detector.new :dominant
@@ -1,3 +1,5 @@
1
+ require 'addressable'
2
+
1
3
  module Madman
2
4
  class Item
3
5
  attr_reader :path, :type, :basedir
@@ -11,7 +13,7 @@ module Madman
11
13
  end
12
14
 
13
15
  def href
14
- URI.escape(path_without_extension.sub(/^#{basedir}\//, ''))
16
+ Addressable::URI.escape(path_without_extension.sub(/^#{basedir}\//, ''))
15
17
  end
16
18
 
17
19
  def dir?
@@ -22,7 +24,7 @@ module Madman
22
24
  type == :file
23
25
  end
24
26
 
25
- private
27
+ private
26
28
 
27
29
  def path_without_extension
28
30
  @path_without_extension ||= path.sub(/\.md$/, '')
@@ -1,3 +1,5 @@
1
+ require 'madman/directory'
2
+
1
3
  module Madman
2
4
  # Generate a markdown Table of Contents
3
5
  class Navigation
@@ -15,7 +17,7 @@ module Madman
15
17
  @markdown ||= markdown!
16
18
  end
17
19
 
18
- private
20
+ private
19
21
 
20
22
  def markdown!
21
23
  result = []
@@ -1,3 +1,6 @@
1
+ require 'madman/server_base'
2
+ require 'madman/document'
3
+
1
4
  module Madman
2
5
  class PreviewServer < ServerBase
3
6
  set :public_folder, -> { File.expand_path(File.dirname(settings.file)) }
@@ -0,0 +1,11 @@
1
+ module StringRefinements
2
+ refine String do
3
+ def slug
4
+ downcase.strip.gsub(' ', '-').gsub(/[^\w-]/, '')
5
+ end
6
+
7
+ def to_html
8
+ CommonMarker.render_html self, :DEFAULT, [:table]
9
+ end
10
+ end
11
+ end
@@ -1,11 +1,13 @@
1
1
  require 'madman/renderers/default'
2
2
  require 'madman/renderers/github'
3
+ require 'madman/renderers/yaml'
3
4
 
4
5
  module Madman
5
6
  module Renderers
6
7
  def self.available_renderers
7
8
  {
8
9
  default: Renderers::Default,
10
+ yaml: Renderers::YAML,
9
11
  github: Renderers::GitHub,
10
12
  }
11
13
  end
@@ -2,7 +2,7 @@ module Madman
2
2
  module Renderers
3
3
  class Default
4
4
  def self.render(text, opts={})
5
- CommonMarker.render_html text, :DEFAULT, [:table]
5
+ CommonMarker.render_html text, [:DEFAULT, :UNSAFE], [:table]
6
6
  end
7
7
  end
8
8
  end
@@ -5,7 +5,7 @@ module Madman
5
5
  client.markdown text
6
6
  end
7
7
 
8
- private
8
+ private
9
9
 
10
10
  def self.client
11
11
  Octokit::Client.new access_token: access_token
@@ -0,0 +1,12 @@
1
+ module Madman
2
+ module Renderers
3
+ class YAML
4
+ def self.render(yaml, opts={})
5
+ doc = YAMLDoc.new yaml, title: opts[:title]
6
+ doc.render
7
+ end
8
+ end
9
+ end
10
+ end
11
+
12
+
@@ -4,10 +4,13 @@ module Madman
4
4
 
5
5
  Slim::Engine.set_options pretty: true
6
6
 
7
- configure :development do
8
- register Sinatra::Reloader
9
- also_reload "#{__dir__}/*.rb"
10
- end
7
+ # Reloader temporarily removed due to
8
+ # https://github.com/sinatra/sinatra/issues/1587
9
+ #
10
+ # configure :development do
11
+ # register Sinatra::Reloader
12
+ # also_reload "#{__dir__}/*.rb"
13
+ # end
11
14
 
12
15
  get '/favicon.ico' do
13
16
  end
@@ -1,3 +1,3 @@
1
1
  module Madman
2
- VERSION = "0.2.2"
2
+ VERSION = "0.2.9"
3
3
  end
@@ -0,0 +1,76 @@
1
+ require 'madman/refinements/string'
2
+
3
+ module Madman
4
+ class YAMLDoc
5
+ using StringRefinements
6
+
7
+ attr_reader :yaml, :title
8
+
9
+ def initialize(yaml, title: nil)
10
+ @yaml = yaml
11
+ @title = title
12
+ end
13
+
14
+ def render
15
+ slim.render self
16
+ end
17
+
18
+ def template
19
+ File.expand_path '../views/yamldoc.slim', __dir__
20
+ end
21
+
22
+ def slim
23
+ @slim ||= Slim::Template.new template, slim_options
24
+ end
25
+
26
+ def slim_options
27
+ { pretty: true, disable_escape: true }
28
+ end
29
+
30
+ def tree
31
+ @tree ||= tree!
32
+ end
33
+
34
+ private
35
+
36
+ def counter
37
+ @counter ||= 0
38
+ @counter += 1
39
+ end
40
+
41
+ def tree!(data=nil, indent=0, caption=2)
42
+ data ||= yaml
43
+ result = []
44
+ caption = 6 if caption > 6
45
+
46
+ data.each do |key, value|
47
+ result.push render_pair key, value, indent, caption
48
+ end
49
+
50
+ result.join "\n"
51
+ end
52
+
53
+ def render_pair(key, value, indent, caption)
54
+ slug = "#{key.slug}-#{counter}"
55
+ space = ' '
56
+ result = []
57
+
58
+ if key[0] == '_'
59
+ result.push "#{space * indent}<div>"
60
+ else
61
+ result.push "#{space * indent}<h#{caption}><a href='##{slug}' class='clickable'>#{key}</a></h#{caption}>"
62
+ result.push "#{space * indent}<div class='hidden' id='#{slug}'>"
63
+ end
64
+
65
+ if value.is_a? Hash
66
+ result.push tree!(value, indent+1, caption+1)
67
+ elsif value
68
+ result.push "#{space * (indent+1)}#{value.to_html}"
69
+ end
70
+
71
+ result.push "#{space * indent}</div>"
72
+ result
73
+ end
74
+
75
+ end
76
+ end
@@ -2,10 +2,9 @@ doctype html
2
2
  html
3
3
  head
4
4
  meta name="viewport" content="width=device-width, initial-scale=1"
5
-
6
- body
7
5
  link href='https://cdnjs.cloudflare.com/ajax/libs/github-markdown-css/2.10.0/github-markdown.min.css' rel='stylesheet' type='text/css'
8
6
 
7
+ body
9
8
  css:
10
9
  .markdown-body {
11
10
  box-sizing: border-box;
@@ -0,0 +1,52 @@
1
+ doctype html
2
+ html
3
+ head
4
+ meta name="viewport" content="width=device-width, initial-scale=1"
5
+ script src="https://code.jquery.com/jquery-3.3.1.min.js"integrity="sha256-FgpCb/KJQlLNfOu91ta32o/NMZxltwRo8QtmkMRdAu8="crossorigin="anonymous"
6
+ link href='https://cdnjs.cloudflare.com/ajax/libs/github-markdown-css/2.10.0/github-markdown.min.css' rel='stylesheet' type='text/css'
7
+
8
+ body
9
+
10
+ scss:
11
+ .markdown-body {
12
+ box-sizing: border-box;
13
+ min-width: 200px;
14
+ max-width: 980px;
15
+ margin: 0 auto;
16
+ padding: 45px;
17
+ }
18
+
19
+ @media (max-width: 767px) {
20
+ .markdown-body {
21
+ padding: 15px;
22
+ }
23
+ }
24
+
25
+ .s:hover {
26
+ cursor: pointer;
27
+ }
28
+
29
+ .hidden {
30
+ display: none;
31
+ margin-left: 10px;
32
+ }
33
+
34
+
35
+ .markdown-body
36
+ h1
37
+ a#toggle-all href='#' = title
38
+
39
+ == tree
40
+
41
+
42
+ coffee:
43
+ $ ->
44
+ $('.clickable').on "click", (e) ->
45
+ e.preventDefault()
46
+ target = $(this).attr 'href'
47
+ $(target).toggle()
48
+
49
+ $('#toggle-all').on "click", (e) ->
50
+ e.preventDefault()
51
+ $('.hidden').toggle()
52
+
metadata CHANGED
@@ -1,281 +1,183 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: madman
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.2.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Danny Ben Shitrit
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-09-20 00:00:00.000000000 Z
11
+ date: 2020-06-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: sinatra
15
- requirement: !ruby/object:Gem::Requirement
16
- requirements:
17
- - - '='
18
- - !ruby/object:Gem::Version
19
- version: 2.0.3
20
- type: :runtime
21
- prerelease: false
22
- version_requirements: !ruby/object:Gem::Requirement
23
- requirements:
24
- - - '='
25
- - !ruby/object:Gem::Version
26
- version: 2.0.3
27
- - !ruby/object:Gem::Dependency
28
- name: commonmarker
29
15
  requirement: !ruby/object:Gem::Requirement
30
16
  requirements:
31
17
  - - "~>"
32
18
  - !ruby/object:Gem::Version
33
- version: '0.17'
19
+ version: 2.0.5
34
20
  type: :runtime
35
21
  prerelease: false
36
22
  version_requirements: !ruby/object:Gem::Requirement
37
23
  requirements:
38
24
  - - "~>"
39
25
  - !ruby/object:Gem::Version
40
- version: '0.17'
26
+ version: 2.0.5
41
27
  - !ruby/object:Gem::Dependency
42
- name: mister_bin
28
+ name: requires
43
29
  requirement: !ruby/object:Gem::Requirement
44
30
  requirements:
45
31
  - - "~>"
46
32
  - !ruby/object:Gem::Version
47
- version: '0.3'
33
+ version: '0.1'
48
34
  type: :runtime
49
35
  prerelease: false
50
36
  version_requirements: !ruby/object:Gem::Requirement
51
37
  requirements:
52
38
  - - "~>"
53
39
  - !ruby/object:Gem::Version
54
- version: '0.3'
40
+ version: '0.1'
55
41
  - !ruby/object:Gem::Dependency
56
- name: puma
42
+ name: commonmarker
57
43
  requirement: !ruby/object:Gem::Requirement
58
44
  requirements:
59
45
  - - "~>"
60
46
  - !ruby/object:Gem::Version
61
- version: '3.11'
47
+ version: '0.20'
62
48
  type: :runtime
63
49
  prerelease: false
64
50
  version_requirements: !ruby/object:Gem::Requirement
65
51
  requirements:
66
52
  - - "~>"
67
53
  - !ruby/object:Gem::Version
68
- version: '3.11'
54
+ version: '0.20'
69
55
  - !ruby/object:Gem::Dependency
70
- name: sinatra-contrib
56
+ name: mister_bin
71
57
  requirement: !ruby/object:Gem::Requirement
72
58
  requirements:
73
59
  - - "~>"
74
60
  - !ruby/object:Gem::Version
75
- version: '2.0'
61
+ version: '0.6'
76
62
  type: :runtime
77
63
  prerelease: false
78
64
  version_requirements: !ruby/object:Gem::Requirement
79
65
  requirements:
80
66
  - - "~>"
81
67
  - !ruby/object:Gem::Version
82
- version: '2.0'
68
+ version: '0.6'
83
69
  - !ruby/object:Gem::Dependency
84
- name: slim
70
+ name: puma
85
71
  requirement: !ruby/object:Gem::Requirement
86
72
  requirements:
87
73
  - - "~>"
88
74
  - !ruby/object:Gem::Version
89
- version: '3.0'
75
+ version: '4.0'
90
76
  type: :runtime
91
77
  prerelease: false
92
78
  version_requirements: !ruby/object:Gem::Requirement
93
79
  requirements:
94
80
  - - "~>"
95
81
  - !ruby/object:Gem::Version
96
- version: '3.0'
82
+ version: '4.0'
97
83
  - !ruby/object:Gem::Dependency
98
- name: string-direction
84
+ name: slim
99
85
  requirement: !ruby/object:Gem::Requirement
100
86
  requirements:
101
87
  - - "~>"
102
88
  - !ruby/object:Gem::Version
103
- version: '1.2'
89
+ version: '4.0'
104
90
  type: :runtime
105
91
  prerelease: false
106
92
  version_requirements: !ruby/object:Gem::Requirement
107
93
  requirements:
108
94
  - - "~>"
109
95
  - !ruby/object:Gem::Version
110
- version: '1.2'
96
+ version: '4.0'
111
97
  - !ruby/object:Gem::Dependency
112
- name: octokit
98
+ name: colsole
113
99
  requirement: !ruby/object:Gem::Requirement
114
100
  requirements:
115
101
  - - "~>"
116
102
  - !ruby/object:Gem::Version
117
- version: '4.9'
103
+ version: '0.5'
118
104
  type: :runtime
119
105
  prerelease: false
120
106
  version_requirements: !ruby/object:Gem::Requirement
121
107
  requirements:
122
108
  - - "~>"
123
109
  - !ruby/object:Gem::Version
124
- version: '4.9'
125
- - !ruby/object:Gem::Dependency
126
- name: byebug
127
- requirement: !ruby/object:Gem::Requirement
128
- requirements:
129
- - - "~>"
130
- - !ruby/object:Gem::Version
131
- version: '10.0'
132
- type: :development
133
- prerelease: false
134
- version_requirements: !ruby/object:Gem::Requirement
135
- requirements:
136
- - - "~>"
137
- - !ruby/object:Gem::Version
138
- version: '10.0'
139
- - !ruby/object:Gem::Dependency
140
- name: lp
141
- requirement: !ruby/object:Gem::Requirement
142
- requirements:
143
- - - "~>"
144
- - !ruby/object:Gem::Version
145
- version: '0.0'
146
- type: :development
147
- prerelease: false
148
- version_requirements: !ruby/object:Gem::Requirement
149
- requirements:
150
- - - "~>"
151
- - !ruby/object:Gem::Version
152
- version: '0.0'
153
- - !ruby/object:Gem::Dependency
154
- name: rack-test
155
- requirement: !ruby/object:Gem::Requirement
156
- requirements:
157
- - - "~>"
158
- - !ruby/object:Gem::Version
159
- version: '1.0'
160
- type: :development
161
- prerelease: false
162
- version_requirements: !ruby/object:Gem::Requirement
163
- requirements:
164
- - - "~>"
165
- - !ruby/object:Gem::Version
166
- version: '1.0'
110
+ version: '0.5'
167
111
  - !ruby/object:Gem::Dependency
168
- name: rdoc
169
- requirement: !ruby/object:Gem::Requirement
170
- requirements:
171
- - - "~>"
172
- - !ruby/object:Gem::Version
173
- version: '6.0'
174
- type: :development
175
- prerelease: false
176
- version_requirements: !ruby/object:Gem::Requirement
177
- requirements:
178
- - - "~>"
179
- - !ruby/object:Gem::Version
180
- version: '6.0'
181
- - !ruby/object:Gem::Dependency
182
- name: rspec
183
- requirement: !ruby/object:Gem::Requirement
184
- requirements:
185
- - - "~>"
186
- - !ruby/object:Gem::Version
187
- version: '3.6'
188
- type: :development
189
- prerelease: false
190
- version_requirements: !ruby/object:Gem::Requirement
191
- requirements:
192
- - - "~>"
193
- - !ruby/object:Gem::Version
194
- version: '3.6'
195
- - !ruby/object:Gem::Dependency
196
- name: rspec-html-matchers
197
- requirement: !ruby/object:Gem::Requirement
198
- requirements:
199
- - - "~>"
200
- - !ruby/object:Gem::Version
201
- version: '0.9'
202
- type: :development
203
- prerelease: false
204
- version_requirements: !ruby/object:Gem::Requirement
205
- requirements:
206
- - - "~>"
207
- - !ruby/object:Gem::Version
208
- version: '0.9'
209
- - !ruby/object:Gem::Dependency
210
- name: rspec_fixtures
112
+ name: string-direction
211
113
  requirement: !ruby/object:Gem::Requirement
212
114
  requirements:
213
115
  - - "~>"
214
116
  - !ruby/object:Gem::Version
215
- version: '0.3'
216
- type: :development
117
+ version: '1.2'
118
+ type: :runtime
217
119
  prerelease: false
218
120
  version_requirements: !ruby/object:Gem::Requirement
219
121
  requirements:
220
122
  - - "~>"
221
123
  - !ruby/object:Gem::Version
222
- version: '0.3'
124
+ version: '1.2'
223
125
  - !ruby/object:Gem::Dependency
224
- name: runfile
126
+ name: octokit
225
127
  requirement: !ruby/object:Gem::Requirement
226
128
  requirements:
227
129
  - - "~>"
228
130
  - !ruby/object:Gem::Version
229
- version: '0.10'
230
- type: :development
131
+ version: '4.14'
132
+ type: :runtime
231
133
  prerelease: false
232
134
  version_requirements: !ruby/object:Gem::Requirement
233
135
  requirements:
234
136
  - - "~>"
235
137
  - !ruby/object:Gem::Version
236
- version: '0.10'
138
+ version: '4.14'
237
139
  - !ruby/object:Gem::Dependency
238
- name: runfile-tasks
140
+ name: sass
239
141
  requirement: !ruby/object:Gem::Requirement
240
142
  requirements:
241
143
  - - "~>"
242
144
  - !ruby/object:Gem::Version
243
- version: '0.4'
244
- type: :development
145
+ version: '3.7'
146
+ type: :runtime
245
147
  prerelease: false
246
148
  version_requirements: !ruby/object:Gem::Requirement
247
149
  requirements:
248
150
  - - "~>"
249
151
  - !ruby/object:Gem::Version
250
- version: '0.4'
152
+ version: '3.7'
251
153
  - !ruby/object:Gem::Dependency
252
- name: simplecov
154
+ name: coffee-script
253
155
  requirement: !ruby/object:Gem::Requirement
254
156
  requirements:
255
157
  - - "~>"
256
158
  - !ruby/object:Gem::Version
257
- version: '0.15'
258
- type: :development
159
+ version: '2.4'
160
+ type: :runtime
259
161
  prerelease: false
260
162
  version_requirements: !ruby/object:Gem::Requirement
261
163
  requirements:
262
164
  - - "~>"
263
165
  - !ruby/object:Gem::Version
264
- version: '0.15'
166
+ version: '2.4'
265
167
  - !ruby/object:Gem::Dependency
266
- name: yard
168
+ name: addressable
267
169
  requirement: !ruby/object:Gem::Requirement
268
170
  requirements:
269
171
  - - "~>"
270
172
  - !ruby/object:Gem::Version
271
- version: '0.9'
272
- type: :development
173
+ version: '2.7'
174
+ type: :runtime
273
175
  prerelease: false
274
176
  version_requirements: !ruby/object:Gem::Requirement
275
177
  requirements:
276
178
  - - "~>"
277
179
  - !ruby/object:Gem::Version
278
- version: '0.9'
180
+ version: '2.7'
279
181
  description: A command line utility for markdown fun
280
182
  email: db@dannyben.com
281
183
  executables:
@@ -300,12 +202,16 @@ files:
300
202
  - lib/madman/item.rb
301
203
  - lib/madman/navigation.rb
302
204
  - lib/madman/preview_server.rb
205
+ - lib/madman/refinements/string.rb
303
206
  - lib/madman/renderers.rb
304
207
  - lib/madman/renderers/default.rb
305
208
  - lib/madman/renderers/github.rb
209
+ - lib/madman/renderers/yaml.rb
306
210
  - lib/madman/server_base.rb
307
211
  - lib/madman/version.rb
212
+ - lib/madman/yamldoc.rb
308
213
  - lib/views/template.slim
214
+ - lib/views/yamldoc.slim
309
215
  homepage: https://github.com/dannyben/madman
310
216
  licenses:
311
217
  - MIT
@@ -325,8 +231,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
325
231
  - !ruby/object:Gem::Version
326
232
  version: '0'
327
233
  requirements: []
328
- rubyforge_project:
329
- rubygems_version: 2.7.6
234
+ rubygems_version: 3.1.2
330
235
  signing_key:
331
236
  specification_version: 4
332
237
  summary: The Markdown Swiss Army Knife