neo4j-rake_tasks 0.7.0 → 0.7.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +32 -0
- data/lib/neo4j/rake_tasks/server_manager.rb +9 -5
- data/lib/neo4j/rake_tasks/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f4d1b6c4bc29cd84a9e571c95d908a86a2718267
|
4
|
+
data.tar.gz: 43647c52d7105b98d28e420f4f7e9e037f20133d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 14b391feedd026a6c21b11b7e54c674c5c8856fba5f8251080ef6e9e042a0dafff2ce0d8454f09fbc78327c2b40cd326db1038b04dc0dc5fd9133f5f501b5adc
|
7
|
+
data.tar.gz: ff11765ca8119a7ad722a5264d5d38ae2e9092ee84b8eb8b50b554a4199904959fcebd05545d165f5a5bd9a30ff541868232ad9b2617054c4449d84ffa308879
|
data/README.md
CHANGED
@@ -84,6 +84,38 @@ The ``neo4j-rake_tasks`` gem (automatically included with the ``neo4j`` gem) inc
|
|
84
84
|
Stop the Neo4j server
|
85
85
|
|
86
86
|
|
87
|
+
## neo4j:indexes
|
88
|
+
|
89
|
+
### Arguments
|
90
|
+
|
91
|
+
``environment``
|
92
|
+
|
93
|
+
### Example
|
94
|
+
|
95
|
+
``rake neo4j:indexes[development]``
|
96
|
+
|
97
|
+
### Description
|
98
|
+
|
99
|
+
Print out the indexes in the database
|
100
|
+
|
101
|
+
|
102
|
+
|
103
|
+
## neo4j:constraints
|
104
|
+
|
105
|
+
### Arguments
|
106
|
+
|
107
|
+
``environment``
|
108
|
+
|
109
|
+
### Example
|
110
|
+
|
111
|
+
``rake neo4j:constraints[development]``
|
112
|
+
|
113
|
+
### Description
|
114
|
+
|
115
|
+
Print out the constraints in the database
|
116
|
+
|
117
|
+
|
118
|
+
|
87
119
|
## neo4j:reset_yes_i_am_sure
|
88
120
|
|
89
121
|
### Arguments
|
@@ -173,12 +173,16 @@ module Neo4j
|
|
173
173
|
def print_indexes_or_constraints(type)
|
174
174
|
url = File.join(server_url, "db/data/schema/#{type}")
|
175
175
|
data = JSON.load(open(url).read)
|
176
|
-
data.
|
177
|
-
|
176
|
+
if data.empty?
|
177
|
+
puts "No #{type.to_s.pluralize} found"
|
178
|
+
return
|
179
|
+
end
|
180
|
+
data.sort_by {|i| i['label'] }.chunk do |value|
|
181
|
+
value['label']
|
178
182
|
end.each do |label, indexes|
|
179
183
|
puts "\e[36m#{label}\e[0m"
|
180
|
-
indexes.each do |
|
181
|
-
puts ' ' +
|
184
|
+
indexes.each do |value|
|
185
|
+
puts ' ' + value['property_keys'].join(', ')
|
182
186
|
end
|
183
187
|
end
|
184
188
|
end
|
@@ -209,7 +213,7 @@ module Neo4j
|
|
209
213
|
address.prepend('http://') unless address.match(/^http:\/\//)
|
210
214
|
end
|
211
215
|
else
|
212
|
-
port = get_config_property('org.neo4j.server.webserver.
|
216
|
+
port = get_config_property('org.neo4j.server.webserver.port')
|
213
217
|
"http://localhost:#{port}"
|
214
218
|
end.strip
|
215
219
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: neo4j-rake_tasks
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.7.
|
4
|
+
version: 0.7.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brian Underwood
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-07-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: colored
|