relaton-nist 0.3.4 → 0.3.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/.github/workflows/macos.yml +29 -0
- data/.github/workflows/ubuntu.yml +29 -0
- data/.github/workflows/windows.yml +32 -0
- data/Gemfile.lock +4 -4
- data/lib/relaton_nist/hit_collection.rb +3 -1
- data/lib/relaton_nist/processor.rb +1 -1
- data/lib/relaton_nist/scrapper.rb +1 -1
- data/lib/relaton_nist/version.rb +1 -1
- metadata +6 -7
- data/.travis.yml +0 -18
- data/appveyor.yml +0 -37
- data/lib/relaton_nist/data/pubs-export.zip +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 6329d1d8733e0a9f985b715ed3d50ceeb2c49f3d5b9b26d36d355206d91df1a9
|
4
|
+
data.tar.gz: 95063e554e41ab590662c5c0c6b0e9da08a7e3117d404189d124adc8ff55ef10
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 12ece7058d095c769db69ecee8234813fdd7aa5ad2df920e9ea183a1dad185cafc8a22a84f77884f42dea50ee447ae9b0934fa57841916eafcd127013290c315
|
7
|
+
data.tar.gz: 07cea2e965fd39ced4df492dda4a48491437cb499acf5c7cbea0c8b75f8bd0057f2f715e6944fe1a69bbfdaed8a097fa3185a7ef88703dea5a95f3d3797daaec
|
@@ -0,0 +1,29 @@
|
|
1
|
+
# Auto-generated !!! Do not edit it manually
|
2
|
+
# use ci-master https://github.com/metanorma/metanorma-build-scripts
|
3
|
+
name: macos
|
4
|
+
|
5
|
+
on: [push]
|
6
|
+
|
7
|
+
jobs:
|
8
|
+
test-macos:
|
9
|
+
name: Test on Ruby ${{ matrix.ruby }} macOS
|
10
|
+
runs-on: macos-latest
|
11
|
+
strategy:
|
12
|
+
matrix:
|
13
|
+
ruby: [ '2.6', '2.5', '2.4' ]
|
14
|
+
steps:
|
15
|
+
- uses: actions/checkout@master
|
16
|
+
with:
|
17
|
+
submodules: recursive
|
18
|
+
- name: Use Ruby
|
19
|
+
uses: actions/setup-ruby@v1
|
20
|
+
with:
|
21
|
+
ruby-version: ${{ matrix.ruby }}
|
22
|
+
architecture: 'x64'
|
23
|
+
- name: Update gems
|
24
|
+
run: |
|
25
|
+
sudo gem install bundler -v "~> 2" --force
|
26
|
+
bundle install --jobs 4 --retry 3
|
27
|
+
- name: Run specs
|
28
|
+
run: |
|
29
|
+
bundle exec rake
|
@@ -0,0 +1,29 @@
|
|
1
|
+
# Auto-generated !!! Do not edit it manually
|
2
|
+
# use ci-master https://github.com/metanorma/metanorma-build-scripts
|
3
|
+
name: ubuntu
|
4
|
+
|
5
|
+
on: [push]
|
6
|
+
|
7
|
+
jobs:
|
8
|
+
test-linux:
|
9
|
+
name: Test on Ruby ${{ matrix.ruby }} Ubuntu
|
10
|
+
runs-on: ubuntu-latest
|
11
|
+
strategy:
|
12
|
+
matrix:
|
13
|
+
ruby: [ '2.6', '2.5', '2.4' ]
|
14
|
+
steps:
|
15
|
+
- uses: actions/checkout@master
|
16
|
+
with:
|
17
|
+
submodules: recursive
|
18
|
+
- name: Use Ruby
|
19
|
+
uses: actions/setup-ruby@v1
|
20
|
+
with:
|
21
|
+
ruby-version: ${{ matrix.ruby }}
|
22
|
+
architecture: 'x64'
|
23
|
+
- name: Update gems
|
24
|
+
run: |
|
25
|
+
gem install bundler -v "~> 2"
|
26
|
+
bundle install --jobs 4 --retry 3
|
27
|
+
- name: Run specs
|
28
|
+
run: |
|
29
|
+
bundle exec rake
|
@@ -0,0 +1,32 @@
|
|
1
|
+
# Auto-generated !!! Do not edit it manually
|
2
|
+
# use ci-master https://github.com/metanorma/metanorma-build-scripts
|
3
|
+
name: windows
|
4
|
+
|
5
|
+
on: [push]
|
6
|
+
|
7
|
+
jobs:
|
8
|
+
test-windows:
|
9
|
+
name: Test on Ruby ${{ matrix.ruby }} Windows
|
10
|
+
runs-on: windows-latest
|
11
|
+
strategy:
|
12
|
+
matrix:
|
13
|
+
ruby: [ '2.6', '2.5', '2.4' ]
|
14
|
+
steps:
|
15
|
+
- uses: actions/checkout@master
|
16
|
+
with:
|
17
|
+
submodules: recursive
|
18
|
+
- name: Use Ruby
|
19
|
+
uses: actions/setup-ruby@v1
|
20
|
+
with:
|
21
|
+
ruby-version: ${{ matrix.ruby }}
|
22
|
+
architecture: 'x64'
|
23
|
+
- name: Update gems
|
24
|
+
shell: pwsh
|
25
|
+
run: |
|
26
|
+
gem install bundler -v "~> 2"
|
27
|
+
bundle config --local path vendor/bundle
|
28
|
+
bundle update
|
29
|
+
bundle install --jobs 4 --retry 3
|
30
|
+
- name: Run specs
|
31
|
+
run: |
|
32
|
+
bundle exec rake
|
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
relaton-nist (0.3.
|
4
|
+
relaton-nist (0.3.9)
|
5
5
|
relaton-bib (~> 0.3.0)
|
6
6
|
rubyzip
|
7
7
|
|
@@ -35,7 +35,7 @@ GEM
|
|
35
35
|
pry (~> 0.10)
|
36
36
|
public_suffix (4.0.1)
|
37
37
|
rake (10.5.0)
|
38
|
-
relaton-bib (0.3.
|
38
|
+
relaton-bib (0.3.12)
|
39
39
|
addressable
|
40
40
|
nokogiri
|
41
41
|
rspec (3.8.0)
|
@@ -53,7 +53,7 @@ GEM
|
|
53
53
|
rspec-support (3.8.2)
|
54
54
|
ruby-debug-ide (0.7.0)
|
55
55
|
rake (>= 0.8.1)
|
56
|
-
rubyzip (
|
56
|
+
rubyzip (2.0.0)
|
57
57
|
safe_yaml (1.0.5)
|
58
58
|
simplecov (0.16.1)
|
59
59
|
docile (~> 1.1)
|
@@ -84,4 +84,4 @@ DEPENDENCIES
|
|
84
84
|
webmock
|
85
85
|
|
86
86
|
BUNDLED WITH
|
87
|
-
2.0.
|
87
|
+
2.0.2
|
@@ -10,7 +10,8 @@ module RelatonNist
|
|
10
10
|
# Page of hit collection.
|
11
11
|
class HitCollection < RelatonBib::HitCollection
|
12
12
|
DOMAIN = "https://csrc.nist.gov"
|
13
|
-
|
13
|
+
DATAFILEDIR = File.expand_path ".relaton/nist", Dir.home
|
14
|
+
DATAFILE = File.expand_path "pubs-export.zip", DATAFILEDIR
|
14
15
|
|
15
16
|
# rubocop:disable Metrics/AbcSize, Metrics/MethodLength
|
16
17
|
|
@@ -139,6 +140,7 @@ module RelatonNist
|
|
139
140
|
@data = nil
|
140
141
|
zip = OpenURI.open_uri "https://csrc.nist.gov/CSRC/media/feeds/metanorma/pubs-export.zip"
|
141
142
|
zip.close
|
143
|
+
FileUtils.mkdir_p DATAFILEDIR unless Dir.exist? DATAFILEDIR
|
142
144
|
FileUtils.mv zip.path, DATAFILE
|
143
145
|
end
|
144
146
|
end
|
@@ -21,7 +21,7 @@ module RelatonNist
|
|
21
21
|
unless /^(SP|NISTIR|FIPS) / =~ item_data[:docid][0].id
|
22
22
|
doctype = id_cleanup(item_data[:docid][0].id)
|
23
23
|
item_data[:docid][0] = RelatonBib::DocumentIdentifier.new(
|
24
|
-
id: titles[0][:content], type: "NIST",
|
24
|
+
id: titles[0][:content].upcase, type: "NIST",
|
25
25
|
)
|
26
26
|
end
|
27
27
|
item_data[:fetched] = Date.today.to_s
|
data/lib/relaton_nist/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: relaton-nist
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.9
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-
|
11
|
+
date: 2019-12-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -199,21 +199,21 @@ executables: []
|
|
199
199
|
extensions: []
|
200
200
|
extra_rdoc_files: []
|
201
201
|
files:
|
202
|
+
- ".github/workflows/macos.yml"
|
203
|
+
- ".github/workflows/ubuntu.yml"
|
204
|
+
- ".github/workflows/windows.yml"
|
202
205
|
- ".gitignore"
|
203
206
|
- ".rspec"
|
204
207
|
- ".rubocop.yml"
|
205
|
-
- ".travis.yml"
|
206
208
|
- Gemfile
|
207
209
|
- Gemfile.lock
|
208
210
|
- LICENSE.txt
|
209
211
|
- README.adoc
|
210
212
|
- Rakefile
|
211
|
-
- appveyor.yml
|
212
213
|
- bin/console
|
213
214
|
- bin/setup
|
214
215
|
- lib/relaton_nist.rb
|
215
216
|
- lib/relaton_nist/comment_period.rb
|
216
|
-
- lib/relaton_nist/data/pubs-export.zip
|
217
217
|
- lib/relaton_nist/document_status.rb
|
218
218
|
- lib/relaton_nist/hash_converter.rb
|
219
219
|
- lib/relaton_nist/hit.rb
|
@@ -245,8 +245,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
245
245
|
- !ruby/object:Gem::Version
|
246
246
|
version: '0'
|
247
247
|
requirements: []
|
248
|
-
|
249
|
-
rubygems_version: 2.6.12
|
248
|
+
rubygems_version: 3.0.6
|
250
249
|
signing_key:
|
251
250
|
specification_version: 4
|
252
251
|
summary: 'RelatonNist: retrive NIST standards.'
|
data/.travis.yml
DELETED
@@ -1,18 +0,0 @@
|
|
1
|
-
# Auto-generated !!! Do not edit it manually
|
2
|
-
# use ci-master https://github.com/metanorma/metanorma-build-scripts
|
3
|
-
language: ruby
|
4
|
-
cache: bundler
|
5
|
-
os:
|
6
|
-
- linux
|
7
|
-
- osx
|
8
|
-
rvm:
|
9
|
-
- 2.6
|
10
|
-
- 2.5
|
11
|
-
- 2.4
|
12
|
-
- ruby-head
|
13
|
-
before_install:
|
14
|
-
- gem install bundler -v "~> 2"
|
15
|
-
- bundle update
|
16
|
-
matrix:
|
17
|
-
allow_failures:
|
18
|
-
- rvm: ruby-head
|
data/appveyor.yml
DELETED
@@ -1,37 +0,0 @@
|
|
1
|
-
# Auto-generated !!! Do not edit it manually
|
2
|
-
# use ci-master https://github.com/metanorma/metanorma-build-scripts
|
3
|
-
version: '{build}'
|
4
|
-
|
5
|
-
cache:
|
6
|
-
- vendor/bundle
|
7
|
-
|
8
|
-
environment:
|
9
|
-
matrix:
|
10
|
-
- RUBY_VERSION: 26
|
11
|
-
- RUBY_VERSION: 25
|
12
|
-
- RUBY_VERSION: 24
|
13
|
-
- RUBY_VERSION: _trunk
|
14
|
-
|
15
|
-
matrix:
|
16
|
-
allow_failures:
|
17
|
-
- RUBY_VERSION: _trunk
|
18
|
-
|
19
|
-
install:
|
20
|
-
- ps: . { iwr -useb https://raw.githubusercontent.com/metanorma/metanorma-build-scripts/master/appveyor.ps1 } | iex
|
21
|
-
- refreshenv
|
22
|
-
|
23
|
-
build_script:
|
24
|
-
- set PATH=C:\Ruby%RUBY_VERSION%\bin;%PATH%
|
25
|
-
- set GIT_TERMINAL_PROMPT=0
|
26
|
-
- gem install bundler -v "~> 2"
|
27
|
-
- bundle config --local path vendor/bundle
|
28
|
-
- bundle update
|
29
|
-
- bundle install
|
30
|
-
|
31
|
-
before_test:
|
32
|
-
- ruby -v
|
33
|
-
- gem -v
|
34
|
-
- bundle -v
|
35
|
-
|
36
|
-
test_script:
|
37
|
-
- bundle exec rake
|
Binary file
|