sts2mn 1.0.0 → 1.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/rake.yml +32 -0
- data/.github/workflows/release-tag.yml +4 -4
- data/README.adoc +1 -3
- data/Rakefile +8 -6
- data/bin/sts2mn.jar +0 -0
- data/lib/sts2mn/version.rb +1 -1
- data/{mn2sts.gemspec → sts2mn.gemspec} +0 -0
- metadata +5 -7
- data/.github/workflows/macos.yml +0 -39
- data/.github/workflows/ubuntu.yml +0 -53
- data/.github/workflows/windows.yml +0 -41
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 14230b25560b003e3ab97798b4abeb1fc9af38d86d46fa8d571409951e272b0c
|
4
|
+
data.tar.gz: '09f663a9e2ce9f239817dde91809deade30b4fc12124ff41576c25f571245dd6'
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 501e826971129becbf71927199044da7e622232f7b7a2f20f90297f6edf12ac365340861a0e18ee980cd3d5e7fc2b4dc93764c840b1983c24d739a3312bd16a2
|
7
|
+
data.tar.gz: 23c9a4b704967babf1824f8cf9ffbd90b32aca94e1c338c81c7ee028346696a8f55fe568bf6945439531b8c159d70d0d42fc16adc0fb6ee6773dd64d75c1cf89
|
@@ -0,0 +1,32 @@
|
|
1
|
+
# Auto-generated by Cimas: Do not edit it manually!
|
2
|
+
# See https://github.com/metanorma/cimas
|
3
|
+
name: rake
|
4
|
+
|
5
|
+
on:
|
6
|
+
push:
|
7
|
+
branches: [ master, main ]
|
8
|
+
tags: [ v* ]
|
9
|
+
pull_request:
|
10
|
+
|
11
|
+
jobs:
|
12
|
+
rake:
|
13
|
+
name: Test on Ruby ${{ matrix.ruby }} ${{ matrix.os }}
|
14
|
+
runs-on: ${{ matrix.os }}
|
15
|
+
continue-on-error: ${{ matrix.experimental }}
|
16
|
+
strategy:
|
17
|
+
fail-fast: false
|
18
|
+
matrix:
|
19
|
+
ruby: [ '3.0', '2.7', '2.6', '2.5', '2.4' ]
|
20
|
+
os: [ ubuntu-latest, windows-latest, macos-latest ]
|
21
|
+
experimental: [ false ]
|
22
|
+
steps:
|
23
|
+
- uses: actions/checkout@v2
|
24
|
+
with:
|
25
|
+
submodules: true
|
26
|
+
|
27
|
+
- uses: ruby/setup-ruby@v1
|
28
|
+
with:
|
29
|
+
ruby-version: ${{ matrix.ruby }}
|
30
|
+
bundler-cache: true
|
31
|
+
|
32
|
+
- run: bundle exec rake
|
@@ -12,15 +12,15 @@ jobs:
|
|
12
12
|
- uses: actions/checkout@v1
|
13
13
|
- name: Add writable remote
|
14
14
|
run: |
|
15
|
-
git config --global user.name "
|
16
|
-
git config --global user.email "
|
17
|
-
git remote add github https://
|
15
|
+
git config --global user.name "metanorma-ci"
|
16
|
+
git config --global user.email "metanorma-ci@users.noreply.github.com"
|
17
|
+
git remote add github "https://metanorma-ci:${{ secrets.METANORMA_CI_PAT_TOKEN }}@github.com/$GITHUB_REPOSITORY.git"
|
18
18
|
git pull github ${GITHUB_REF} --ff-only
|
19
19
|
- name: Parse sts2mn version
|
20
20
|
env:
|
21
21
|
sts2mn_TAG: ${{ github.event.client_payload.ref }}
|
22
22
|
run: |
|
23
|
-
echo
|
23
|
+
echo sts2mn_VERSION=${sts2mn_TAG#*/v} >> ${GITHUB_ENV}
|
24
24
|
- name: Use Ruby
|
25
25
|
uses: actions/setup-ruby@v1
|
26
26
|
with:
|
data/README.adoc
CHANGED
@@ -1,9 +1,7 @@
|
|
1
1
|
= sts2mn Ruby gem
|
2
2
|
|
3
3
|
image:https://img.shields.io/gem/v/metanorma.svg["Gem Version", link="https://rubygems.org/gems/metanorma"]
|
4
|
-
image:https://github.com/metanorma/sts2mn-ruby/workflows/
|
5
|
-
image:https://github.com/metanorma/sts2mn-ruby/workflows/macos/badge.svg["OSX Build Status", link="https://github.com/metanorma/sts2mn-ruby/actions?query=workflow%3Amacos"]
|
6
|
-
image:https://github.com/metanorma/sts2mn-ruby/workflows/windows/badge.svg["Windows Build Status", link="https://github.com/metanorma/sts2mn-ruby/actions?query=workflow%3Awindows"]
|
4
|
+
image:https://github.com/metanorma/sts2mn-ruby/workflows/rake/badge.svg["Build Status", link="https://github.com/metanorma/sts2mn-ruby/actions?query=workflow%3Arake"]
|
7
5
|
image:https://codeclimate.com/github/metanorma/sts2mn-ruby/badges/gpa.svg["Code Climate", link="https://codeclimate.com/github/metanorma/sts2mn-ruby"]
|
8
6
|
image:https://img.shields.io/github/issues-pr-raw/metanorma/sts2mn-ruby.svg["Pull Requests", link="https://github.com/metanorma/sts2mn-ruby/pulls"]
|
9
7
|
image:https://img.shields.io/github/commits-since/metanorma/sts2mn-ruby/latest.svg["Commits since latest",link="https://github.com/metanorma/sts2mn-ruby/releases"]
|
data/Rakefile
CHANGED
@@ -7,13 +7,18 @@ RSpec::Core::RakeTask.new(:spec)
|
|
7
7
|
|
8
8
|
task :default => ['bin/sts2mn.jar', 'spec/fixtures/rice-en.final.sts.xml', :spec]
|
9
9
|
|
10
|
-
|
10
|
+
def uri_open(url)
|
11
|
+
if Gem::Version.new(RUBY_VERSION) < Gem::Version.new("2.5")
|
12
|
+
return open(url)
|
13
|
+
end
|
14
|
+
return URI.open(url)
|
15
|
+
end
|
11
16
|
|
12
17
|
file 'bin/sts2mn.jar' do |file|
|
13
18
|
ver = Sts2mn::STS2MN_JAR_VERSION
|
14
19
|
url = "https://github.com/metanorma/sts2mn/releases/download/v#{ver}/sts2mn-#{ver}.jar"
|
15
20
|
File.open(file.name, 'wb') do |file|
|
16
|
-
file.write
|
21
|
+
file.write uri_open(url).read
|
17
22
|
end
|
18
23
|
end
|
19
24
|
|
@@ -22,9 +27,6 @@ file 'spec/fixtures/rice-en.final.sts.xml' do |file|
|
|
22
27
|
|
23
28
|
File.open(file.name, "w") do |saved_file|
|
24
29
|
# the following "open" is provided by open-uri
|
25
|
-
|
26
|
-
saved_file.write(read_file.read)
|
27
|
-
end
|
30
|
+
saved_file.write(uri_open(uri).read)
|
28
31
|
end
|
29
|
-
|
30
32
|
end
|
data/bin/sts2mn.jar
CHANGED
Binary file
|
data/lib/sts2mn/version.rb
CHANGED
File without changes
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sts2mn
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-06-23 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: |
|
14
14
|
sts2mn converts NISO STS XML into Metanorma XML.
|
@@ -20,11 +20,9 @@ executables: []
|
|
20
20
|
extensions: []
|
21
21
|
extra_rdoc_files: []
|
22
22
|
files:
|
23
|
-
- ".github/workflows/
|
23
|
+
- ".github/workflows/rake.yml"
|
24
24
|
- ".github/workflows/release-tag.yml"
|
25
25
|
- ".github/workflows/release.yml"
|
26
|
-
- ".github/workflows/ubuntu.yml"
|
27
|
-
- ".github/workflows/windows.yml"
|
28
26
|
- ".gitignore"
|
29
27
|
- ".rspec"
|
30
28
|
- CODE_OF_CONDUCT.md
|
@@ -36,7 +34,7 @@ files:
|
|
36
34
|
- bin/sts2mn.jar
|
37
35
|
- lib/sts2mn.rb
|
38
36
|
- lib/sts2mn/version.rb
|
39
|
-
-
|
37
|
+
- sts2mn.gemspec
|
40
38
|
homepage: https://github.com/metanorma/sts2mn-ruby
|
41
39
|
licenses:
|
42
40
|
- BSD-2-Clause
|
@@ -56,7 +54,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
56
54
|
- !ruby/object:Gem::Version
|
57
55
|
version: '0'
|
58
56
|
requirements: []
|
59
|
-
rubygems_version: 3.0.3
|
57
|
+
rubygems_version: 3.0.3.1
|
60
58
|
signing_key:
|
61
59
|
specification_version: 4
|
62
60
|
summary: sts2mn converts NISO STS XML into Metanorma XML.
|
data/.github/workflows/macos.yml
DELETED
@@ -1,39 +0,0 @@
|
|
1
|
-
# Auto-generated by Cimas: Do not edit it manually!
|
2
|
-
# See https://github.com/metanorma/cimas
|
3
|
-
name: macos
|
4
|
-
|
5
|
-
on:
|
6
|
-
push:
|
7
|
-
branches: [ master ]
|
8
|
-
pull_request:
|
9
|
-
paths-ignore:
|
10
|
-
- .github/workflows/ubuntu.yml
|
11
|
-
- .github/workflows/windows.yml
|
12
|
-
|
13
|
-
jobs:
|
14
|
-
test-macos:
|
15
|
-
name: Test on Ruby ${{ matrix.ruby }} macOS
|
16
|
-
runs-on: macos-latest
|
17
|
-
continue-on-error: ${{ matrix.experimental }}
|
18
|
-
strategy:
|
19
|
-
fail-fast: false
|
20
|
-
matrix:
|
21
|
-
ruby: [ '2.6', '2.5', '2.4' ]
|
22
|
-
experimental: [false]
|
23
|
-
include:
|
24
|
-
- ruby: '2.7'
|
25
|
-
experimental: true
|
26
|
-
steps:
|
27
|
-
- uses: actions/checkout@master
|
28
|
-
- name: Use Ruby
|
29
|
-
uses: actions/setup-ruby@v1
|
30
|
-
with:
|
31
|
-
ruby-version: ${{ matrix.ruby }}
|
32
|
-
architecture: 'x64'
|
33
|
-
- name: Update gems
|
34
|
-
run: |
|
35
|
-
sudo gem install bundler --force
|
36
|
-
bundle install --jobs 4 --retry 3
|
37
|
-
- name: Run specs
|
38
|
-
run: |
|
39
|
-
bundle exec rake
|
@@ -1,53 +0,0 @@
|
|
1
|
-
# Auto-generated by Cimas: Do not edit it manually!
|
2
|
-
# See https://github.com/metanorma/cimas
|
3
|
-
name: ubuntu
|
4
|
-
|
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
|
14
|
-
|
15
|
-
jobs:
|
16
|
-
test-linux:
|
17
|
-
name: Test on Ruby ${{ matrix.ruby }} Ubuntu
|
18
|
-
runs-on: ubuntu-latest
|
19
|
-
continue-on-error: ${{ matrix.experimental }}
|
20
|
-
strategy:
|
21
|
-
fail-fast: false
|
22
|
-
matrix:
|
23
|
-
ruby: [ '2.6', '2.5', '2.4' ]
|
24
|
-
experimental: [false]
|
25
|
-
include:
|
26
|
-
- ruby: '2.7'
|
27
|
-
experimental: true
|
28
|
-
steps:
|
29
|
-
- uses: actions/checkout@master
|
30
|
-
- name: Use Ruby
|
31
|
-
uses: actions/setup-ruby@v1
|
32
|
-
with:
|
33
|
-
ruby-version: ${{ matrix.ruby }}
|
34
|
-
architecture: 'x64'
|
35
|
-
- name: Update gems
|
36
|
-
run: |
|
37
|
-
gem install bundler
|
38
|
-
bundle install --jobs 4 --retry 3
|
39
|
-
- name: Run specs
|
40
|
-
run: |
|
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,41 +0,0 @@
|
|
1
|
-
# Auto-generated by Cimas: Do not edit it manually!
|
2
|
-
# See https://github.com/metanorma/cimas
|
3
|
-
name: windows
|
4
|
-
|
5
|
-
on:
|
6
|
-
push:
|
7
|
-
branches: [ master ]
|
8
|
-
pull_request:
|
9
|
-
paths-ignore:
|
10
|
-
- .github/workflows/macos.yml
|
11
|
-
- .github/workflows/ubuntu.yml
|
12
|
-
|
13
|
-
jobs:
|
14
|
-
test-windows:
|
15
|
-
name: Test on Ruby ${{ matrix.ruby }} Windows
|
16
|
-
runs-on: windows-latest
|
17
|
-
continue-on-error: ${{ matrix.experimental }}
|
18
|
-
strategy:
|
19
|
-
fail-fast: false
|
20
|
-
matrix:
|
21
|
-
ruby: [ '2.6', '2.5', '2.4' ]
|
22
|
-
experimental: [false]
|
23
|
-
include:
|
24
|
-
- ruby: '2.7'
|
25
|
-
experimental: true
|
26
|
-
steps:
|
27
|
-
- uses: actions/checkout@master
|
28
|
-
- name: Use Ruby
|
29
|
-
uses: actions/setup-ruby@v1
|
30
|
-
with:
|
31
|
-
ruby-version: ${{ matrix.ruby }}
|
32
|
-
architecture: 'x64'
|
33
|
-
- name: Update gems
|
34
|
-
shell: pwsh
|
35
|
-
run: |
|
36
|
-
gem install bundler
|
37
|
-
bundle config --local path vendor/bundle
|
38
|
-
bundle install --jobs 4 --retry 3
|
39
|
-
- name: Run specs
|
40
|
-
run: |
|
41
|
-
bundle exec rake
|