geojsonlint 0.1.3 → 0.1.4
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 +5 -5
- data/.gitignore +2 -0
- data/.travis.yml +22 -1
- data/Gemfile +8 -5
- data/LICENSE.md +19 -6
- data/README.md +4 -14
- data/geojsonlint.gemspec +5 -17
- data/lib/geojsonlint.rb +7 -5
- data/lib/geojsonlint/geojson_validator.rb +2 -0
- data/lib/geojsonlint/version.rb +3 -1
- metadata +9 -55
- data/bin/console +0 -14
- data/bin/setup +0 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 1e4fcf8ea76d6ae6c3cb71421f4d6b1ec9a57001e50816626ac4ba70f3e40d46
|
4
|
+
data.tar.gz: 4c27cd74f9bbdd1e8303f026728a1db2e1bd43a120d5aaad571df50223135193
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ced67021d90face27b78ea0752a31e72f8e0336c445023f7cf97d666d2e2bbc8d7635069661008c1849c5358c285dd9757f2341b274370d9957b53f8b6cd4f97
|
7
|
+
data.tar.gz: 2ede11eb822c845fe94e88e3e8ac73f5f56ed777a1391faa230a6117cea4b4f59a71e7c0ddb0ee7be01b4906420bb997f88e475834be58ab1af9e38f5bf29ccb
|
data/.travis.yml
CHANGED
@@ -1,4 +1,25 @@
|
|
1
|
+
env:
|
2
|
+
global:
|
3
|
+
- CC_TEST_REPORTER_ID=79de1b602777e3ea40c5289db031d8d731bdb5d18bae0d0e65f46f0887aec6cd
|
4
|
+
|
1
5
|
language: ruby
|
2
6
|
|
3
7
|
rvm:
|
4
|
-
- 2.
|
8
|
+
- 2.3
|
9
|
+
- 2.4
|
10
|
+
- 2.5
|
11
|
+
- 2.6
|
12
|
+
|
13
|
+
before_install:
|
14
|
+
- gem install bundler
|
15
|
+
|
16
|
+
before_script:
|
17
|
+
- curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
|
18
|
+
- chmod +x ./cc-test-reporter
|
19
|
+
- ./cc-test-reporter before-build
|
20
|
+
|
21
|
+
script:
|
22
|
+
- bundle exec rspec
|
23
|
+
|
24
|
+
after_script:
|
25
|
+
- ./cc-test-reporter after-build --exit-code $TRAVIS_TEST_RESULT
|
data/Gemfile
CHANGED
@@ -1,8 +1,11 @@
|
|
1
1
|
source 'https://rubygems.org'
|
2
2
|
|
3
|
-
group :test do
|
4
|
-
gem 'activemodel', '>= 3.0.0'
|
5
|
-
gem 'coveralls', require: false
|
6
|
-
end
|
7
|
-
|
8
3
|
gemspec
|
4
|
+
|
5
|
+
group :development do
|
6
|
+
gem "coveralls"
|
7
|
+
gem "pry", "~> 0.11"
|
8
|
+
gem "rake"
|
9
|
+
gem "rspec", "~> 3.9"
|
10
|
+
gem "shoulda-matchers", "~> 4.0"
|
11
|
+
end
|
data/LICENSE.md
CHANGED
@@ -1,8 +1,21 @@
|
|
1
|
-
|
1
|
+
MIT License
|
2
2
|
|
3
|
-
|
3
|
+
Copyright (c) [2015] [Philippe Dionne]
|
4
4
|
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
13
|
+
copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
21
|
+
SOFTWARE.
|
data/README.md
CHANGED
@@ -3,9 +3,9 @@
|
|
3
3
|
A geoJSON validator.
|
4
4
|
|
5
5
|
[](http://badge.fury.io/rb/geojsonlint)
|
6
|
-
[](https://codeclimate.com/github/phildionne/geojsonlint)
|
7
|
+
[](https://coveralls.io/r/phildionne/geojsonlint)
|
8
|
+
[](https://travis-ci.org/phildionne/geojsonlint)
|
9
9
|
|
10
10
|
## Usage
|
11
11
|
|
@@ -79,7 +79,7 @@ To install this gem onto your local machine, run `bundle exec rake install`. To
|
|
79
79
|
|
80
80
|
## Contributing
|
81
81
|
|
82
|
-
1. Fork it ( https://github.com/
|
82
|
+
1. Fork it ( https://github.com/phildionne/geojsonlint/fork )
|
83
83
|
2. Create your feature branch (`git checkout -b my-new-feature`)
|
84
84
|
3. Commit your changes (`git commit -am 'Add some feature'`)
|
85
85
|
4. Push to the branch (`git push origin my-new-feature`)
|
@@ -94,13 +94,3 @@ To install this gem onto your local machine, run `bundle exec rake install`. To
|
|
94
94
|
* [geojsonlint.com](http://geojsonlint.com/) does this server-side
|
95
95
|
* [GeoJSON-Validation](https://github.com/craveprogramminginc/GeoJSON-Validation) is another node module for this.
|
96
96
|
* [geojson-assert](https://github.com/calvinmetcalf/geojson-assert) does it in assertion tests
|
97
|
-
|
98
|
-
## License
|
99
|
-
|
100
|
-
`geojsonlint` is © 2015 Can-Explore and may be freely distributed under the New BSD license. See the `LICENSE.md` file.
|
101
|
-
|
102
|
-
## About Can-Explore
|
103
|
-
|
104
|
-
Can-Explore is a team of passionate people brdiging the gap between technology and the world of civil engineering. We love building new things and get out of our comfort zone.
|
105
|
-
|
106
|
-
We love [open-source](https://github.com/can-explore) and we try to give back to the community as much as we can.
|
data/geojsonlint.gemspec
CHANGED
@@ -1,4 +1,5 @@
|
|
1
|
-
#
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
2
3
|
lib = File.expand_path('../lib', __FILE__)
|
3
4
|
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
5
|
require 'geojsonlint/version'
|
@@ -11,26 +12,13 @@ Gem::Specification.new do |spec|
|
|
11
12
|
|
12
13
|
spec.summary = %q{A geojson validator.}
|
13
14
|
spec.description = %q{A geojson validator.}
|
14
|
-
spec.homepage = "http://github.com/
|
15
|
-
spec.license = "
|
15
|
+
spec.homepage = "http://github.com/phildionne/geojsonlint"
|
16
|
+
spec.license = "MIT"
|
16
17
|
|
17
|
-
# Prevent pushing this gem to RubyGems.org by setting 'allowed_push_host', or
|
18
|
-
# delete this section to allow pushing this gem to any host.
|
19
|
-
if spec.respond_to?(:metadata)
|
20
|
-
spec.metadata['allowed_push_host'] = "https://rubygems.org"
|
21
|
-
else
|
22
|
-
raise "RubyGems 2.0 or newer is required to protect against public gem pushes."
|
23
|
-
end
|
24
18
|
|
25
19
|
spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
26
|
-
spec.bindir = "exe"
|
27
|
-
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
28
20
|
spec.require_paths = ["lib"]
|
29
21
|
|
30
|
-
spec.add_dependency "json-schema", "~> 2.
|
22
|
+
spec.add_dependency "json-schema", "~> 2.8"
|
31
23
|
spec.add_dependency "activemodel", ">= 3.0.0"
|
32
|
-
|
33
|
-
spec.add_development_dependency "bundler"
|
34
|
-
spec.add_development_dependency "rake"
|
35
|
-
spec.add_development_dependency "rspec", "~> 3.2"
|
36
24
|
end
|
data/lib/geojsonlint.rb
CHANGED
@@ -1,9 +1,11 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
require
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require "geojsonlint/version"
|
4
|
+
require "json"
|
5
|
+
require "json-schema"
|
4
6
|
|
5
7
|
if defined?(ActiveModel)
|
6
|
-
require
|
8
|
+
require "geojsonlint/geojson_validator"
|
7
9
|
end
|
8
10
|
|
9
11
|
module Geojsonlint
|
@@ -15,7 +17,7 @@ module Geojsonlint
|
|
15
17
|
def initialize(data)
|
16
18
|
@data = data
|
17
19
|
|
18
|
-
@schema = JSON.parse(File.read(File.expand_path(
|
20
|
+
@schema = JSON.parse(File.read(File.expand_path("../geojsonlint/geojson_schema.json", __FILE__)))
|
19
21
|
self
|
20
22
|
end
|
21
23
|
|
data/lib/geojsonlint/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: geojsonlint
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Philippe Dionne
|
8
8
|
autorequire:
|
9
|
-
bindir:
|
9
|
+
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2019-12-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: json-schema
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 2.
|
19
|
+
version: '2.8'
|
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: 2.
|
26
|
+
version: '2.8'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: activemodel
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -38,48 +38,6 @@ dependencies:
|
|
38
38
|
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: 3.0.0
|
41
|
-
- !ruby/object:Gem::Dependency
|
42
|
-
name: bundler
|
43
|
-
requirement: !ruby/object:Gem::Requirement
|
44
|
-
requirements:
|
45
|
-
- - ">="
|
46
|
-
- !ruby/object:Gem::Version
|
47
|
-
version: '0'
|
48
|
-
type: :development
|
49
|
-
prerelease: false
|
50
|
-
version_requirements: !ruby/object:Gem::Requirement
|
51
|
-
requirements:
|
52
|
-
- - ">="
|
53
|
-
- !ruby/object:Gem::Version
|
54
|
-
version: '0'
|
55
|
-
- !ruby/object:Gem::Dependency
|
56
|
-
name: rake
|
57
|
-
requirement: !ruby/object:Gem::Requirement
|
58
|
-
requirements:
|
59
|
-
- - ">="
|
60
|
-
- !ruby/object:Gem::Version
|
61
|
-
version: '0'
|
62
|
-
type: :development
|
63
|
-
prerelease: false
|
64
|
-
version_requirements: !ruby/object:Gem::Requirement
|
65
|
-
requirements:
|
66
|
-
- - ">="
|
67
|
-
- !ruby/object:Gem::Version
|
68
|
-
version: '0'
|
69
|
-
- !ruby/object:Gem::Dependency
|
70
|
-
name: rspec
|
71
|
-
requirement: !ruby/object:Gem::Requirement
|
72
|
-
requirements:
|
73
|
-
- - "~>"
|
74
|
-
- !ruby/object:Gem::Version
|
75
|
-
version: '3.2'
|
76
|
-
type: :development
|
77
|
-
prerelease: false
|
78
|
-
version_requirements: !ruby/object:Gem::Requirement
|
79
|
-
requirements:
|
80
|
-
- - "~>"
|
81
|
-
- !ruby/object:Gem::Version
|
82
|
-
version: '3.2'
|
83
41
|
description: A geojson validator.
|
84
42
|
email:
|
85
43
|
- dionne.phil@gmail.com
|
@@ -94,18 +52,15 @@ files:
|
|
94
52
|
- LICENSE.md
|
95
53
|
- README.md
|
96
54
|
- Rakefile
|
97
|
-
- bin/console
|
98
|
-
- bin/setup
|
99
55
|
- geojsonlint.gemspec
|
100
56
|
- lib/geojsonlint.rb
|
101
57
|
- lib/geojsonlint/geojson_schema.json
|
102
58
|
- lib/geojsonlint/geojson_validator.rb
|
103
59
|
- lib/geojsonlint/version.rb
|
104
|
-
homepage: http://github.com/
|
60
|
+
homepage: http://github.com/phildionne/geojsonlint
|
105
61
|
licenses:
|
106
|
-
-
|
107
|
-
metadata:
|
108
|
-
allowed_push_host: https://rubygems.org
|
62
|
+
- MIT
|
63
|
+
metadata: {}
|
109
64
|
post_install_message:
|
110
65
|
rdoc_options: []
|
111
66
|
require_paths:
|
@@ -121,8 +76,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
121
76
|
- !ruby/object:Gem::Version
|
122
77
|
version: '0'
|
123
78
|
requirements: []
|
124
|
-
|
125
|
-
rubygems_version: 2.4.5
|
79
|
+
rubygems_version: 3.0.3
|
126
80
|
signing_key:
|
127
81
|
specification_version: 4
|
128
82
|
summary: A geojson validator.
|
data/bin/console
DELETED
@@ -1,14 +0,0 @@
|
|
1
|
-
#!/usr/bin/env ruby
|
2
|
-
|
3
|
-
require "bundler/setup"
|
4
|
-
require "geojsonlint"
|
5
|
-
|
6
|
-
# You can add fixtures and/or initialization code here to make experimenting
|
7
|
-
# with your gem easier. You can also use a different console, if you like.
|
8
|
-
|
9
|
-
# (If you use this, don't forget to add pry to your Gemfile!)
|
10
|
-
# require "pry"
|
11
|
-
# Pry.start
|
12
|
-
|
13
|
-
require "irb"
|
14
|
-
IRB.start
|