metanorma-nist 1.2.6 → 1.2.7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 87d9c7be14355912b02f7f0dc22c25c4fc232911a18c6d5c41b95df158592314
4
- data.tar.gz: dcc54050671bbb3265517009cee8bc5797c952473bd457cd72e0bc26ded1531c
3
+ metadata.gz: cb6a46ab09b565bb49b1d6071a774b367e453438176f5bffb29a094df0535256
4
+ data.tar.gz: 65711ba670c7b3874dc25e9aae6d9bae9617611a066d096dcdc5d91260cd435f
5
5
  SHA512:
6
- metadata.gz: c23571ad0654a2470b91f7d4704debdd577df11567d37facff8b22b17a76d38c4fe4ef7e61cfd69b01810c9bc8d5c99611d9f922fe63234c74906e88dd569484
7
- data.tar.gz: 25a3e238f7c4ebc8003b4276e988388b0d6df536d5867058bc531c04e6f0bed37a54a466f73387caba8cf7d739b9a34eaa4b396da9e0fbdd999609532aa74a34
6
+ metadata.gz: cebd778e6f74ca1f1a07cef424c467b509b6ef9ff206e2f9c0125e99ec4990d350c5327ed9f21b74edcd8702455801f7e9a5467968514fff4ff7e404341c5088
7
+ data.tar.gz: 8b3a2f422fe2e0dbe75ac806d8095cd99d38c72ac8e95d852e0e188f2cdfa500b8218eb45cf5046ee2eb8cf1bcd02ac427829350d862afe5a1d615e4c057c8cb
@@ -4,7 +4,8 @@ name: rake
4
4
 
5
5
  on:
6
6
  push:
7
- branches: [ master ]
7
+ branches: [ master, main ]
8
+ tags: [ v* ]
8
9
  pull_request:
9
10
 
10
11
  jobs:
@@ -31,14 +32,32 @@ jobs:
31
32
  steps:
32
33
  - uses: actions/checkout@master
33
34
 
34
- - name: Use Ruby
35
- uses: ruby/setup-ruby@v1
35
+ - uses: ruby/setup-ruby@v1
36
36
  with:
37
37
  ruby-version: ${{ matrix.ruby }}
38
- bundler-cache: true
39
38
 
40
- - name: Update gems
41
- run: bundle install --jobs 4 --retry 3
39
+ - uses: actions/cache@v1
40
+ with:
41
+ path: vendor/bundle
42
+ key: bundle-${{ matrix.os }}-${{ matrix.ruby }}-${{ hashFiles('**/*.gemspec') }}
43
+ restore-keys: bundle-${{ matrix.os }}-${{ matrix.ruby }}
44
+
45
+ - run: bundle config set path 'vendor/bundle'
46
+
47
+ - run: bundle install --jobs 4 --retry 3
42
48
 
43
- - name: Run specs
44
- run: bundle exec rake
49
+ - run: bundle exec rake
50
+
51
+ notify:
52
+ name: Trigger notify workflow
53
+ needs: rake
54
+ runs-on: ubuntu-latest
55
+ steps:
56
+ - name: Trigger notify workflow
57
+ uses: Sibz/github-status-action@v1
58
+ with:
59
+ authToken: ${{ secrets.GITHUB_TOKEN }}
60
+ context: 'tests-passed-successfully'
61
+ description: 'Tests passed successfully'
62
+ state: 'success'
63
+ sha: ${{ github.event.pull_request.head.sha || github.sha }}
@@ -0,0 +1,36 @@
1
+ name: release
2
+
3
+ on:
4
+ push:
5
+ tags:
6
+ - '*'
7
+
8
+ jobs:
9
+ release:
10
+ runs-on: ubuntu-latest
11
+ steps:
12
+ - uses: actions/checkout@v1
13
+
14
+ - uses: ruby/setup-ruby@v1
15
+ with:
16
+ ruby-version: '2.6'
17
+
18
+ - uses: actions/cache@v1
19
+ with:
20
+ path: vendor/bundle
21
+ restore-keys: bundle-ubuntu-latest-2.6
22
+
23
+ - run: bundle exec rake
24
+
25
+ - name: publish
26
+ env:
27
+ GITHUB_PACKAGES_TOKEN: ${{ secrets.METANORMA_CI_PAT_TOKEN }}
28
+ run: |
29
+ cat << 'EOF' > ~/.gem/credentials
30
+ ---
31
+ :github: Bearer ${GITHUB_PACKAGES_TOKEN}
32
+ EOF
33
+ chmod 0600 ~/.gem/credentials
34
+ gem install gem-release
35
+ gem release --key github --host https://rubygems.pkg.github.com/metanorma
36
+
@@ -1,16 +1,15 @@
1
1
  = metanorma-nist: Metanorma processor for the NIST SP 800 document classes
2
2
 
3
3
  image:https://img.shields.io/gem/v/metanorma-nist.svg["Gem Version", link="https://rubygems.org/gems/metanorma-nist"]
4
- image:https://github.com/metanorma/metanorma-nist/workflows/macos/badge.svg["Build Status (macOS)", link="https://github.com/metanorma/metanorma-nist/actions?workflow=macos"]
5
- image:https://github.com/metanorma/metanorma-nist/workflows/ubuntu/badge.svg["Build Status (ubuntu)", link="https://github.com/metanorma/metanorma-nist/actions?workflow=ubuntu"]
6
- image:https://github.com/metanorma/metanorma-nist/workflows/windows/badge.svg["Build Status (Windows)", link="https://github.com/metanorma/metanorma-nist/actions?workflow=windows"]
4
+ image:https://github.com/metanorma/metanorma-nist/workflows/rake/badge.svg["Build Status", link="https://github.com/metanorma/metanorma-nist/actions?workflow=rake"]
7
5
  image:https://codeclimate.com/github/metanorma/metanorma-nist/badges/gpa.svg["Code Climate", link="https://codeclimate.com/github/metanorma/metanorma-nist"]
8
6
  image:https://img.shields.io/github/issues-pr-raw/metanorma/metanorma-nist.svg["Pull Requests", link="https://github.com/metanorma/metanorma-nist/pulls"]
9
7
  image:https://img.shields.io/github/commits-since/metanorma/metanorma-nist/latest.svg["Commits since latest",link="https://github.com/metanorma/metanorma-nist/releases"]
10
8
 
11
9
  == Functionality
12
10
 
13
- This gem processes Metanorma documents into the NIST document class.
11
+ This gem processes https://www.metanorma.com[Metanorma documents] following
12
+ a template for generating NIST standards.
14
13
 
15
14
  It provides the following functions:
16
15
 
@@ -24,6 +24,14 @@
24
24
  <start>
25
25
  <ref name="standard-document"/>
26
26
  </start>
27
+ <define name="doctype">
28
+ <element name="doctype">
29
+ <optional>
30
+ <attribute name="abbreviation"/>
31
+ </optional>
32
+ <ref name="DocumentType"/>
33
+ </element>
34
+ </define>
27
35
  <define name="hyperlink">
28
36
  <element name="link">
29
37
  <attribute name="target">
@@ -141,6 +149,11 @@
141
149
  <data type="boolean"/>
142
150
  </attribute>
143
151
  </optional>
152
+ <optional>
153
+ <attribute name="key">
154
+ <data type="boolean"/>
155
+ </attribute>
156
+ </optional>
144
157
  <oneOrMore>
145
158
  <ref name="dt"/>
146
159
  <ref name="dd"/>
@@ -46,6 +46,14 @@ module IsoDoc
46
46
  HEAD
47
47
  end
48
48
 
49
+ def html_head()
50
+ super + <<~HEAD.freeze
51
+ <link rel="stylesheet" href="https://pages.nist.gov/nist-header-footer/css/nist-combined.css">
52
+ <script src="https://pages.nist.gov/nist-header-footer/js/jquery-1.9.0.min.js" type="text/javascript" defer="defer"></script>
53
+ <script src="https://pages.nist.gov/nist-header-footer/js/nist-header-footer.js" type="text/javascript" defer="defer"></script>
54
+ HEAD
55
+ end
56
+
49
57
  def toclevel
50
58
  ret = toclevel_classes.map do |l|
51
59
  "#{l}:not(:empty):not(.TermNum):not(.noTOC):not(.AbstractTitle):"\
@@ -1,5 +1,5 @@
1
1
  module Metanorma
2
2
  module NIST
3
- VERSION = "1.2.6"
3
+ VERSION = "1.2.7"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: metanorma-nist
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.6
4
+ version: 1.2.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-10-25 00:00:00.000000000 Z
11
+ date: 2020-11-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: htmlentities
@@ -258,6 +258,7 @@ extensions: []
258
258
  extra_rdoc_files: []
259
259
  files:
260
260
  - ".github/workflows/rake.yml"
261
+ - ".github/workflows/release.yml"
261
262
  - ".hound.yml"
262
263
  - ".rubocop.yml"
263
264
  - CODE_OF_CONDUCT.md