rdepend 0.0.9 → 0.0.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 958519b840593bc87c769f2f5f58327c4a969761
4
- data.tar.gz: e5458d6b91ae8361d25ef277bd1174383237aefb
3
+ metadata.gz: f0beccfd6d9a2482a4c9a6b3e1d62aa337b955ad
4
+ data.tar.gz: 1034a0445c65dfdff6c25c81c8deca237d6e3656
5
5
  SHA512:
6
- metadata.gz: 15bec6085049d38d32de0fdf2e7b7c5fdbd8c78f029f52be8880dc7cde570abf65fc3d5fdcca40dc52a44a01615ec842cb2a75f5a48f4811dd60e63bab6e4116
7
- data.tar.gz: 89abd262d8286829d9a3a3b69eb8602b51a8e9588e0f4cb74fcd0405d48eed2eed5592a6244cbc4e44e8c7d5870ca4bdfb58ada5b867324d39e975dbe1e8f207
6
+ metadata.gz: 32c28e30764068dc654b517a6066fdc0e78f7fe2f8938db26719ee732e88cb8637e4ed07e1aa9d8a01134a04ed08db51a6e1a55982f7d75eee457e345fa20084
7
+ data.tar.gz: c98458cf5424409b928c638b3c47f5a986529d50a6020754abf693860036d475bd382f808a0df0b20733ef43493535e9e461c76b2f65a85cfaeacf9793539c78
data/README.md CHANGED
@@ -13,6 +13,8 @@ See http://www.whiteboxtest.com/information-flow-metrics.php
13
13
 
14
14
  ## Installation
15
15
 
16
+ This Gem depends on Graphviz, http://www.graphviz.org/
17
+
16
18
  Add this line to your application's Gemfile:
17
19
 
18
20
  ```ruby
@@ -5,8 +5,6 @@ module Rdepend
5
5
  class Printer < RubyProf::AbstractPrinter
6
6
  EDGE_COLOR = '"#666666"'
7
7
 
8
- PROGGER = ['|','/','-','\\']
9
-
10
8
  attr_reader :color
11
9
 
12
10
  def initialize(result)
@@ -44,7 +42,7 @@ module Rdepend
44
42
  thread.methods.sort_by(&sort_method).reverse_each do |method|
45
43
  name = method_name(method).split('#').last
46
44
  reset_color
47
- colors = "color=#{color}; fontcolor=#{color}; fontsize=14"
45
+ colors = "color=#{color}; fontcolor=#{color}; fontsize=10"
48
46
  add("#{method.object_id} [label=\"#{name}\"; #{colors}];")
49
47
  @seen_methods << method
50
48
  print_edges(method)
@@ -67,28 +65,21 @@ module Rdepend
67
65
  return if methods.empty?
68
66
  reset_color
69
67
  add("subgraph cluster_#{cls.object_id} {")
70
- add("label = \"#{cls}\";", "fontcolor = #{color};")
71
- add('fontsize = 16;', "color = #{color};")
68
+ add("label=\"#{cls.gsub(/\(.*\)/, '')}\";", "fontcolor=#{color};")
69
+ add('fontsize=12;', "color=#{color}; shape=box; style=\"rounded\";")
72
70
  methods.each { |m| add("#{m.object_id};") }
73
71
  add('}')
74
72
  end
75
73
 
76
74
  def print_edges(method)
77
75
  method.aggregate_children.each do |child|
78
- label = "label=\"#{child.called}/#{child.target.called}\""
79
- label = "fontsize=10 color=#{color} fontcolor=#{EDGE_COLOR}"
76
+ label = "label=\"#{child.called}\/#{child.target.called}\";"
77
+ label = "#{label} fontsize=8; color=#{color}; fontcolor=#{EDGE_COLOR};"
80
78
  add("#{method.object_id} -> #{child.target.object_id} [#{label}];")
81
79
  end
82
80
  end
83
81
 
84
- def print_progress
85
- p = PROGGER.delete_at(0)
86
- PROGGER.push(p)
87
- STDOUT.print "#{p}\r"
88
- end
89
-
90
82
  def add(*args)
91
- print_progress
92
83
  @contents = (@contents || []) + [args].flatten
93
84
  end
94
85
  end
@@ -18,7 +18,6 @@ module RubyProf
18
18
  source = method_info.source_file
19
19
  match = paths.any? { |path| source.start_with?(path) }
20
20
  if match || method_info.root?
21
- puts method_info.full_name
22
21
  i += 1
23
22
  else
24
23
  eliminated << methods.delete_at(i)
@@ -1,3 +1,3 @@
1
1
  module Rdepend
2
- VERSION = '0.0.9'
2
+ VERSION = '0.0.10'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rdepend
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.9
4
+ version: 0.0.10
5
5
  platform: ruby
6
6
  authors:
7
7
  - jarra
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-12-01 00:00:00.000000000 Z
11
+ date: 2015-12-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: ruby-graphviz