networkx 0.1.0 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (60) hide show
  1. checksums.yaml +5 -5
  2. data/{CODE_OF_CONDUCT.md → .github/CODE_OF_CONDUCT.md} +0 -0
  3. data/{CONTRIBUTING.md → .github/CONTRIBUTING.md} +21 -11
  4. data/.github/ISSUE_TEMPLATE.md +15 -0
  5. data/.github/PULL_REQUEST_TEMPLATE.md +10 -0
  6. data/.github/workflows/ci.yml +17 -0
  7. data/.github/workflows/doc.yml +23 -0
  8. data/.github/workflows/gem-push.yml +45 -0
  9. data/.rspec +0 -1
  10. data/.rubocop.yml +56 -63
  11. data/.yardopts +0 -1
  12. data/README.md +27 -27
  13. data/Rakefile +2 -3
  14. data/lib/networkx/auxillary_functions/cliques.rb +62 -0
  15. data/lib/networkx/auxillary_functions/cycles.rb +114 -0
  16. data/lib/networkx/auxillary_functions/dag.rb +59 -0
  17. data/lib/networkx/auxillary_functions/eccentricity.rb +37 -0
  18. data/lib/networkx/auxillary_functions/mis.rb +23 -0
  19. data/lib/networkx/auxillary_functions/mst.rb +33 -0
  20. data/lib/networkx/auxillary_functions/union_find.rb +104 -0
  21. data/lib/networkx/auxillary_functions/vitality.rb +13 -0
  22. data/lib/networkx/auxillary_functions/wiener.rb +13 -0
  23. data/lib/networkx/converters/to_csv.rb +45 -0
  24. data/lib/networkx/converters/to_json.rb +37 -0
  25. data/lib/networkx/digraph.rb +234 -0
  26. data/lib/networkx/flow/capacityscaling.rb +249 -0
  27. data/lib/networkx/flow/edmondskarp.rb +115 -0
  28. data/lib/networkx/flow/preflowpush.rb +249 -0
  29. data/lib/networkx/flow/shortestaugmentingpath.rb +154 -0
  30. data/lib/networkx/flow/utils.rb +139 -0
  31. data/lib/networkx/graph.rb +448 -0
  32. data/lib/networkx/link_analysis/hits.rb +59 -0
  33. data/lib/networkx/link_analysis/pagerank.rb +89 -0
  34. data/lib/networkx/multidigraph.rb +249 -0
  35. data/lib/networkx/multigraph.rb +199 -0
  36. data/lib/networkx/operators/all.rb +65 -0
  37. data/lib/networkx/operators/binary.rb +222 -0
  38. data/lib/networkx/operators/product.rb +201 -0
  39. data/lib/networkx/operators/unary.rb +17 -0
  40. data/lib/networkx/others/bridges.rb +30 -0
  41. data/lib/networkx/others/generators.rb +237 -0
  42. data/lib/networkx/others/grid_2d_graph.rb +38 -0
  43. data/lib/networkx/others/info.rb +11 -0
  44. data/lib/networkx/others/number_connected_components.rb +17 -0
  45. data/lib/networkx/others/reads.rb +52 -0
  46. data/lib/networkx/shortest_path/astar.rb +73 -0
  47. data/lib/networkx/shortest_path/dense.rb +29 -0
  48. data/lib/networkx/shortest_path/unweighted.rb +136 -0
  49. data/lib/networkx/shortest_path/weighted.rb +417 -0
  50. data/lib/networkx/to_matrix.rb +51 -0
  51. data/lib/networkx/traversals/bfs.rb +110 -0
  52. data/lib/networkx/traversals/dfs.rb +135 -0
  53. data/lib/networkx/traversals/edge_dfs.rb +114 -0
  54. data/lib/networkx/version.rb +1 -1
  55. data/lib/networkx.rb +43 -1
  56. data/networkx.gemspec +14 -12
  57. metadata +118 -62
  58. data/.rspec_formatter.rb +0 -24
  59. data/.travis.yml +0 -18
  60. data/Guardfile +0 -7
@@ -0,0 +1,114 @@
1
+ module NetworkX
2
+ # Helper function for edge_dfs
3
+ #
4
+ # @param graph [Graph, DiGraph, MultiGraph, MultiDiGraph] a graph
5
+ # @param node [Object] a node in the graph
6
+ def self.out_edges(graph, node)
7
+ edges = []
8
+ visited = {}
9
+ case graph.class.name
10
+ when 'NetworkX::Graph', 'NetworkX::DiGraph'
11
+ graph.adj[node].each do |v, _|
12
+ if graph.instance_of?(::NetworkX::DiGraph) || visited[[v, node]].nil?
13
+ visited[[node, v]] = true
14
+ edges << [node, v]
15
+ end
16
+ end
17
+ else
18
+ graph.adj[node].each do |v, uv_keys|
19
+ uv_keys.each_key do |k|
20
+ if graph.instance_of?(::NetworkX::MultiDiGraph) || visited[[v, node, k]].nil?
21
+ visited[[node, v, k]] = true
22
+ edges << [node, v, k]
23
+ end
24
+ end
25
+ end
26
+ end
27
+ edges
28
+ end
29
+
30
+ # Helper function of edge_dfs
31
+ def self.edge_id(graph, edge)
32
+ return edge if graph.directed?
33
+ return Set.new([edge, (edge[0..1].reverse << edge[2])]) if graph.multigraph?
34
+
35
+ Set.new([edge, edge.reverse])
36
+ end
37
+
38
+ # Performs edge dfs on the graph
39
+ # Orientation :ignore, directed edges can be
40
+ # travelled in both fashions
41
+ # Orientation reverse, directed edges can be travelled
42
+ # in reverse fashion
43
+ # Orientation :nil, the graph is not meddled with
44
+ #
45
+ # @example
46
+ # NetworkX.edge_dfs(graph, source, 'ignore')
47
+ #
48
+ # @param graph [Graph, DiGraph, MultiGraph, MultiDiGraph] a graph
49
+ # @param start [Object] node to start dfs from
50
+ # @param orientation [:ignore, :reverse', nil] the orientation of edges of graph
51
+ def self.edge_dfs(graph, start, orientation = nil)
52
+ case orientation
53
+ when :reverse
54
+ graph = graph.reverse if graph.instance_of?(::NetworkX::DiGraph) || graph.instance_of?(::NetworkX::MultiDiGraph)
55
+ when :ignore
56
+ graph = graph.to_undirected if graph.instance_of?(::NetworkX::DiGraph)
57
+ graph = graph.to_multigraph if graph.instance_of?(::NetworkX::MultiDiGraph)
58
+ end
59
+
60
+ visited_edges = []
61
+ visited_nodes = []
62
+ stack = [start]
63
+ current_edges = {}
64
+
65
+ e = Enumerator.new do |yield_var|
66
+ until stack.empty?
67
+ current = stack.last
68
+ unless visited_nodes.include?(current)
69
+ current_edges[current] = out_edges(graph, current)
70
+ visited_nodes << current
71
+ end
72
+
73
+ edge = current_edges[current].shift
74
+ if edge.nil?
75
+ stack.pop
76
+ else
77
+ unless visited_edges.include?(edge_id(graph, edge))
78
+ visited_edges << edge_id(graph, edge)
79
+ stack << edge[1]
80
+ yield_var.yield edge
81
+ end
82
+ end
83
+ end
84
+ end
85
+ e.take(graph.number_of_edges)
86
+ end
87
+
88
+ class Graph
89
+ def dfs_edges(node)
90
+ each_dfs_edge(node).to_a
91
+ end
92
+
93
+ def each_dfs_edge(node)
94
+ return enum_for(:each_dfs_edge, node) unless block_given?
95
+
96
+ st = [node]
97
+ used = {}
98
+ parents = {}
99
+ while st[-1]
100
+ node = st.pop
101
+
102
+ yield(parents[node], node) if parents[node]
103
+
104
+ used[node] = true
105
+ @adj[node].reverse_each do |v, _data|
106
+ next if used[v]
107
+
108
+ parents[v] = node
109
+ st << v unless used[v]
110
+ end
111
+ end
112
+ end
113
+ end
114
+ end
@@ -1,3 +1,3 @@
1
1
  module NetworkX
2
- VERSION = '0.1.0'.freeze
2
+ VERSION = '0.2.0'.freeze
3
3
  end
data/lib/networkx.rb CHANGED
@@ -1 +1,43 @@
1
- require 'networkx/version'
1
+ require 'set'
2
+ require 'matrix'
3
+ require 'rb_heap'
4
+ require 'securerandom'
5
+ require_relative 'networkx/version'
6
+ require_relative 'networkx/graph'
7
+ require_relative 'networkx/digraph'
8
+ require_relative 'networkx/multigraph'
9
+ require_relative 'networkx/multidigraph'
10
+ require_relative 'networkx/traversals/bfs'
11
+ require_relative 'networkx/traversals/dfs'
12
+ require_relative 'networkx/traversals/edge_dfs'
13
+ require_relative 'networkx/shortest_path/unweighted'
14
+ require_relative 'networkx/to_matrix'
15
+ require_relative 'networkx/shortest_path/dense'
16
+ require_relative 'networkx/shortest_path/weighted'
17
+ require_relative 'networkx/shortest_path/astar'
18
+ require_relative 'networkx/operators/product'
19
+ require_relative 'networkx/operators/binary'
20
+ require_relative 'networkx/operators/unary'
21
+ require_relative 'networkx/operators/all'
22
+ require_relative 'networkx/flow/utils'
23
+ require_relative 'networkx/flow/edmondskarp'
24
+ require_relative 'networkx/flow/shortestaugmentingpath'
25
+ require_relative 'networkx/flow/capacityscaling'
26
+ require_relative 'networkx/flow/preflowpush'
27
+ require_relative 'networkx/auxillary_functions/cliques'
28
+ require_relative 'networkx/auxillary_functions/dag'
29
+ require_relative 'networkx/auxillary_functions/eccentricity'
30
+ require_relative 'networkx/auxillary_functions/mis'
31
+ require_relative 'networkx/auxillary_functions/mst'
32
+ require_relative 'networkx/auxillary_functions/union_find'
33
+ require_relative 'networkx/auxillary_functions/vitality'
34
+ require_relative 'networkx/auxillary_functions/wiener'
35
+ require_relative 'networkx/auxillary_functions/cycles'
36
+ require_relative 'networkx/link_analysis/hits'
37
+ require_relative 'networkx/link_analysis/pagerank'
38
+ require_relative 'networkx/others/bridges'
39
+ require_relative 'networkx/others/generators'
40
+ require_relative 'networkx/others/grid_2d_graph'
41
+ require_relative 'networkx/others/info'
42
+ require_relative 'networkx/others/number_connected_components'
43
+ require_relative 'networkx/others/reads'
data/networkx.gemspec CHANGED
@@ -1,4 +1,4 @@
1
- lib = File.expand_path('../lib', __FILE__)
1
+ lib = File.expand_path('lib', __dir__)
2
2
  $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
3
3
  require 'networkx/version'
4
4
 
@@ -20,16 +20,18 @@ Gem::Specification.new do |spec|
20
20
  spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
21
21
  spec.require_paths = ['lib']
22
22
 
23
- spec.add_development_dependency 'bundler', '~> 1.15'
24
- spec.add_development_dependency 'rake', '~> 10.0'
25
- spec.add_development_dependency 'redcarpet'
23
+ spec.add_development_dependency 'bundler', '~> 2.0'
24
+ spec.add_development_dependency 'rake', '~> 13.0'
26
25
  spec.add_development_dependency 'rspec', '~> 3.0'
27
- spec.add_development_dependency 'rspec-its'
28
- spec.add_development_dependency 'rubocop', '>= 0.40.0'
29
- spec.add_development_dependency 'rubocop-rspec'
30
- spec.add_development_dependency 'rubygems-tasks'
31
- spec.add_development_dependency 'saharspec'
32
- spec.add_development_dependency 'simplecov'
33
- spec.add_development_dependency 'yard'
34
- spec.add_development_dependency 'guard-rspec' if RUBY_VERSION >= '2.2.5'
26
+ spec.add_development_dependency 'rspec-its', '~> 1.0'
27
+ spec.add_development_dependency 'rubocop', '~> 1.0'
28
+ spec.add_development_dependency 'rubocop-rake', '~> 0.6'
29
+ spec.add_development_dependency 'rubocop-rspec', '~> 2.0'
30
+ spec.add_development_dependency 'rubygems-tasks', '~> 0.2'
31
+ spec.add_development_dependency 'saharspec', '~> 0.0'
32
+ spec.add_development_dependency 'simplecov', '~> 0.21'
33
+ spec.add_development_dependency 'yard', '~> 0.9'
34
+
35
+ spec.add_runtime_dependency 'matrix', '~> 0.4'
36
+ spec.add_runtime_dependency 'rb_heap', '~> 1.0'
35
37
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: networkx
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Athitya Kumar
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-11-14 00:00:00.000000000 Z
11
+ date: 2022-11-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -16,197 +16,254 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '1.15'
19
+ version: '2.0'
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '1.15'
26
+ version: '2.0'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rake
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: '10.0'
33
+ version: '13.0'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: '10.0'
40
+ version: '13.0'
41
41
  - !ruby/object:Gem::Dependency
42
- name: redcarpet
42
+ name: rspec
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - ">="
45
+ - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: '0'
47
+ version: '3.0'
48
48
  type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - ">="
52
+ - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: '0'
54
+ version: '3.0'
55
55
  - !ruby/object:Gem::Dependency
56
- name: rspec
56
+ name: rspec-its
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
59
  - - "~>"
60
60
  - !ruby/object:Gem::Version
61
- version: '3.0'
61
+ version: '1.0'
62
62
  type: :development
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - "~>"
67
67
  - !ruby/object:Gem::Version
68
- version: '3.0'
68
+ version: '1.0'
69
69
  - !ruby/object:Gem::Dependency
70
- name: rspec-its
70
+ name: rubocop
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
- - - ">="
73
+ - - "~>"
74
74
  - !ruby/object:Gem::Version
75
- version: '0'
75
+ version: '1.0'
76
76
  type: :development
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
- - - ">="
80
+ - - "~>"
81
81
  - !ruby/object:Gem::Version
82
- version: '0'
82
+ version: '1.0'
83
83
  - !ruby/object:Gem::Dependency
84
- name: rubocop
84
+ name: rubocop-rake
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
- - - ">="
87
+ - - "~>"
88
88
  - !ruby/object:Gem::Version
89
- version: 0.40.0
89
+ version: '0.6'
90
90
  type: :development
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
- - - ">="
94
+ - - "~>"
95
95
  - !ruby/object:Gem::Version
96
- version: 0.40.0
96
+ version: '0.6'
97
97
  - !ruby/object:Gem::Dependency
98
98
  name: rubocop-rspec
99
99
  requirement: !ruby/object:Gem::Requirement
100
100
  requirements:
101
- - - ">="
101
+ - - "~>"
102
102
  - !ruby/object:Gem::Version
103
- version: '0'
103
+ version: '2.0'
104
104
  type: :development
105
105
  prerelease: false
106
106
  version_requirements: !ruby/object:Gem::Requirement
107
107
  requirements:
108
- - - ">="
108
+ - - "~>"
109
109
  - !ruby/object:Gem::Version
110
- version: '0'
110
+ version: '2.0'
111
111
  - !ruby/object:Gem::Dependency
112
112
  name: rubygems-tasks
113
113
  requirement: !ruby/object:Gem::Requirement
114
114
  requirements:
115
- - - ">="
115
+ - - "~>"
116
116
  - !ruby/object:Gem::Version
117
- version: '0'
117
+ version: '0.2'
118
118
  type: :development
119
119
  prerelease: false
120
120
  version_requirements: !ruby/object:Gem::Requirement
121
121
  requirements:
122
- - - ">="
122
+ - - "~>"
123
123
  - !ruby/object:Gem::Version
124
- version: '0'
124
+ version: '0.2'
125
125
  - !ruby/object:Gem::Dependency
126
126
  name: saharspec
127
127
  requirement: !ruby/object:Gem::Requirement
128
128
  requirements:
129
- - - ">="
129
+ - - "~>"
130
130
  - !ruby/object:Gem::Version
131
- version: '0'
131
+ version: '0.0'
132
132
  type: :development
133
133
  prerelease: false
134
134
  version_requirements: !ruby/object:Gem::Requirement
135
135
  requirements:
136
- - - ">="
136
+ - - "~>"
137
137
  - !ruby/object:Gem::Version
138
- version: '0'
138
+ version: '0.0'
139
139
  - !ruby/object:Gem::Dependency
140
140
  name: simplecov
141
141
  requirement: !ruby/object:Gem::Requirement
142
142
  requirements:
143
- - - ">="
143
+ - - "~>"
144
144
  - !ruby/object:Gem::Version
145
- version: '0'
145
+ version: '0.21'
146
146
  type: :development
147
147
  prerelease: false
148
148
  version_requirements: !ruby/object:Gem::Requirement
149
149
  requirements:
150
- - - ">="
150
+ - - "~>"
151
151
  - !ruby/object:Gem::Version
152
- version: '0'
152
+ version: '0.21'
153
153
  - !ruby/object:Gem::Dependency
154
154
  name: yard
155
155
  requirement: !ruby/object:Gem::Requirement
156
156
  requirements:
157
- - - ">="
157
+ - - "~>"
158
158
  - !ruby/object:Gem::Version
159
- version: '0'
159
+ version: '0.9'
160
160
  type: :development
161
161
  prerelease: false
162
162
  version_requirements: !ruby/object:Gem::Requirement
163
163
  requirements:
164
- - - ">="
164
+ - - "~>"
165
165
  - !ruby/object:Gem::Version
166
- version: '0'
166
+ version: '0.9'
167
167
  - !ruby/object:Gem::Dependency
168
- name: guard-rspec
168
+ name: matrix
169
169
  requirement: !ruby/object:Gem::Requirement
170
170
  requirements:
171
- - - ">="
171
+ - - "~>"
172
172
  - !ruby/object:Gem::Version
173
- version: '0'
174
- type: :development
173
+ version: '0.4'
174
+ type: :runtime
175
175
  prerelease: false
176
176
  version_requirements: !ruby/object:Gem::Requirement
177
177
  requirements:
178
- - - ">="
178
+ - - "~>"
179
+ - !ruby/object:Gem::Version
180
+ version: '0.4'
181
+ - !ruby/object:Gem::Dependency
182
+ name: rb_heap
183
+ requirement: !ruby/object:Gem::Requirement
184
+ requirements:
185
+ - - "~>"
186
+ - !ruby/object:Gem::Version
187
+ version: '1.0'
188
+ type: :runtime
189
+ prerelease: false
190
+ version_requirements: !ruby/object:Gem::Requirement
191
+ requirements:
192
+ - - "~>"
179
193
  - !ruby/object:Gem::Version
180
- version: '0'
181
- description: |2
182
- A Ruby implemenation of the well-known graph library called "networkx".
194
+ version: '1.0'
195
+ description: ' A Ruby implemenation of the well-known graph library called "networkx".
196
+
197
+ '
183
198
  email:
184
199
  - athityakumar@gmail.com
185
200
  executables: []
186
201
  extensions: []
187
202
  extra_rdoc_files: []
188
203
  files:
204
+ - ".github/CODE_OF_CONDUCT.md"
205
+ - ".github/CONTRIBUTING.md"
206
+ - ".github/ISSUE_TEMPLATE.md"
207
+ - ".github/PULL_REQUEST_TEMPLATE.md"
208
+ - ".github/workflows/ci.yml"
209
+ - ".github/workflows/doc.yml"
210
+ - ".github/workflows/gem-push.yml"
189
211
  - ".gitignore"
190
212
  - ".rspec"
191
- - ".rspec_formatter.rb"
192
213
  - ".rubocop.yml"
193
- - ".travis.yml"
194
214
  - ".yardopts"
195
- - CODE_OF_CONDUCT.md
196
- - CONTRIBUTING.md
197
215
  - Gemfile
198
- - Guardfile
199
216
  - LICENSE.md
200
217
  - README.md
201
218
  - Rakefile
202
219
  - lib/networkx.rb
220
+ - lib/networkx/auxillary_functions/cliques.rb
221
+ - lib/networkx/auxillary_functions/cycles.rb
222
+ - lib/networkx/auxillary_functions/dag.rb
223
+ - lib/networkx/auxillary_functions/eccentricity.rb
224
+ - lib/networkx/auxillary_functions/mis.rb
225
+ - lib/networkx/auxillary_functions/mst.rb
226
+ - lib/networkx/auxillary_functions/union_find.rb
227
+ - lib/networkx/auxillary_functions/vitality.rb
228
+ - lib/networkx/auxillary_functions/wiener.rb
229
+ - lib/networkx/converters/to_csv.rb
230
+ - lib/networkx/converters/to_json.rb
231
+ - lib/networkx/digraph.rb
232
+ - lib/networkx/flow/capacityscaling.rb
233
+ - lib/networkx/flow/edmondskarp.rb
234
+ - lib/networkx/flow/preflowpush.rb
235
+ - lib/networkx/flow/shortestaugmentingpath.rb
236
+ - lib/networkx/flow/utils.rb
237
+ - lib/networkx/graph.rb
238
+ - lib/networkx/link_analysis/hits.rb
239
+ - lib/networkx/link_analysis/pagerank.rb
240
+ - lib/networkx/multidigraph.rb
241
+ - lib/networkx/multigraph.rb
242
+ - lib/networkx/operators/all.rb
243
+ - lib/networkx/operators/binary.rb
244
+ - lib/networkx/operators/product.rb
245
+ - lib/networkx/operators/unary.rb
246
+ - lib/networkx/others/bridges.rb
247
+ - lib/networkx/others/generators.rb
248
+ - lib/networkx/others/grid_2d_graph.rb
249
+ - lib/networkx/others/info.rb
250
+ - lib/networkx/others/number_connected_components.rb
251
+ - lib/networkx/others/reads.rb
252
+ - lib/networkx/shortest_path/astar.rb
253
+ - lib/networkx/shortest_path/dense.rb
254
+ - lib/networkx/shortest_path/unweighted.rb
255
+ - lib/networkx/shortest_path/weighted.rb
256
+ - lib/networkx/to_matrix.rb
257
+ - lib/networkx/traversals/bfs.rb
258
+ - lib/networkx/traversals/dfs.rb
259
+ - lib/networkx/traversals/edge_dfs.rb
203
260
  - lib/networkx/version.rb
204
261
  - networkx.gemspec
205
262
  homepage: https://github.com/athityakumar/networkx.rb
206
263
  licenses:
207
264
  - MIT
208
265
  metadata: {}
209
- post_install_message:
266
+ post_install_message:
210
267
  rdoc_options: []
211
268
  require_paths:
212
269
  - lib
@@ -221,9 +278,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
221
278
  - !ruby/object:Gem::Version
222
279
  version: '0'
223
280
  requirements: []
224
- rubyforge_project:
225
- rubygems_version: 2.6.12
226
- signing_key:
281
+ rubygems_version: 3.3.3
282
+ signing_key:
227
283
  specification_version: 4
228
284
  summary: A Ruby implemenation of the well-known graph library called networkx.
229
285
  test_files: []
data/.rspec_formatter.rb DELETED
@@ -1,24 +0,0 @@
1
- RSpec::Support.require_rspec_core 'formatters/base_text_formatter'
2
-
3
- class SimpleFormatter < RSpec::Core::Formatters::BaseTextFormatter
4
- RSpec::Core::Formatters.register self,
5
- :example_passed, :example_pending, :example_failed, :dump_pending, :dump_failures, :dump_summary
6
-
7
- def example_passed(message); end
8
-
9
- def example_pending(message); end
10
-
11
- def example_failed(message); end
12
-
13
- def dump_pending(message); end
14
-
15
- def dump_failures(message); end
16
-
17
- def dump_summary(message)
18
- colorizer = ::RSpec::Core::Formatters::ConsoleCodes
19
-
20
- output.puts "\nFinished in #{message.formatted_duration} " \
21
- "(files took #{message.formatted_load_time} to load)\n" \
22
- "#{message.colorized_totals_line(colorizer)}\n"
23
- end
24
- end
data/.travis.yml DELETED
@@ -1,18 +0,0 @@
1
- language:
2
- ruby
3
-
4
- rvm:
5
- - '2.1'
6
- - '2.2'
7
- - '2.3.0'
8
- - '2.4.0'
9
-
10
- script:
11
- - bundle exec rspec
12
- - bundle exec rubocop
13
-
14
- install:
15
- - gem install bundler
16
- - gem install rainbow -v '2.2.1'
17
- - sudo apt-get update -qq
18
- - bundle install
data/Guardfile DELETED
@@ -1,7 +0,0 @@
1
- guard :rspec, cmd: 'rspec' do
2
- watch(%r{^spec/.+_spec\.rb$})
3
- watch(%r{^lib/networkx/(.+)\.rb$}) { |m| "spec/#{m[1]}_spec.rb" }
4
- watch('spec/spec_helper.rb') { 'spec' }
5
- end
6
-
7
- # TODO: Run Rubocop in the background