mdify 0.4 → 1.2.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: 15c8dae4e789eec972f8c5ef455dc63155e93f63984c2427cab2d6411679a361
4
+ data.tar.gz: c7926861ce23542198b59dc86c29ea4c53dbc69c4d68fbd915c4bf3de9ffd7e7
5
+ SHA512:
6
+ metadata.gz: ccf29107ed7fccac12d83c0780f378e10ea06559b51c598d87a675dca75b7ee17276f60e31b006b56c03f0740bf75e5ca78924f93b84df96eacc8b3b40d99182
7
+ data.tar.gz: 71b83c49acdeaf73a03bef93a27fd50c847de2cc32af86c301245cbbe6acff03a7e96787e9cebadff42b893ef8cf4a1519993358f1788a69fc9e624cb21e0150
@@ -1,11 +1,17 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- mdify (0.1)
4
+ mdify (1.0.1)
5
+ launchy
6
+ redcarpet (~> 1.9)
5
7
 
6
8
  GEM
7
9
  remote: http://rubygems.org/
8
10
  specs:
11
+ addressable (2.2.6)
12
+ launchy (2.0.5)
13
+ addressable (~> 2.2.6)
14
+ redcarpet (1.17.2)
9
15
 
10
16
  PLATFORMS
11
17
  ruby
@@ -6,7 +6,7 @@ require 'launchy'
6
6
  require 'mdify/renderer'
7
7
 
8
8
  module Mdify
9
- VERSION = "0.4"
9
+ VERSION = "1.2.0"
10
10
 
11
11
  def self.preview(filename)
12
12
  Renderer.new(filename).render
@@ -13,7 +13,11 @@ module Mdify
13
13
  html = Redcarpet.new(@content).to_html
14
14
  document = render_html(@title, html)
15
15
  temp_file = create_temp_file(document)
16
- exec "launchy #{temp_file}"
16
+ if RUBY_PLATFORM.downcase.include?("darwin")
17
+ exec "open #{temp_file}"
18
+ else
19
+ exec "launchy #{temp_file}"
20
+ end
17
21
  end
18
22
 
19
23
  protected
@@ -7,10 +7,9 @@ Gem::Specification.new do |s|
7
7
  ## If your rubyforge_project name is different, then edit it and comment out
8
8
  ## the sub! line in the Rakefile
9
9
  s.name = 'mdify'
10
- s.version = '0.4'
11
- s.date = '2011-11-29'
12
- s.rubyforge_project = 'mdify'
13
-
10
+ s.version = '1.2.0'
11
+ s.date = '2020-12-16'
12
+ s.licenses = ['MIT']
14
13
  ## Make sure your summary is short. The description may be as long
15
14
  ## as you like.
16
15
  s.summary = "Preview Markdown documents with your browser"
@@ -32,8 +31,8 @@ Gem::Specification.new do |s|
32
31
 
33
32
  ## List your runtime dependencies here. Runtime dependencies are those
34
33
  ## that are needed for an end user to actually USE your code.
35
- s.add_dependency("redcarpet")
36
- s.add_dependency("launchy")
34
+ s.add_dependency("redcarpet", "~> 1.9")
35
+ s.add_dependency("launchy", "~> 2.0")
37
36
 
38
37
  ## List your development dependencies here. Development dependencies are
39
38
  ## those that are only needed during development
@@ -2,12 +2,6 @@
2
2
  <head>
3
3
  <meta charset="utf-8">
4
4
  <title>{{ title }}</title>
5
- <link rel="stylesheet" href="http://twitter.github.com/bootstrap/1.3.0/bootstrap.css">
6
- <style>
7
- body { padding: 30px; width: 960px; }
8
- code { background-color: #f5f5f5; }
9
- h2 { margin-bottom: 10px; }
10
- </style>
11
5
  </head>
12
6
  <body>
13
7
  {{ body }}
metadata CHANGED
@@ -1,58 +1,51 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: mdify
3
- version: !ruby/object:Gem::Version
4
- hash: 3
5
- prerelease:
6
- segments:
7
- - 0
8
- - 4
9
- version: "0.4"
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.2.0
10
5
  platform: ruby
11
- authors:
6
+ authors:
12
7
  - Federico Builes
13
- autorequire:
8
+ autorequire:
14
9
  bindir: bin
15
10
  cert_chain: []
16
-
17
- date: 2011-11-29 00:00:00 Z
18
- dependencies:
19
- - !ruby/object:Gem::Dependency
11
+ date: 2020-12-16 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
20
14
  name: redcarpet
21
- prerelease: false
22
- requirement: &id001 !ruby/object:Gem::Requirement
23
- none: false
24
- requirements:
25
- - - ">="
26
- - !ruby/object:Gem::Version
27
- hash: 3
28
- segments:
29
- - 0
30
- version: "0"
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.9'
31
20
  type: :runtime
32
- version_requirements: *id001
33
- - !ruby/object:Gem::Dependency
34
- name: launchy
35
21
  prerelease: false
36
- requirement: &id002 !ruby/object:Gem::Requirement
37
- none: false
38
- requirements:
39
- - - ">="
40
- - !ruby/object:Gem::Version
41
- hash: 3
42
- segments:
43
- - 0
44
- version: "0"
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.9'
27
+ - !ruby/object:Gem::Dependency
28
+ name: launchy
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '2.0'
45
34
  type: :runtime
46
- version_requirements: *id002
47
- description: mdify is a tool for previewing Markdown documents right in your browser, with a nice stylesheet.
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '2.0'
41
+ description: mdify is a tool for previewing Markdown documents right in your browser,
42
+ with a nice stylesheet.
48
43
  email: federico.builes@gmail.com
49
- executables:
44
+ executables:
50
45
  - mdify
51
46
  extensions: []
52
-
53
47
  extra_rdoc_files: []
54
-
55
- files:
48
+ files:
56
49
  - Gemfile
57
50
  - Gemfile.lock
58
51
  - README.md
@@ -63,37 +56,26 @@ files:
63
56
  - mdify.gemspec
64
57
  - vendor/template.html
65
58
  homepage: http://github.com/febuiles/mdify
66
- licenses: []
67
-
68
- post_install_message:
59
+ licenses:
60
+ - MIT
61
+ metadata: {}
62
+ post_install_message:
69
63
  rdoc_options: []
70
-
71
- require_paths:
64
+ require_paths:
72
65
  - lib
73
- required_ruby_version: !ruby/object:Gem::Requirement
74
- none: false
75
- requirements:
66
+ required_ruby_version: !ruby/object:Gem::Requirement
67
+ requirements:
76
68
  - - ">="
77
- - !ruby/object:Gem::Version
78
- hash: 3
79
- segments:
80
- - 0
81
- version: "0"
82
- required_rubygems_version: !ruby/object:Gem::Requirement
83
- none: false
84
- requirements:
69
+ - !ruby/object:Gem::Version
70
+ version: '0'
71
+ required_rubygems_version: !ruby/object:Gem::Requirement
72
+ requirements:
85
73
  - - ">="
86
- - !ruby/object:Gem::Version
87
- hash: 3
88
- segments:
89
- - 0
90
- version: "0"
74
+ - !ruby/object:Gem::Version
75
+ version: '0'
91
76
  requirements: []
92
-
93
- rubyforge_project: mdify
94
- rubygems_version: 1.8.10
95
- signing_key:
77
+ rubygems_version: 3.1.2
78
+ signing_key:
96
79
  specification_version: 2
97
80
  summary: Preview Markdown documents with your browser
98
81
  test_files: []
99
-