relaton-cli 0.1.9 → 0.1.10
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 +4 -4
- data/.travis.yml +12 -12
- data/appveyor.yml +29 -0
- data/docs/README.adoc +4 -3
- data/lib/relaton/bibdata.rb +1 -0
- data/lib/relaton/cli/relaton_file.rb +8 -0
- data/lib/relaton/cli/version.rb +1 -1
- data/relaton-cli.gemspec +1 -1
- metadata +4 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: f1e8d976c2b02974585ecdae77bf5737e7d3b2701c79f168ab44d775c005935e
|
|
4
|
+
data.tar.gz: 39c205cb7863fb70e43c465c28e87ae54935501b1f9ef0427ef0349b7cbb3047
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: fa32c9beb7744a8eba3d41661ac68a5010923b7a7017e29c145d75b37694916203a71365daa69a8ff76148164aee335837752904c3daa3c3d7ecbac16e5cdfb3
|
|
7
|
+
data.tar.gz: c430918d1db7b87438a8e5b64e34bed702ffdeabf07dc06bcc3911b60327d9ad05ab8ab4ec2a70a7b03f7129d8a7626e0bd599b3e86a06ca341d5232f0eec86f
|
data/.travis.yml
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
dist: trusty
|
|
2
|
-
sudo: false
|
|
3
1
|
language: ruby
|
|
2
|
+
cache: bundler
|
|
3
|
+
os:
|
|
4
|
+
- linux
|
|
5
|
+
- osx
|
|
4
6
|
rvm:
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
- 2.5
|
|
8
|
+
- 2.4
|
|
9
|
+
- 2.3
|
|
10
|
+
- ruby-head
|
|
10
11
|
before_install:
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
12
|
+
- gem install bundler -v 2.0.1
|
|
13
|
+
- bundle update
|
|
14
|
+
- mkdir ./tmp
|
|
15
|
+
- mkdir ~/.relaton
|
|
16
16
|
matrix:
|
|
17
17
|
allow_failures:
|
|
18
18
|
- rvm: 2.3
|
data/appveyor.yml
ADDED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
version: '{build}'
|
|
2
|
+
|
|
3
|
+
environment:
|
|
4
|
+
matrix:
|
|
5
|
+
- RUBY_VERSION: 25
|
|
6
|
+
- RUBY_VERSION: 24
|
|
7
|
+
- RUBY_VERSION: _trunk
|
|
8
|
+
|
|
9
|
+
matrix:
|
|
10
|
+
allow_failures:
|
|
11
|
+
- RUBY_VERSION: _trunk
|
|
12
|
+
|
|
13
|
+
install:
|
|
14
|
+
- ps: . { iwr -useb https://raw.githubusercontent.com/metanorma/metanorma-build-scripts/master/appveyor.ps1 } | iex
|
|
15
|
+
- refreshenv
|
|
16
|
+
|
|
17
|
+
build_script:
|
|
18
|
+
- set PATH=C:\Ruby%RUBY_VERSION%\bin;%PATH%
|
|
19
|
+
- bundle update
|
|
20
|
+
- bundle install
|
|
21
|
+
|
|
22
|
+
before_test:
|
|
23
|
+
- ruby -v
|
|
24
|
+
- gem -v
|
|
25
|
+
- bundle -v
|
|
26
|
+
|
|
27
|
+
test_script:
|
|
28
|
+
- bundle exec rake
|
|
29
|
+
|
data/docs/README.adoc
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
= Relaton CLI (relaton-cli): Relaton Command-line Interface
|
|
2
2
|
|
|
3
3
|
image:https://img.shields.io/gem/v/relaton-cli.svg["Gem Version", link="https://rubygems.org/gems/relaton-cli"]
|
|
4
|
-
image:https://img.shields.io/travis/
|
|
5
|
-
image:https://
|
|
4
|
+
image:https://img.shields.io/travis/metanorma/relaton-cli/master.svg["Build Status", link="https://travis-ci.org/metanorma/relaton-cli"]
|
|
5
|
+
image:https://ci.appveyor.com/api/projects/status/fyy87flpig4q5o2u?svg=true["Appveyor Build Status", link="https://ci.appveyor.com/project/ribose/relaton-cli"]
|
|
6
|
+
image:https://codeclimate.com/github/metanorma/relaton-cli/badges/gpa.svg["Code Climate", link="https://codeclimate.com/github/metanorma/relaton-cli"]
|
|
6
7
|
|
|
7
8
|
Documentation in development.
|
|
8
9
|
|
|
9
|
-
Please refer to https://github.com/
|
|
10
|
+
Please refer to https://github.com/metanorma/relaton.
|
|
10
11
|
|
|
11
12
|
== Executables
|
|
12
13
|
|
data/lib/relaton/bibdata.rb
CHANGED
|
@@ -139,10 +139,18 @@ module Relaton
|
|
|
139
139
|
|
|
140
140
|
relaton_collection.items.each do |content|
|
|
141
141
|
name = build_filename(nil, content.docidentifier)
|
|
142
|
+
find_available_bibrxl_file(name, output_dir, content)
|
|
142
143
|
write_to_file(content.send(output_type), output_dir, name)
|
|
143
144
|
end
|
|
144
145
|
end
|
|
145
146
|
|
|
147
|
+
def find_available_bibrxl_file(name, ouputdir, content)
|
|
148
|
+
if options[:extension] == "yaml" || options[:extension] == "yml"
|
|
149
|
+
bib_rxl = Pathname.new([outdir, name].join("/")).sub_ext(".rxl")
|
|
150
|
+
content.bib_rxl = bib_rxl.to_s if File.file?(bib_rxl)
|
|
151
|
+
end
|
|
152
|
+
end
|
|
153
|
+
|
|
146
154
|
def output_type
|
|
147
155
|
output_format = options[:extension] || "rxl"
|
|
148
156
|
(output_format == "rxl" ? "to_xml" : "to_#{output_format}").to_sym
|
data/lib/relaton/cli/version.rb
CHANGED
data/relaton-cli.gemspec
CHANGED
|
@@ -11,7 +11,7 @@ Gem::Specification.new do |spec|
|
|
|
11
11
|
|
|
12
12
|
spec.summary = %q{Relaton Command-line Interface}
|
|
13
13
|
spec.description = %q{Relaton Command-line Interface}
|
|
14
|
-
spec.homepage = "https://github.com/
|
|
14
|
+
spec.homepage = "https://github.com/metanorma/relaton-cli"
|
|
15
15
|
spec.license = "BSD-2-Clause"
|
|
16
16
|
|
|
17
17
|
spec.files = `git ls-files -z`.split("\x0").reject do |f|
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: relaton-cli
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.10
|
|
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-03
|
|
11
|
+
date: 2019-05-03 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: rake
|
|
@@ -168,6 +168,7 @@ files:
|
|
|
168
168
|
- Gemfile
|
|
169
169
|
- LICENSE
|
|
170
170
|
- Rakefile
|
|
171
|
+
- appveyor.yml
|
|
171
172
|
- bin/console
|
|
172
173
|
- bin/rspec
|
|
173
174
|
- bin/setup
|
|
@@ -192,7 +193,7 @@ files:
|
|
|
192
193
|
- templates/_document.liquid
|
|
193
194
|
- templates/_index.liquid
|
|
194
195
|
- templates/index-style.css
|
|
195
|
-
homepage: https://github.com/
|
|
196
|
+
homepage: https://github.com/metanorma/relaton-cli
|
|
196
197
|
licenses:
|
|
197
198
|
- BSD-2-Clause
|
|
198
199
|
metadata: {}
|