onestop-id-registry-validator 0.0.3 → 0.0.4

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: 5e9e455fe397bd23b0085381acedb4e71ff54afe
4
- data.tar.gz: 1e945f347aa17169a0634d191d2dbf5bec161006
3
+ metadata.gz: e219a4b8c212a2b0cba4a766a9527e0330b70bdc
4
+ data.tar.gz: 2c11ff40e176cee41a222538440ef3abe2d8722c
5
5
  SHA512:
6
- metadata.gz: 8fa53b61bee91d1eb92972c9ec75e24e3f07027826496d5657b3893f3f5b45a2aa77b9b8aa64c83ea26e533a9f1224de09dbbbb9d4f49feaa4a50989b0c127ee
7
- data.tar.gz: 44971c21d7b22b12c655d1eac99384ee9a8fd2d2c6c4bc7cf8d19326bdab97f6416e0b08d53da12e2c3b1a39113975df1cb39fa5bd9b29cc359cc253734c7129
6
+ metadata.gz: ef9ff444eefd14c8489a039f7fd3abfcf68df665e5dfc5d02e4a0af9d20cef9dc65dd41e4417017577a34730bf854ebd213f2c90d9ad0631bf791a431369f5e3
7
+ data.tar.gz: 0778f932f257f744b6f3c228bd31f3853eb38c6c12cfc9a1ce14a26a575b38eee921cbaca72ff3b8ca490e677ba392507dd81ec8dd43d462e4ab3774bdc1d760
data/README.md CHANGED
@@ -3,4 +3,14 @@
3
3
 
4
4
  # onestop-id-registry-validator
5
5
 
6
- TODO: write a readme
6
+ A set of Ruby scripts that validates the [Onestop ID Registry](https://github.com/onestop-id-registry) and returns any errors in JSON, GeoJSON, and internal consistency.
7
+
8
+ Requires Ruby 2.0+
9
+
10
+ To install: `gem install onestop-id-registry-validator` or include in your `Gemfile`
11
+
12
+ To use: `bundle exec onestop_id_registry_validator`
13
+
14
+ By default, this will use [onestop-id-ruby-client](https://github.com/transitland/onestop-id-ruby-client) to download a copy of the latest Onestop ID Registry on GitHub.
15
+
16
+ If you already have a local copy of the registry, point it to the local path using an environment variable. For example: `ONESTOP_ID_REGISTRY_LOCAL_PATH=/tmp/onestop-id-registry onestop_id_registry_validator`
@@ -42,6 +42,12 @@ module OnestopIdRegistryValidator
42
42
  errors[File.basename(file)] = file_errors if file_errors && file_errors.length > 0
43
43
  end
44
44
  end
45
+ all_valid = (errors.length == 0)
46
+ return all_valid, errors
47
+ end
48
+
49
+ def self.validate_return_errors_and_exit
50
+ all_valid, errors = validate_all
45
51
  if errors.length > 0
46
52
  puts errors.inspect
47
53
  else
@@ -1,3 +1,3 @@
1
1
  module OnestopIdRegistryValidator
2
- VERSION = '0.0.3'
2
+ VERSION = '0.0.4'
3
3
  end
metadata CHANGED
@@ -1,29 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: onestop-id-registry-validator
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Drew Dara-Abrams
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-03-07 00:00:00.000000000 Z
11
+ date: 2015-04-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: onestop-id-client
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
17
+ - - '='
18
18
  - !ruby/object:Gem::Version
19
- version: '0.0'
19
+ version: 0.0.4
20
20
  type: :runtime
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: '0.0'
26
+ version: 0.0.4
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rake
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -100,28 +100,28 @@ dependencies:
100
100
  requirements:
101
101
  - - "~>"
102
102
  - !ruby/object:Gem::Version
103
- version: '3.5'
103
+ version: '4.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: '3.5'
110
+ version: '4.0'
111
111
  - !ruby/object:Gem::Dependency
112
112
  name: pry-byebug
113
113
  requirement: !ruby/object:Gem::Requirement
114
114
  requirements:
115
115
  - - "~>"
116
116
  - !ruby/object:Gem::Version
117
- version: '3.0'
117
+ version: '3.1'
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: '3.0'
124
+ version: '3.1'
125
125
  description: ''
126
126
  email:
127
127
  - drew@mapzen.com
@@ -137,6 +137,7 @@ files:
137
137
  - lib/onestop_id_registry_validator/internal_validation.rb
138
138
  - lib/onestop_id_registry_validator/schemas/feeds.json
139
139
  - lib/onestop_id_registry_validator/schemas/operators.json
140
+ - lib/onestop_id_registry_validator/schemas/stop_tiles.json
140
141
  - lib/onestop_id_registry_validator/version.rb
141
142
  homepage: https://github.com/transitland/onestop-id-registry-validator
142
143
  licenses: