findbugs_translate_checkstyle_format 0.2.4 → 0.2.5

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
  SHA1:
3
- metadata.gz: a447fe8ec9367838a29860e07da53c6b09a77b4e
4
- data.tar.gz: 89a7ce3b8e9d40f006b65b4f150d8b8ba846ccde
3
+ metadata.gz: a782a01eb2e2ce8a20684d03448c6a5b77de0b5f
4
+ data.tar.gz: b1c0a0019c92d528dcf42466c4aa3149d3b3d1fb
5
5
  SHA512:
6
- metadata.gz: e032b457fc0506cefd74a2cacc63a4f17464401a4bdd9a759dd863ad709ee4a432e7654ed7dde2dfb2ed57d95a42259aaacce511e92c26ce7f9d8b5d7a7543bd
7
- data.tar.gz: 21582c9a60431e1205d38d0401f582afb6673a777ef30b70475cda5a3aea2f440006196439eb1ec25ed619dc6a5cac4425dfb4c1ea80be449a2e8945b99d5b1b
6
+ metadata.gz: 8ad50c4749c2bd2c2ef51572e86dc301ddef4e321cbb07754a80e2a86c2fb6089824a30b3ac79d459156da72b27fcf06f095c91d5cd7cebff6e811f39af7243c
7
+ data.tar.gz: 965fb1d8e7e323e1615bdf28f090e90902b45a67b2963a15877b1611f6d725218538791bf960729272bf3f8c8e1197c9b4dcf4894ad8df838989c07cc4f2f190
@@ -42,7 +42,10 @@ module FindbugsTranslateCheckstyleFormat
42
42
  def self.fqcn_to_path(fqcn, xml)
43
43
  path = fqcn.tr('.', '/').gsub(/\$[A-z0-9]+/, '') + '.java'
44
44
  src_dirs = xml['BugCollection']['Project']['SrcDir']
45
- src_dirs = [src_dirs] unless src_dirs.is_a?(Array)
45
+
46
+ # if find 1 SrcDir, that is single parent dir.
47
+ return src_dirs + '/' + path unless src_dirs.is_a?(Array)
48
+
46
49
  src_dirs.find { |src| !src.index(path).nil? }
47
50
  end
48
51
 
@@ -1,3 +1,3 @@
1
1
  module FindbugsTranslateCheckstyleFormat
2
- VERSION = '0.2.4'
2
+ VERSION = '0.2.5'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: findbugs_translate_checkstyle_format
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.4
4
+ version: 0.2.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - noboru-i
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-04-26 00:00:00.000000000 Z
11
+ date: 2016-05-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: thor
@@ -140,7 +140,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
140
140
  version: '0'
141
141
  requirements: []
142
142
  rubyforge_project:
143
- rubygems_version: 2.5.1
143
+ rubygems_version: 2.6.4
144
144
  signing_key:
145
145
  specification_version: 4
146
146
  summary: Translate findbugs format into checkstyle format.