saddler-reporter-support 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: d6851e629d8a3ccd548179f3306bb04e2668a278
4
+ data.tar.gz: e869a1862e4490b6ae59accea7d6677eede631f3
5
+ SHA512:
6
+ metadata.gz: daacb9d2245a6aee4cbbc5f806c604126a22414d785144e7bd0275485aef120d2056559fe608782c99ed3c64a21dcfac3f14a1726bcb78cd2830d5e612ef3005
7
+ data.tar.gz: 2d1174cd66707c10a1d114eb685022eab569f8a7aac012ef81a736aadc8aae715a070089c4dcef0098f5b505f8d73ee9ea8c6a1db4a3339c72eed17fe8086517
data/.gitignore ADDED
@@ -0,0 +1,9 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /Gemfile.lock
4
+ /_yardoc/
5
+ /coverage/
6
+ /doc/
7
+ /pkg/
8
+ /spec/reports/
9
+ /tmp/
data/.rubocop.yml ADDED
@@ -0,0 +1,17 @@
1
+ AllCops:
2
+ Exclude:
3
+ - 'bundle_bin/*'
4
+ - 'vendor/bundle/**/*'
5
+
6
+ Style/Documentation:
7
+ Enabled: false
8
+
9
+ Metrics/LineLength:
10
+ Max: 120
11
+
12
+ Style/FileName:
13
+ Exclude:
14
+ - exe/*
15
+
16
+ Style/RegexpLiteral:
17
+ MaxSlashes: 0
data/.tachikoma.yml ADDED
@@ -0,0 +1 @@
1
+ strategy: 'none'
data/.travis.yml ADDED
@@ -0,0 +1,15 @@
1
+ language: ruby
2
+ sudo: false
3
+ rvm:
4
+ - 1.9
5
+ - 2.0
6
+ - 2.1
7
+ - 2.2
8
+ before_install:
9
+ - gem update bundler
10
+ notifications:
11
+ email:
12
+ - ogataken@gmail.com
13
+ branches:
14
+ only:
15
+ - master
@@ -0,0 +1,13 @@
1
+ # Contributor Code of Conduct
2
+
3
+ As contributors and maintainers of this project, we pledge to respect all people who contribute through reporting issues, posting feature requests, updating documentation, submitting pull requests or patches, and other activities.
4
+
5
+ We are committed to making participation in this project a harassment-free experience for everyone, regardless of level of experience, gender, gender identity and expression, sexual orientation, disability, personal appearance, body size, race, age, or religion.
6
+
7
+ Examples of unacceptable behavior by participants include the use of sexual language or imagery, derogatory comments or personal attacks, trolling, public or private harassment, insults, or other unprofessional conduct.
8
+
9
+ Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct. Project maintainers who do not follow the Code of Conduct may be removed from the project team.
10
+
11
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by opening an issue or contacting one or more of the project maintainers.
12
+
13
+ This Code of Conduct is adapted from the [Contributor Covenant](http:contributor-covenant.org), version 1.0.0, available at [http://contributor-covenant.org/version/1/0/0/](http://contributor-covenant.org/version/1/0/0/)
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in saddler-reporter-support.gemspec
4
+ gemspec
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2015 sanemat
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,34 @@
1
+ # Saddler::Reporter::Support
2
+
3
+ [![Gem Version](http://img.shields.io/gem/v/saddler-reporter-support.svg?style=flat)](http://badge.fury.io/rb/saddler-reporter-support)
4
+ [![Build Status](http://img.shields.io/travis/packsaddle/ruby-saddler-reporter-support/master.svg?style=flat)](https://travis-ci.org/packsaddle/ruby-saddler-reporter-support)
5
+
6
+ ## Installation
7
+
8
+ Add this line to your application's Gemfile:
9
+
10
+ ```ruby
11
+ gem 'saddler-reporter-support'
12
+ ```
13
+
14
+ And then execute:
15
+
16
+ $ bundle
17
+
18
+ Or install it yourself as:
19
+
20
+ $ gem install saddler-reporter-support
21
+
22
+ ## Development
23
+
24
+ After checking out the repo, run `bin/setup` to install dependencies. Then, run `bin/console` for an interactive prompt that will allow you to experiment.
25
+
26
+ To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release` to create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
27
+
28
+ ## Contributing
29
+
30
+ 1. Fork it ( https://github.com/packsaddle/ruby-saddler-reporter-support/fork )
31
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
32
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
33
+ 4. Push to the branch (`git push origin my-new-feature`)
34
+ 5. Create a new Pull Request
data/Rakefile ADDED
@@ -0,0 +1,9 @@
1
+ require 'bundler/gem_tasks'
2
+ require 'rake/testtask'
3
+
4
+ Rake::TestTask.new(:test) do |t|
5
+ t.libs << 'test'
6
+ t.test_files = FileList['test/**/test*.rb']
7
+ end
8
+
9
+ task default: :test
data/bin/console ADDED
@@ -0,0 +1,14 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require 'bundler/setup'
4
+ require 'saddler/reporter/support'
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 ADDED
@@ -0,0 +1,7 @@
1
+ #!/bin/bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+
5
+ bundle install
6
+
7
+ # Do any other automated setup that you need to do here
@@ -0,0 +1,51 @@
1
+ require 'pathname'
2
+ require 'nori'
3
+ require 'saddler/reporter/support/version'
4
+
5
+ module Saddler
6
+ module Reporter
7
+ module Support
8
+ def initialize(output)
9
+ @output = output
10
+ end
11
+
12
+ def report(messages, _options)
13
+ @output.puts messages
14
+ end
15
+
16
+ # {"checkstyle"=>
17
+ # {"file"=>
18
+ # [{"error"=>
19
+ # [{"@column"=>"4",
20
+ # "@line"=>"22",
21
+ # "@message"=>"Assignment Branch Condition size for report is too high. [34.34/15]",
22
+ # "@severity"=>"info",
23
+ # "@source"=>"com.puppycrawl.tools.checkstyle.Metrics/AbcSize"},
24
+ # {"@column"=>"4",
25
+ # "@line"=>"22",
26
+ # "@message"=>"Cyclomatic complexity for report is too high. [10/6]",
27
+ # "@severity"=>"info",
28
+ # "@source"=>"com.puppycrawl.tools.checkstyle.Metrics/CyclomaticComplexity"},
29
+ # {"@column"=>"6",
30
+ # "@line"=>"39",
31
+ # "@message"=>"Use space after control keywords.",
32
+ # "@severity"=>"info",
33
+ # "@source"=>"com.puppycrawl.tools.checkstyle.Style/SpaceAfterControlKeyword"}],
34
+ # "@name"=>"/Users/sane/work/ruby-study/saddler/lib/saddler/cli.rb"},
35
+ # {"@name"=>"/Users/sane/work/ruby-study/saddler/lib/saddler/reporter.rb"}]}}
36
+ def parse(xml)
37
+ Nori
38
+ .new(parser: :rexml)
39
+ .parse(xml)
40
+ end
41
+
42
+ def file_relative_path_string(file_name)
43
+ if Pathname.new(file_name).absolute?
44
+ Pathname.new(file_name).relative_path_from(Pathname.new(Dir.pwd)).to_s
45
+ else
46
+ Pathname.new(file_name).relative_path_from(Pathname.new('.')).to_s
47
+ end
48
+ end
49
+ end
50
+ end
51
+ end
@@ -0,0 +1,7 @@
1
+ module Saddler
2
+ module Reporter
3
+ module Support
4
+ VERSION = '0.1.0'
5
+ end
6
+ end
7
+ end
@@ -0,0 +1,27 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'saddler/reporter/support/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = 'saddler-reporter-support'
8
+ spec.version = Saddler::Reporter::Support::VERSION
9
+ spec.authors = ['sanemat']
10
+ spec.email = ['o.gata.ken@gmail.com']
11
+
12
+ spec.summary = 'Utilities for saddler-reporter'
13
+ spec.description = 'Utilities for saddler-reporter'
14
+ spec.homepage = 'https://github.com/packsaddle/ruby-saddler-reporter-support'
15
+ spec.license = 'MIT'
16
+
17
+ spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
18
+ spec.bindir = 'exe'
19
+ spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
20
+ spec.require_paths = ['lib']
21
+
22
+ spec.add_runtime_dependency 'nori'
23
+
24
+ spec.add_development_dependency 'bundler', '~> 1.8'
25
+ spec.add_development_dependency 'rake', '~> 10.0'
26
+ spec.add_development_dependency 'test-unit'
27
+ end
metadata ADDED
@@ -0,0 +1,114 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: saddler-reporter-support
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - sanemat
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2015-02-24 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: nori
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '0'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '0'
27
+ - !ruby/object:Gem::Dependency
28
+ name: bundler
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '1.8'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '1.8'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rake
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '10.0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '10.0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: test-unit
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ">="
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ">="
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
69
+ description: Utilities for saddler-reporter
70
+ email:
71
+ - o.gata.ken@gmail.com
72
+ executables: []
73
+ extensions: []
74
+ extra_rdoc_files: []
75
+ files:
76
+ - ".gitignore"
77
+ - ".rubocop.yml"
78
+ - ".tachikoma.yml"
79
+ - ".travis.yml"
80
+ - CODE_OF_CONDUCT.md
81
+ - Gemfile
82
+ - LICENSE.txt
83
+ - README.md
84
+ - Rakefile
85
+ - bin/console
86
+ - bin/setup
87
+ - lib/saddler/reporter/support.rb
88
+ - lib/saddler/reporter/support/version.rb
89
+ - saddler-reporter-support.gemspec
90
+ homepage: https://github.com/packsaddle/ruby-saddler-reporter-support
91
+ licenses:
92
+ - MIT
93
+ metadata: {}
94
+ post_install_message:
95
+ rdoc_options: []
96
+ require_paths:
97
+ - lib
98
+ required_ruby_version: !ruby/object:Gem::Requirement
99
+ requirements:
100
+ - - ">="
101
+ - !ruby/object:Gem::Version
102
+ version: '0'
103
+ required_rubygems_version: !ruby/object:Gem::Requirement
104
+ requirements:
105
+ - - ">="
106
+ - !ruby/object:Gem::Version
107
+ version: '0'
108
+ requirements: []
109
+ rubyforge_project:
110
+ rubygems_version: 2.4.5
111
+ signing_key:
112
+ specification_version: 4
113
+ summary: Utilities for saddler-reporter
114
+ test_files: []