json2xxx 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.document +3 -0
- data/.gitignore +8 -0
- data/.rspec +1 -0
- data/.travis.yml +16 -0
- data/.yardopts +1 -0
- data/ChangeLog.md +4 -0
- data/Gemfile +7 -0
- data/LICENSE.txt +20 -0
- data/README.md +45 -0
- data/Rakefile +40 -0
- data/bin/json2xxx +6 -0
- data/json2xxx.gemspec +32 -0
- data/lib/json2xxx.rb +3 -0
- data/lib/json2xxx/cli.rb +73 -0
- data/lib/json2xxx/core.rb +105 -0
- data/lib/json2xxx/version.rb +4 -0
- data/spec/cli_spec.rb +17 -0
- data/spec/core_spec.rb +39 -0
- data/spec/json2xxx_spec.rb +8 -0
- data/spec/spec_helper.rb +24 -0
- metadata +222 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 88f8a97c5d6960761a0417be1da8c43ba20c3aa5
|
4
|
+
data.tar.gz: a4abb8389bd10497fe6325b9b12107e88bd146cd
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: f233f8b0ff9cfe113ee48f4a552b934ed76ea2053ad9b0deb2ea1446425c4c405ac55020fe6db6702623cd3e6be78fd2db9cb4939c3e7712e244000681c53c76
|
7
|
+
data.tar.gz: b6a5de71886dcbea2d287fa11a8e0fadd192be740a4f097d55f54f2cd872b91ecdf468ef6552cf83cc6ee715a5677f6de431a7175ebf3e772bdb886b7c606da6
|
data/.document
ADDED
data/.gitignore
ADDED
data/.rspec
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
--colour --format documentation
|
data/.travis.yml
ADDED
data/.yardopts
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
--markup markdown --title "json2xxx Documentation" --protected
|
data/ChangeLog.md
ADDED
data/Gemfile
ADDED
data/LICENSE.txt
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
Copyright (c) 2014 Hiroshi Toyama
|
2
|
+
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
4
|
+
a copy of this software and associated documentation files (the
|
5
|
+
"Software"), to deal in the Software without restriction, including
|
6
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
7
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
8
|
+
permit persons to whom the Software is furnished to do so, subject to
|
9
|
+
the following conditions:
|
10
|
+
|
11
|
+
The above copyright notice and this permission notice shall be
|
12
|
+
included in all copies or substantial portions of the Software.
|
13
|
+
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
15
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
16
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
17
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
18
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
19
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
20
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,45 @@
|
|
1
|
+
# json2xxx [![Build Status](https://secure.travis-ci.org/toyama0919/json2xxx.png?branch=master)](http://travis-ci.org/toyama0919/json2xxx)
|
2
|
+
|
3
|
+
TODO: Summary
|
4
|
+
|
5
|
+
TODO: Description
|
6
|
+
|
7
|
+
## Examples
|
8
|
+
|
9
|
+
$ json2xxx sample
|
10
|
+
#=> hoge
|
11
|
+
|
12
|
+
## Installation
|
13
|
+
|
14
|
+
Add this line to your application's Gemfile:
|
15
|
+
|
16
|
+
gem 'json2xxx'
|
17
|
+
|
18
|
+
And then execute:
|
19
|
+
|
20
|
+
$ bundle
|
21
|
+
|
22
|
+
Or install it yourself as:
|
23
|
+
|
24
|
+
$ gem install json2xxx
|
25
|
+
|
26
|
+
## Contributing
|
27
|
+
|
28
|
+
1. Fork it
|
29
|
+
2. Create your feature branch (`git checkout -b my-new-feature`)
|
30
|
+
3. Commit your changes (`git commit -am 'Add some feature'`)
|
31
|
+
4. Push to the branch (`git push origin my-new-feature`)
|
32
|
+
5. Create new [Pull Request](../../pull/new/master)
|
33
|
+
|
34
|
+
## Information
|
35
|
+
|
36
|
+
* [Homepage](https://github.com/toyama0919/json2xxx)
|
37
|
+
* [Issues](https://github.com/toyama0919/json2xxx/issues)
|
38
|
+
* [Documentation](http://rubydoc.info/gems/json2xxx/frames)
|
39
|
+
* [Email](mailto:toyama0919@gmail.com)
|
40
|
+
|
41
|
+
## Copyright
|
42
|
+
|
43
|
+
Copyright (c) 2014 Hiroshi Toyama
|
44
|
+
|
45
|
+
See [LICENSE.txt](../LICENSE.txt) for details.
|
data/Rakefile
ADDED
@@ -0,0 +1,40 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
|
3
|
+
require 'rubygems'
|
4
|
+
require 'rake'
|
5
|
+
|
6
|
+
begin
|
7
|
+
gem 'rubygems-tasks', '~> 0.2'
|
8
|
+
require 'rubygems/tasks'
|
9
|
+
|
10
|
+
Gem::Tasks.new
|
11
|
+
rescue LoadError => e
|
12
|
+
warn e.message
|
13
|
+
warn "Run `gem install rubygems-tasks` to install Gem::Tasks."
|
14
|
+
end
|
15
|
+
|
16
|
+
begin
|
17
|
+
gem 'rspec', '~> 2.4'
|
18
|
+
require 'rspec/core/rake_task'
|
19
|
+
|
20
|
+
RSpec::Core::RakeTask.new
|
21
|
+
rescue LoadError => e
|
22
|
+
task :spec do
|
23
|
+
abort "Please run `gem install rspec` to install RSpec."
|
24
|
+
end
|
25
|
+
end
|
26
|
+
|
27
|
+
task :test => :spec
|
28
|
+
task :default => :spec
|
29
|
+
|
30
|
+
begin
|
31
|
+
gem 'yard', '~> 0.8'
|
32
|
+
require 'yard'
|
33
|
+
|
34
|
+
YARD::Rake::YardocTask.new
|
35
|
+
rescue LoadError => e
|
36
|
+
task :yard do
|
37
|
+
abort "Please run `gem install yard` to install YARD."
|
38
|
+
end
|
39
|
+
end
|
40
|
+
task :doc => :yard
|
data/bin/json2xxx
ADDED
data/json2xxx.gemspec
ADDED
@@ -0,0 +1,32 @@
|
|
1
|
+
# -*- encoding: utf-8 -*-
|
2
|
+
|
3
|
+
require File.expand_path('../lib/json2xxx/version', __FILE__)
|
4
|
+
|
5
|
+
Gem::Specification.new do |gem|
|
6
|
+
gem.name = "json2xxx"
|
7
|
+
gem.version = Json2xxx::VERSION
|
8
|
+
gem.summary = %q{json to variety of formats}
|
9
|
+
gem.description = %q{json to variety of formats}
|
10
|
+
gem.license = "MIT"
|
11
|
+
gem.authors = ["Hiroshi Toyama"]
|
12
|
+
gem.email = "toyama0919@gmail.com"
|
13
|
+
gem.homepage = "https://github.com/toyama0919/json2xxx"
|
14
|
+
|
15
|
+
gem.files = `git ls-files`.split($/)
|
16
|
+
gem.executables = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
|
17
|
+
gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
|
18
|
+
gem.require_paths = ['lib']
|
19
|
+
|
20
|
+
gem.add_dependency 'thor', '~> 0.19.1'
|
21
|
+
gem.add_dependency 'spreadsheet'
|
22
|
+
gem.add_dependency 'tbpgr_utils'
|
23
|
+
gem.add_dependency 'hashie'
|
24
|
+
|
25
|
+
gem.add_development_dependency 'bundler', '~> 1.7.2'
|
26
|
+
gem.add_development_dependency 'pry', '~> 0.10.1'
|
27
|
+
gem.add_development_dependency 'rake', '~> 10.3.2'
|
28
|
+
gem.add_development_dependency 'rspec', '~> 2.4'
|
29
|
+
gem.add_development_dependency 'rubocop', '~> 0.24.1'
|
30
|
+
gem.add_development_dependency 'rubygems-tasks', '~> 0.2'
|
31
|
+
gem.add_development_dependency 'yard', '~> 0.8'
|
32
|
+
end
|
data/lib/json2xxx.rb
ADDED
data/lib/json2xxx/cli.rb
ADDED
@@ -0,0 +1,73 @@
|
|
1
|
+
require "thor"
|
2
|
+
require "json"
|
3
|
+
require 'yaml'
|
4
|
+
require 'hashie'
|
5
|
+
|
6
|
+
module Json2xxx
|
7
|
+
class CLI < Thor
|
8
|
+
|
9
|
+
include Thor::Actions
|
10
|
+
class_option :fields, aliases: '-f', type: :array, desc: 'default is first data'
|
11
|
+
def initialize(args = [], options = {}, config = {})
|
12
|
+
super(args, options, config)
|
13
|
+
@global_options = config[:shell].base.options
|
14
|
+
return unless File.pipe?(STDIN)
|
15
|
+
@data = parse_json(STDIN.read)
|
16
|
+
@core = Core.new
|
17
|
+
unless @global_options['fields'].nil?
|
18
|
+
@data = @core.extract(@data, @global_options['fields'])
|
19
|
+
end
|
20
|
+
end
|
21
|
+
|
22
|
+
desc 'tsv', 'tsv'
|
23
|
+
def tsv
|
24
|
+
puts @core.convert_csv(@data, "\t")
|
25
|
+
end
|
26
|
+
|
27
|
+
desc 'csv', 'csv'
|
28
|
+
def csv
|
29
|
+
puts @core.convert_csv(@data, ',')
|
30
|
+
end
|
31
|
+
|
32
|
+
desc 'yaml', 'yaml'
|
33
|
+
def yaml
|
34
|
+
puts YAML.dump(@data)
|
35
|
+
end
|
36
|
+
|
37
|
+
desc 'markdown', 'markdown'
|
38
|
+
def markdown
|
39
|
+
puts @core.convert_markdown(@data)
|
40
|
+
end
|
41
|
+
|
42
|
+
desc 'backlog', 'backlog'
|
43
|
+
def backlog
|
44
|
+
puts @core.convert_backlog_wiki(@data)
|
45
|
+
end
|
46
|
+
|
47
|
+
desc 'html', 'html'
|
48
|
+
def html
|
49
|
+
puts @core.convert_html(@data)
|
50
|
+
end
|
51
|
+
|
52
|
+
desc 'excel', 'excel'
|
53
|
+
def excel
|
54
|
+
@core.convert_excel(@data)
|
55
|
+
end
|
56
|
+
|
57
|
+
private
|
58
|
+
|
59
|
+
def parse_json(buffer)
|
60
|
+
begin
|
61
|
+
data = JSON.parse(buffer)
|
62
|
+
rescue => e
|
63
|
+
data = []
|
64
|
+
buffer.lines.each do |line|
|
65
|
+
data << JSON.parse(line)
|
66
|
+
end
|
67
|
+
end
|
68
|
+
data.class == Array ? data : [data]
|
69
|
+
end
|
70
|
+
end
|
71
|
+
end
|
72
|
+
|
73
|
+
|
@@ -0,0 +1,105 @@
|
|
1
|
+
require 'spreadsheet'
|
2
|
+
require 'csv'
|
3
|
+
require 'tbpgr_utils'
|
4
|
+
|
5
|
+
module Json2xxx
|
6
|
+
class Core
|
7
|
+
|
8
|
+
def initialize
|
9
|
+
end
|
10
|
+
|
11
|
+
def convert_csv(data, delimiter)
|
12
|
+
headers = data.first.keys
|
13
|
+
csv = []
|
14
|
+
CSV.generate(col_sep: delimiter, force_quotes: true) do |csv|
|
15
|
+
csv << headers
|
16
|
+
data.each do |hash|
|
17
|
+
csv << headers.map { |column_name|
|
18
|
+
get_json_value(hash[column_name]).gsub("\n", '')
|
19
|
+
}
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
|
24
|
+
def convert_markdown(data)
|
25
|
+
headers = data.first.keys
|
26
|
+
result = []
|
27
|
+
header = '|' + headers.join('|') + '|' + "\n" +
|
28
|
+
'|' + headers.map { |_header| ':--' }.join('|') + '|'
|
29
|
+
data.each do |hash|
|
30
|
+
columns = headers.map{ |column_name|
|
31
|
+
get_json_value(hash[column_name]).gsub("\n", '').gsub("|", '')
|
32
|
+
}
|
33
|
+
result << columns
|
34
|
+
end
|
35
|
+
header + "\n" + result.to_table
|
36
|
+
end
|
37
|
+
|
38
|
+
def convert_backlog_wiki(data)
|
39
|
+
headers = data.first.keys
|
40
|
+
result = []
|
41
|
+
result << '|~' + headers.join('|') + '|h'
|
42
|
+
|
43
|
+
data.each do |hash|
|
44
|
+
columns = headers.map{ |column_name|
|
45
|
+
get_json_value(hash[column_name]).gsub("\n", "&br;")
|
46
|
+
}
|
47
|
+
result << '|~' + columns.join('|') + '|'
|
48
|
+
end
|
49
|
+
result.join("\n")
|
50
|
+
end
|
51
|
+
|
52
|
+
def convert_excel(data)
|
53
|
+
filepath = Time.now.strftime("%Y%m%d%H%M%S") + '.xls'
|
54
|
+
headers = data.first.keys
|
55
|
+
basename = File.basename(filepath, '.*')
|
56
|
+
Spreadsheet.client_encoding = 'UTF-8'
|
57
|
+
workbook = Spreadsheet::Workbook.new
|
58
|
+
workbook.add_font 'MS ゴシック'
|
59
|
+
worksheet = workbook.create_worksheet(name: basename)
|
60
|
+
worksheet.row(0).replace headers
|
61
|
+
|
62
|
+
unless data.class == Array
|
63
|
+
puts 'data is not Array'
|
64
|
+
exit
|
65
|
+
end
|
66
|
+
i = 1
|
67
|
+
data.each do |record|
|
68
|
+
values = headers.map { |key| get_json_value(record[key]) }
|
69
|
+
worksheet.row(i).replace values
|
70
|
+
i = i + 1
|
71
|
+
end
|
72
|
+
workbook.write(filepath)
|
73
|
+
puts "write #{filepath}"
|
74
|
+
end
|
75
|
+
|
76
|
+
def convert_html(data)
|
77
|
+
headers = data.first.keys
|
78
|
+
result = []
|
79
|
+
result << headers
|
80
|
+
data.each do |hash|
|
81
|
+
columns = headers.map{ |column_name|
|
82
|
+
get_json_value(hash[column_name]).gsub("\n", '')
|
83
|
+
}
|
84
|
+
result << columns
|
85
|
+
end
|
86
|
+
result.to_html_table
|
87
|
+
end
|
88
|
+
|
89
|
+
def extract(data, fields)
|
90
|
+
data.map { |record|
|
91
|
+
record = Hashie::Mash.new(record)
|
92
|
+
fields.inject({}) { |result, field|
|
93
|
+
result[field] = eval("record.#{field}")
|
94
|
+
result
|
95
|
+
}
|
96
|
+
}
|
97
|
+
end
|
98
|
+
|
99
|
+
def get_json_value(value)
|
100
|
+
return '' if value.nil?
|
101
|
+
return value.to_json if value.class == Array || value.class == Hash || value.class == Hashie::Mash
|
102
|
+
return value.to_s
|
103
|
+
end
|
104
|
+
end
|
105
|
+
end
|
data/spec/cli_spec.rb
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
require 'json2xxx'
|
3
|
+
|
4
|
+
describe Json2xxx::CLI do
|
5
|
+
before do
|
6
|
+
end
|
7
|
+
|
8
|
+
it "should stdout sample" do
|
9
|
+
output = capture_stdout do
|
10
|
+
Json2xxx::CLI.start(['help'])
|
11
|
+
end
|
12
|
+
output.should_not nil
|
13
|
+
end
|
14
|
+
|
15
|
+
after do
|
16
|
+
end
|
17
|
+
end
|
data/spec/core_spec.rb
ADDED
@@ -0,0 +1,39 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
require 'json2xxx'
|
3
|
+
|
4
|
+
describe Json2xxx::Core do
|
5
|
+
before do
|
6
|
+
@core = Core.new
|
7
|
+
end
|
8
|
+
|
9
|
+
it "tsv" do
|
10
|
+
data = [
|
11
|
+
{id: 1, name: 'user1', address: 'tokyo'},
|
12
|
+
{id: 2, name: 'user2', address: 'tokyo'},
|
13
|
+
{id: 3, name: 'user3', address: 'tokyo'}
|
14
|
+
]
|
15
|
+
result = @core.convert_csv(data, "\t")
|
16
|
+
result.should == %Q{"id"\t"name"\t"address"
|
17
|
+
"1"\t"user1"\t"tokyo"
|
18
|
+
"2"\t"user2"\t"tokyo"
|
19
|
+
"3"\t"user3"\t"tokyo"
|
20
|
+
}
|
21
|
+
end
|
22
|
+
|
23
|
+
it "tsv" do
|
24
|
+
data = [
|
25
|
+
{id: 1, name: 'user1', address: 'tokyo'},
|
26
|
+
{id: 2, name: 'user2', address: 'tokyo', zip_code: '111-1111'},
|
27
|
+
{id: 3, name: 'user3', address: 'tokyo'}
|
28
|
+
]
|
29
|
+
result = @core.convert_csv(data, "\t")
|
30
|
+
result.should == %Q{"id"\t"name"\t"address"
|
31
|
+
"1"\t"user1"\t"tokyo"
|
32
|
+
"2"\t"user2"\t"tokyo"
|
33
|
+
"3"\t"user3"\t"tokyo"
|
34
|
+
}
|
35
|
+
end
|
36
|
+
|
37
|
+
after do
|
38
|
+
end
|
39
|
+
end
|
data/spec/spec_helper.rb
ADDED
@@ -0,0 +1,24 @@
|
|
1
|
+
gem 'rspec', '~> 2.4'
|
2
|
+
require 'rspec'
|
3
|
+
require 'json2xxx/version'
|
4
|
+
|
5
|
+
include Json2xxx
|
6
|
+
|
7
|
+
def capture_stdout
|
8
|
+
out = StringIO.new
|
9
|
+
$stdout = out
|
10
|
+
yield
|
11
|
+
return out.string
|
12
|
+
ensure
|
13
|
+
$stdout = STDOUT
|
14
|
+
end
|
15
|
+
|
16
|
+
def capture_stderr
|
17
|
+
out = StringIO.new
|
18
|
+
$stderr = out
|
19
|
+
yield
|
20
|
+
return out.string
|
21
|
+
ensure
|
22
|
+
$stderr = STDERR
|
23
|
+
end
|
24
|
+
|
metadata
ADDED
@@ -0,0 +1,222 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: json2xxx
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.2.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Hiroshi Toyama
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2014-12-26 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: thor
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: 0.19.1
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: 0.19.1
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: spreadsheet
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ">="
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0'
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - ">="
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: tbpgr_utils
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - ">="
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '0'
|
48
|
+
type: :runtime
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - ">="
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: hashie
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - ">="
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
type: :runtime
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: bundler
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - "~>"
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: 1.7.2
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: 1.7.2
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: pry
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - "~>"
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: 0.10.1
|
90
|
+
type: :development
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - "~>"
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: 0.10.1
|
97
|
+
- !ruby/object:Gem::Dependency
|
98
|
+
name: rake
|
99
|
+
requirement: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - "~>"
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: 10.3.2
|
104
|
+
type: :development
|
105
|
+
prerelease: false
|
106
|
+
version_requirements: !ruby/object:Gem::Requirement
|
107
|
+
requirements:
|
108
|
+
- - "~>"
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: 10.3.2
|
111
|
+
- !ruby/object:Gem::Dependency
|
112
|
+
name: rspec
|
113
|
+
requirement: !ruby/object:Gem::Requirement
|
114
|
+
requirements:
|
115
|
+
- - "~>"
|
116
|
+
- !ruby/object:Gem::Version
|
117
|
+
version: '2.4'
|
118
|
+
type: :development
|
119
|
+
prerelease: false
|
120
|
+
version_requirements: !ruby/object:Gem::Requirement
|
121
|
+
requirements:
|
122
|
+
- - "~>"
|
123
|
+
- !ruby/object:Gem::Version
|
124
|
+
version: '2.4'
|
125
|
+
- !ruby/object:Gem::Dependency
|
126
|
+
name: rubocop
|
127
|
+
requirement: !ruby/object:Gem::Requirement
|
128
|
+
requirements:
|
129
|
+
- - "~>"
|
130
|
+
- !ruby/object:Gem::Version
|
131
|
+
version: 0.24.1
|
132
|
+
type: :development
|
133
|
+
prerelease: false
|
134
|
+
version_requirements: !ruby/object:Gem::Requirement
|
135
|
+
requirements:
|
136
|
+
- - "~>"
|
137
|
+
- !ruby/object:Gem::Version
|
138
|
+
version: 0.24.1
|
139
|
+
- !ruby/object:Gem::Dependency
|
140
|
+
name: rubygems-tasks
|
141
|
+
requirement: !ruby/object:Gem::Requirement
|
142
|
+
requirements:
|
143
|
+
- - "~>"
|
144
|
+
- !ruby/object:Gem::Version
|
145
|
+
version: '0.2'
|
146
|
+
type: :development
|
147
|
+
prerelease: false
|
148
|
+
version_requirements: !ruby/object:Gem::Requirement
|
149
|
+
requirements:
|
150
|
+
- - "~>"
|
151
|
+
- !ruby/object:Gem::Version
|
152
|
+
version: '0.2'
|
153
|
+
- !ruby/object:Gem::Dependency
|
154
|
+
name: yard
|
155
|
+
requirement: !ruby/object:Gem::Requirement
|
156
|
+
requirements:
|
157
|
+
- - "~>"
|
158
|
+
- !ruby/object:Gem::Version
|
159
|
+
version: '0.8'
|
160
|
+
type: :development
|
161
|
+
prerelease: false
|
162
|
+
version_requirements: !ruby/object:Gem::Requirement
|
163
|
+
requirements:
|
164
|
+
- - "~>"
|
165
|
+
- !ruby/object:Gem::Version
|
166
|
+
version: '0.8'
|
167
|
+
description: json to variety of formats
|
168
|
+
email: toyama0919@gmail.com
|
169
|
+
executables:
|
170
|
+
- json2xxx
|
171
|
+
extensions: []
|
172
|
+
extra_rdoc_files: []
|
173
|
+
files:
|
174
|
+
- ".document"
|
175
|
+
- ".gitignore"
|
176
|
+
- ".rspec"
|
177
|
+
- ".travis.yml"
|
178
|
+
- ".yardopts"
|
179
|
+
- ChangeLog.md
|
180
|
+
- Gemfile
|
181
|
+
- LICENSE.txt
|
182
|
+
- README.md
|
183
|
+
- Rakefile
|
184
|
+
- bin/json2xxx
|
185
|
+
- json2xxx.gemspec
|
186
|
+
- lib/json2xxx.rb
|
187
|
+
- lib/json2xxx/cli.rb
|
188
|
+
- lib/json2xxx/core.rb
|
189
|
+
- lib/json2xxx/version.rb
|
190
|
+
- spec/cli_spec.rb
|
191
|
+
- spec/core_spec.rb
|
192
|
+
- spec/json2xxx_spec.rb
|
193
|
+
- spec/spec_helper.rb
|
194
|
+
homepage: https://github.com/toyama0919/json2xxx
|
195
|
+
licenses:
|
196
|
+
- MIT
|
197
|
+
metadata: {}
|
198
|
+
post_install_message:
|
199
|
+
rdoc_options: []
|
200
|
+
require_paths:
|
201
|
+
- lib
|
202
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
203
|
+
requirements:
|
204
|
+
- - ">="
|
205
|
+
- !ruby/object:Gem::Version
|
206
|
+
version: '0'
|
207
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
208
|
+
requirements:
|
209
|
+
- - ">="
|
210
|
+
- !ruby/object:Gem::Version
|
211
|
+
version: '0'
|
212
|
+
requirements: []
|
213
|
+
rubyforge_project:
|
214
|
+
rubygems_version: 2.4.5
|
215
|
+
signing_key:
|
216
|
+
specification_version: 4
|
217
|
+
summary: json to variety of formats
|
218
|
+
test_files:
|
219
|
+
- spec/cli_spec.rb
|
220
|
+
- spec/core_spec.rb
|
221
|
+
- spec/json2xxx_spec.rb
|
222
|
+
- spec/spec_helper.rb
|