cnccs 0.1.5 → 0.1.6

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e3fb5ce410ccef55d72a0e4891b167124cd4a797481bcc12aeda694caf395030
4
- data.tar.gz: c63ff80f43ff2727a631bfa9a5b46ec7356a6ce6be4f86ce6c3e950e4e925e9b
3
+ metadata.gz: 0fdce9dc33d6dfe444346aaa7779a6fec2389d7a1d2f8173642ca1af23ce4e4d
4
+ data.tar.gz: 2d0f018fab5db2bf4f1b67aa528dcac12a6a9e645e9bbbc6d8b669988c61cf3a
5
5
  SHA512:
6
- metadata.gz: 1421ede0a184e52f36fde9ee7d699e1fb0235f3986a02257071fd7744462b4040b58bb74e7ab656c82388839b0f364c97471a165a099783e09074680edddeb2c
7
- data.tar.gz: 49f35641cfc7b5fd02a26c91b23ad809accea8394ffe0fb4b088a60cbab63cca915fdc9251be546ea733fd07ac2b1285f7dcb9d4e753a24f65fe6f7a2b8d7c95
6
+ metadata.gz: 132f13b49169fc4ac73cc91b4ef3d7fe78b015361563393c159b47d023c6e1208e833cef5adbe02f6967ec4c39d7e54e85214ec9a644f6b332e97b57b5b39dd4
7
+ data.tar.gz: da42aeb8630c8dbc856efbe813eb675f4dd5fdaf1e4a523f0abdf699d871592c307f4d1c708f97d229d0d09c44d3eeec35533ebd7fc09a1a6b2cb73abc999ece
@@ -1,16 +1,28 @@
1
- # Auto-generated !!! Do not edit it manually
2
- # use ci-master https://github.com/metanorma/metanorma-build-scripts
1
+ # Auto-generated by Cimas: Do not edit it manually!
2
+ # See https://github.com/metanorma/cimas
3
3
  name: macos
4
4
 
5
- on: [push]
5
+ on:
6
+ push:
7
+ branches: [ master ]
8
+ pull_request:
9
+ paths-ignore:
10
+ - .github/workflows/ubuntu.yml
11
+ - .github/workflows/windows.yml
6
12
 
7
13
  jobs:
8
14
  test-macos:
9
15
  name: Test on Ruby ${{ matrix.ruby }} macOS
10
16
  runs-on: macos-latest
17
+ continue-on-error: ${{ matrix.experimental }}
11
18
  strategy:
19
+ fail-fast: false
12
20
  matrix:
13
21
  ruby: [ '2.6', '2.5', '2.4' ]
22
+ experimental: [false]
23
+ include:
24
+ - ruby: '2.7'
25
+ experimental: true
14
26
  steps:
15
27
  - uses: actions/checkout@master
16
28
  - name: Use Ruby
@@ -20,7 +32,7 @@ jobs:
20
32
  architecture: 'x64'
21
33
  - name: Update gems
22
34
  run: |
23
- sudo gem install bundler -v "~> 2" --force
35
+ sudo gem install bundler --force
24
36
  bundle install --jobs 4 --retry 3
25
37
  - name: Run specs
26
38
  run: |
@@ -1,16 +1,30 @@
1
- # Auto-generated !!! Do not edit it manually
2
- # use ci-master https://github.com/metanorma/metanorma-build-scripts
1
+ # Auto-generated by Cimas: Do not edit it manually!
2
+ # See https://github.com/metanorma/cimas
3
3
  name: ubuntu
4
4
 
5
- on: [push]
5
+ on:
6
+ push:
7
+ branches: [ master ]
8
+ tags:
9
+ - '*'
10
+ pull_request:
11
+ paths-ignore:
12
+ - .github/workflows/macos.yml
13
+ - .github/workflows/windows.yml
6
14
 
7
15
  jobs:
8
16
  test-linux:
9
17
  name: Test on Ruby ${{ matrix.ruby }} Ubuntu
10
18
  runs-on: ubuntu-latest
19
+ continue-on-error: ${{ matrix.experimental }}
11
20
  strategy:
21
+ fail-fast: false
12
22
  matrix:
13
23
  ruby: [ '2.6', '2.5', '2.4' ]
24
+ experimental: [false]
25
+ include:
26
+ - ruby: '2.7'
27
+ experimental: true
14
28
  steps:
15
29
  - uses: actions/checkout@master
16
30
  - name: Use Ruby
@@ -20,8 +34,20 @@ jobs:
20
34
  architecture: 'x64'
21
35
  - name: Update gems
22
36
  run: |
23
- gem install bundler -v "~> 2"
37
+ gem install bundler
24
38
  bundle install --jobs 4 --retry 3
25
39
  - name: Run specs
26
40
  run: |
27
41
  bundle exec rake
42
+ - name: Trigger dependent repositories
43
+ if: github.ref == 'refs/heads/master' && matrix.ruby == '2.6'
44
+ env:
45
+ GH_USERNAME: ${{ secrets.PAT_USERNAME }}
46
+ GH_ACCESS_TOKEN: ${{ secrets.PAT_TOKEN }}
47
+ run: |
48
+ curl -LO --retry 3 https://raw.githubusercontent.com/metanorma/metanorma-build-scripts/master/trigger-gh-actions.sh
49
+ [[ -f ".github/workflows/dependent_repos.env" ]] && source .github/workflows/dependent_repos.env
50
+ for repo in $DEPENDENT_REPOS
51
+ do
52
+ sh trigger-gh-actions.sh $ORGANISATION $repo $GH_USERNAME $GH_ACCESS_TOKEN $GITHUB_REPOSITORY "{ \"ref\": \"${GITHUB_REF}\" }"
53
+ done
@@ -1,16 +1,28 @@
1
- # Auto-generated !!! Do not edit it manually
2
- # use ci-master https://github.com/metanorma/metanorma-build-scripts
1
+ # Auto-generated by Cimas: Do not edit it manually!
2
+ # See https://github.com/metanorma/cimas
3
3
  name: windows
4
4
 
5
- on: [push]
5
+ on:
6
+ push:
7
+ branches: [ master ]
8
+ pull_request:
9
+ paths-ignore:
10
+ - .github/workflows/macos.yml
11
+ - .github/workflows/ubuntu.yml
6
12
 
7
13
  jobs:
8
14
  test-windows:
9
15
  name: Test on Ruby ${{ matrix.ruby }} Windows
10
16
  runs-on: windows-latest
17
+ continue-on-error: ${{ matrix.experimental }}
11
18
  strategy:
19
+ fail-fast: false
12
20
  matrix:
13
21
  ruby: [ '2.6', '2.5', '2.4' ]
22
+ experimental: [false]
23
+ include:
24
+ - ruby: '2.7'
25
+ experimental: true
14
26
  steps:
15
27
  - uses: actions/checkout@master
16
28
  - name: Use Ruby
@@ -21,9 +33,8 @@ jobs:
21
33
  - name: Update gems
22
34
  shell: pwsh
23
35
  run: |
24
- gem install bundler -v "~> 2"
36
+ gem install bundler
25
37
  bundle config --local path vendor/bundle
26
- bundle update
27
38
  bundle install --jobs 4 --retry 3
28
39
  - name: Run specs
29
40
  run: |
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- cnccs (0.1.4)
4
+ cnccs (0.1.5)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
@@ -10,7 +10,7 @@ GEM
10
10
  coderay (1.1.2)
11
11
  diff-lcs (1.3)
12
12
  docile (1.3.2)
13
- json (2.2.0)
13
+ json (2.3.0)
14
14
  method_source (0.9.2)
15
15
  pry (0.12.2)
16
16
  coderay (~> 1.1.0)
@@ -18,7 +18,7 @@ GEM
18
18
  pry-byebug (3.7.0)
19
19
  byebug (~> 11.0)
20
20
  pry (~> 0.10)
21
- rake (10.5.0)
21
+ rake (13.0.1)
22
22
  rspec (3.9.0)
23
23
  rspec-core (~> 3.9.0)
24
24
  rspec-expectations (~> 3.9.0)
@@ -42,10 +42,10 @@ PLATFORMS
42
42
  ruby
43
43
 
44
44
  DEPENDENCIES
45
- bundler (~> 2.0.1)
45
+ bundler
46
46
  cnccs!
47
47
  pry-byebug
48
- rake (~> 10.0)
48
+ rake (~> 13.0)
49
49
  rspec (~> 3.0)
50
50
  simplecov
51
51
 
@@ -1,8 +1,12 @@
1
1
  = CnCcs: Ruby gem for using CCS codes
2
2
 
3
3
  image:https://img.shields.io/gem/v/cnccs.svg["Gem Version", link="https://rubygems.org/gems/cnccs"]
4
- image:https://img.shields.io/travis/metanorma/cnccs/master.svg["Build Status", link="https://travis-ci.com/metanorma/cnccs"]
4
+ image:https://github.com/metanorma/cnccs/workflows/ubuntu/badge.svg["Ubuntu Build Status", link="https://github.com/metanorma/cnccs/actions?query=workflow%3Aubuntu"]
5
+ image:https://github.com/metanorma/cnccs/workflows/macos/badge.svg["OSX Build Status", link="https://github.com/metanorma/cnccs/actions?query=workflow%3Amacos"]
6
+ image:https://github.com/metanorma/cnccs/workflows/windows/badge.svg["Windows Build Status", link="https://github.com/metanorma/cnccs/actions?query=workflow%3Awindows"]
5
7
  image:https://codeclimate.com/github/metanorma/cnccs/badges/gpa.svg["Code Climate", link="https://codeclimate.com/github/metanorma/cnccs"]
8
+ image:https://img.shields.io/github/issues-pr-raw/metanorma/cnccs.svg["Pull Requests", link="https://github.com/metanorma/cnccs/pulls"]
9
+ image:https://img.shields.io/github/commits-since/metanorma/cnccs/latest.svg["Commits since latest",link="https://github.com/metanorma/cnccs/releases"]
6
10
 
7
11
 
8
12
  The categories used in the Classification of Chinese Standards ("CCS")
@@ -22,8 +22,8 @@ Gem::Specification.new do |spec|
22
22
  spec.require_paths = ["lib"]
23
23
  spec.required_ruby_version = Gem::Requirement.new(">= 2.4.0")
24
24
 
25
- spec.add_development_dependency "bundler", "~> 2.0.1"
26
- spec.add_development_dependency "rake", "~> 10.0"
25
+ spec.add_development_dependency "bundler"
26
+ spec.add_development_dependency "rake", "~> 13.0"
27
27
  spec.add_development_dependency "rspec", "~> 3.0"
28
28
  spec.add_development_dependency "simplecov"
29
29
  spec.add_development_dependency "pry-byebug"
@@ -79,7 +79,7 @@ module Cnccs
79
79
  # @param match [String]
80
80
  # @return [Array<String, Array>]
81
81
  def fetch_data(level, match)
82
- csv = CSV.read "#{__dir__}/../../cn-ccs-codes/cat-level#{level}.csv", "rb:UTF-8", headers: true
82
+ csv = CSV.read "#{__dir__}/../../cn-ccs-codes/cat-level#{level}.csv", encoding: "UTF-8", headers: true
83
83
  row = csv.find { |r| r[0] == match }
84
84
  row.map(&:last)
85
85
  end
@@ -1,3 +1,3 @@
1
1
  module Cnccs
2
- VERSION = "0.1.5"
2
+ VERSION = "0.1.6"
3
3
  end
metadata CHANGED
@@ -1,43 +1,43 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cnccs
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.5
4
+ version: 0.1.6
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-10-20 00:00:00.000000000 Z
11
+ date: 2020-05-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: 2.0.1
19
+ version: '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: 2.0.1
26
+ version: '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
42
  name: rspec
43
43
  requirement: !ruby/object:Gem::Requirement
@@ -129,8 +129,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
129
129
  - !ruby/object:Gem::Version
130
130
  version: '0'
131
131
  requirements: []
132
- rubyforge_project:
133
- rubygems_version: 2.7.6
132
+ rubygems_version: 3.0.3
134
133
  signing_key:
135
134
  specification_version: 4
136
135
  summary: Classification of Chinese Standards ("CCS") are accessible via this gem.