marked-conductor 1.0.35 → 1.0.38

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: 31042fe7c5635982e15c551493cf380e0d3aabae92051871144172e5890e2328
4
- data.tar.gz: 8ea8a81fb13a5342332e5c3ac779fea2dced77b34318f1e43210d1d5c388dd54
3
+ metadata.gz: d11929a623cf222dcc0fb6cb681b2292a9d00b1560651f2705935089b42c6b8f
4
+ data.tar.gz: 2162e63d939709e7a81ed1d686c7fde34024b763a05ea41ccbd17165bd4c60ec
5
5
  SHA512:
6
- metadata.gz: d8bea2c1c42bf3bf95819b1371368ad73a810860725fc2e86ccf2803c11de5de826740cd32723c5b67ccf2423e7bebb15442888e163c1fe5188924988c9b15f3
7
- data.tar.gz: b8a3881c29831dae7b37b7eeafb31acf5c34ccaf79c99e9b2bed2252a71f82575417dfe8941ba9c2d6629fad6c10511dacff6d40dd05a5022c91804720568c96
6
+ metadata.gz: f695ce001dbaae4e25e2bb03106923cf6488e90b71a5e427b0511d3cba57d395e47e6e6cd4f19c2d365a9be11edf7f4a518349950a2e90b4b7beabd94a625e51
7
+ data.tar.gz: 42092c947da449d3dc54d36f9b48e36f3a213767145f0151dce5b98a00b92c0a1ff575a8f3f8904aed43841b444dbac3ef27ed31f5140f9dabbb9e062e145537
data/CHANGELOG.md CHANGED
@@ -1,3 +1,23 @@
1
+ ### 1.0.38
2
+
3
+ 2024-08-23 11:20
4
+
5
+ ### 1.0.37
6
+
7
+ 2024-08-23 11:04
8
+
9
+ #### FIXED
10
+
11
+ - Attempt to fix installation on Ruby 2.6
12
+
13
+ ### 1.0.36
14
+
15
+ 2024-08-23 11:03
16
+
17
+ #### FIXED
18
+
19
+ - Attempt to fix installation on Ruby 2.6
20
+
1
21
  ### 1.0.35
2
22
 
3
23
  2024-08-22 10:14
data/Gemfile CHANGED
@@ -4,8 +4,3 @@ source "https://rubygems.org"
4
4
 
5
5
  # Specify your gem's dependencies in marked-conductor.gemspec
6
6
  gemspec
7
-
8
- gem "rake", "~> 13.0"
9
-
10
- gem "rubocop", "~> 1.21"
11
- gem "rspec", "~> 3.13"
data/bin/conductor CHANGED
@@ -1,29 +1,53 @@
1
- #!/usr/bin/env ruby
1
+ #!/usr/bin/env ruby -W1
2
2
  # frozen_string_literal: true
3
3
 
4
- #
5
- # This file was generated by Bundler.
6
- #
7
- # The application 'conductor' is installed as part of a gem, and
8
- # this file is here to facilitate running it.
9
- #
10
-
11
- require "pathname"
12
- ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
13
- Pathname.new(__FILE__).realpath)
14
-
15
- bundle_binstub = File.expand_path("../bundle", __FILE__)
16
-
17
- if File.file?(bundle_binstub)
18
- if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
19
- load(bundle_binstub)
20
- else
21
- abort("Your `bin/bundle` was not generated by Bundler, so this binstub cannot run.
22
- Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this command again.")
4
+ require_relative "../lib/conductor"
5
+ require "optparse"
6
+
7
+ optparse = OptionParser.new do |opts|
8
+ opts.banner = "Called from Marked 2 as a Custom Pre/Processor"
9
+
10
+ opts.on("-v", "--version", "Show version number") do
11
+ puts "conductor v#{Conductor::VERSION}"
12
+ Process.exit 0
13
+ end
14
+
15
+ opts.on("-h", "--help", "Display this screen") do
16
+ puts opts
17
+ exit
23
18
  end
24
19
  end
25
20
 
26
- require "rubygems"
27
- require "bundler/setup"
21
+ optparse.parse!
22
+
23
+ config = Conductor::Config.new
24
+ res = config.configure
25
+
26
+ Process.exit 0 unless res
28
27
 
29
- load Gem.bin_path("marked-conductor", "conductor")
28
+ Conductor.stdin
29
+ Conductor.original_input = Conductor.stdin
30
+
31
+ tracks = config.tracks
32
+ res, condition = Conductor.conduct(tracks)
33
+
34
+ ##
35
+ ## Clean up conditions for output
36
+ ##
37
+ ## @param condition The condition
38
+ ##
39
+ def clean_condition(condition)
40
+ condition.join("").sub(/ *(->|,) *$/, "")
41
+ end
42
+
43
+ if res.nil?
44
+ warn "No conditions satisfied"
45
+ # puts Conductor::Env
46
+ puts "NOCUSTOM"
47
+ elsif res == Conductor.original_input
48
+ warn "No change in output"
49
+ puts "NOCUSTOM"
50
+ else
51
+ warn "Met condition: #{clean_condition(condition)}"
52
+ puts res
53
+ end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Conductor
4
- VERSION = '1.0.35'
4
+ VERSION = '1.0.38'
5
5
  end
@@ -41,6 +41,9 @@ Gem::Specification.new do |spec|
41
41
  spec.add_development_dependency "simplecov-console", "~> 0.9"
42
42
  spec.add_development_dependency "yard", "~> 0.9", ">= 0.9.26"
43
43
 
44
+ spec.add_development_dependency "rubocop", "~> 1.21"
45
+
46
+
44
47
  # Uncomment to register a new dependency of your gem
45
48
  spec.add_dependency "chronic", "~> 0.10.2"
46
49
  spec.add_dependency "tty-which", "~> 0.5.0"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: marked-conductor
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.35
4
+ version: 1.0.38
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brett Terpstra
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-08-22 00:00:00.000000000 Z
11
+ date: 2024-08-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: awesome_print
@@ -156,6 +156,20 @@ dependencies:
156
156
  - - ">="
157
157
  - !ruby/object:Gem::Version
158
158
  version: 0.9.26
159
+ - !ruby/object:Gem::Dependency
160
+ name: rubocop
161
+ requirement: !ruby/object:Gem::Requirement
162
+ requirements:
163
+ - - "~>"
164
+ - !ruby/object:Gem::Version
165
+ version: '1.21'
166
+ type: :development
167
+ prerelease: false
168
+ version_requirements: !ruby/object:Gem::Requirement
169
+ requirements:
170
+ - - "~>"
171
+ - !ruby/object:Gem::Version
172
+ version: '1.21'
159
173
  - !ruby/object:Gem::Dependency
160
174
  name: chronic
161
175
  requirement: !ruby/object:Gem::Requirement
@@ -198,7 +212,6 @@ files:
198
212
  - CHANGELOG.md
199
213
  - CODE_OF_CONDUCT.md
200
214
  - Gemfile
201
- - Gemfile.lock
202
215
  - LICENSE.txt
203
216
  - README.md
204
217
  - README.rdoc
data/Gemfile.lock DELETED
@@ -1,103 +0,0 @@
1
- PATH
2
- remote: .
3
- specs:
4
- marked-conductor (1.0.33)
5
- chronic (~> 0.10.2)
6
- tty-which (~> 0.5.0)
7
-
8
- GEM
9
- remote: https://rubygems.org/
10
- specs:
11
- ansi (1.5.0)
12
- ast (2.4.2)
13
- awesome_print (1.9.2)
14
- chronic (0.10.2)
15
- coderay (1.1.3)
16
- diff-lcs (1.5.1)
17
- docile (1.4.0)
18
- gem-release (2.2.2)
19
- json (2.7.2)
20
- language_server-protocol (3.17.0.3)
21
- method_source (1.1.0)
22
- multi_json (1.15.0)
23
- parallel (1.24.0)
24
- parse_gemspec (1.0.0)
25
- parse_gemspec-cli (1.0.0)
26
- multi_json
27
- parse_gemspec
28
- thor
29
- parser (3.3.1.0)
30
- ast (~> 2.4.1)
31
- racc
32
- pry (0.14.2)
33
- coderay (~> 1.1)
34
- method_source (~> 1.0)
35
- racc (1.7.3)
36
- rainbow (3.1.1)
37
- rake (13.2.1)
38
- regexp_parser (2.9.0)
39
- rexml (3.2.6)
40
- rspec (3.13.0)
41
- rspec-core (~> 3.13.0)
42
- rspec-expectations (~> 3.13.0)
43
- rspec-mocks (~> 3.13.0)
44
- rspec-core (3.13.0)
45
- rspec-support (~> 3.13.0)
46
- rspec-expectations (3.13.1)
47
- diff-lcs (>= 1.2.0, < 2.0)
48
- rspec-support (~> 3.13.0)
49
- rspec-mocks (3.13.1)
50
- diff-lcs (>= 1.2.0, < 2.0)
51
- rspec-support (~> 3.13.0)
52
- rspec-support (3.13.1)
53
- rubocop (1.62.1)
54
- json (~> 2.3)
55
- language_server-protocol (>= 3.17.0)
56
- parallel (~> 1.10)
57
- parser (>= 3.3.0.2)
58
- rainbow (>= 2.2.2, < 4.0)
59
- regexp_parser (>= 1.8, < 3.0)
60
- rexml (>= 3.2.5, < 4.0)
61
- rubocop-ast (>= 1.31.1, < 2.0)
62
- ruby-progressbar (~> 1.7)
63
- unicode-display_width (>= 2.4.0, < 3.0)
64
- rubocop-ast (1.31.2)
65
- parser (>= 3.3.0.4)
66
- ruby-progressbar (1.13.0)
67
- simplecov (0.22.0)
68
- docile (~> 1.1)
69
- simplecov-html (~> 0.11)
70
- simplecov_json_formatter (~> 0.1)
71
- simplecov-console (0.9.1)
72
- ansi
73
- simplecov
74
- terminal-table
75
- simplecov-html (0.12.3)
76
- simplecov_json_formatter (0.1.4)
77
- terminal-table (3.0.2)
78
- unicode-display_width (>= 1.1.1, < 3)
79
- thor (1.3.1)
80
- tty-which (0.5.0)
81
- unicode-display_width (2.5.0)
82
- yard (0.9.36)
83
-
84
- PLATFORMS
85
- arm64-darwin-20
86
- x86_64-darwin-20
87
-
88
- DEPENDENCIES
89
- awesome_print (~> 1.9.2)
90
- bundler (~> 2.0)
91
- gem-release (~> 2.2)
92
- marked-conductor!
93
- parse_gemspec-cli (~> 1.0)
94
- pry (~> 0.14.2)
95
- rake (~> 13.0)
96
- rspec (~> 3.13)
97
- rubocop (~> 1.21)
98
- simplecov (~> 0.21)
99
- simplecov-console (~> 0.9)
100
- yard (~> 0.9, >= 0.9.26)
101
-
102
- BUNDLED WITH
103
- 2.2.29