Skip to content

Commit

Permalink
JIS flavour: metanorma/metanorma-jis#124; debugging of other files
Browse files Browse the repository at this point in the history
  • Loading branch information
opoudjis committed Dec 7, 2023
1 parent 2b67ca6 commit 7f4d5a3
Show file tree
Hide file tree
Showing 14 changed files with 266 additions and 12 deletions.
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ group :jekyll_plugins do
gem "jekyll-asciidoc"
gem "jekyll-redirect-from"
gem "git"
gem "jekyll-theme-open-project-helpers"
gem "jekyll-theme-open-project-helpers", "~> 2.1.9"
gem "kramdown-parser-gfm"
gem "kramdown-syntax-coderay"
end
Expand Down
4 changes: 4 additions & 0 deletions _layouts/home.html
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,10 @@
description: Messaging, Malware and Mobile Anti-Abuse Working Group
path: /author/m3aawg/
experimental: yes
- name: JIS
description: JIS standards
path: /author/jis/
experimental: yes

corporate:
- name: MPFA
Expand Down
71 changes: 71 additions & 0 deletions _layouts/jis-flavor.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
---
layout: flavor

docs_title: Metanorma for JIS
title: Author JIS documents using Metanorma

ieee_flavor:
implemented_by: metanorma-jis
data_models: metanorma-model-jis
title: JIS
title_org: JIS
title_org_full: Japanese Industrial Standards
markup_name: Metanorma for JIS
experimental: yes
build:
cli_flags: "--type jis -x html"
sample:
repo_url: https://github.com/metanorma/mn-samples-jis
rendered_url: https://metanorma.github.io/mn-samples-jis/
docs_entry_points:
- path: ./topics/markup/
title: General guide

base_url: /author/jis

navigation:
items:
- title: Get started
path: /
- title: Authoring guide
path: /authoring-guide/
items:
- title: Terms used in this guide
path: /authoring-guide/terms/
- title: Development process
path: /authoring-guide/process/
- title: Metanorma AsciiDoc
path: /authoring-guide/metanorma-adoc/
- title: New document
path: /authoring-guide/new-doc-template/
- title: Setting metadata
path: /authoring-guide/metadata/
- title: Sections
path: /authoring-guide/sections/
- title: Block syntax
path: /authoring-guide/block-syntax/
- title: Text formatting
path: /authoring-guide/text-formatting/
- title: Cross references
path: /authoring-guide/cross-references/
- title: Terms and definitions
path: /authoring-guide/terms-definitions/
- title: Bibliographic references
path: /authoring-guide/bibliographic-references/
- title: Samples
path: /sample/
- title: Usage
path: /topics/
items:
- title: Markup
path: /topics/markup/
- title: Output formats
path: /topics/formats/
- title: Reference guides
path: /ref/
items:
- title: Document attributes
path: /ref/document-attributes/
---

{{ content }}
3 changes: 3 additions & 0 deletions _pages/flavors.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,9 @@ at the customization guidelines in link:/builder/[Metanorma builder's documentat
|Chinese Standards
| link:/author/gb/[Metanorma for GB]

|Japanese Industrial Standards
| link:/author/jis/[Metanorma for JIS]

|===


Expand Down
2 changes: 1 addition & 1 deletion author/iho/authoring-guide/block-syntax.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -309,4 +309,4 @@ required AsciiDoc markup.

== Removing auto-numbering from blocks

include::author/iho/topics/markup.adoc[tag=unnumbered-iho]
include::author/topics/document-format/text.adoc[tag=unnumbered]
13 changes: 10 additions & 3 deletions author/iho/topics/markup.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ NOTE: This pattern is derived from IHO S-102.
* 2 and onwards. Document content.
* Annex A onwards. Document content.

tag::preliminary-iho[]
// tag::preliminary-iho[]


== Preface segments
Expand Down Expand Up @@ -104,7 +104,7 @@ Please refer to the full list at the respective committee sites:
* https://iho.int/en/ircc[IRCC]


end::preliminary-iho[]
// end::preliminary-iho[]


== Overview
Expand Down Expand Up @@ -156,7 +156,7 @@ title.

== Definitions clause

tag::definitions[]
// tag::definitions[]

=== General

Expand Down Expand Up @@ -403,6 +403,7 @@ drop with time at constant operating conditions. (Adapted from ISO/IEC
____
====

// end::definitions[]

== Annexes

Expand Down Expand Up @@ -468,6 +469,7 @@ ____

is automatically generated by Metanorma.

// tag::tables-iho[]
=== Tables

Table heads and table subheads are marked up as header cells. They are differentiated by line break:
Expand All @@ -481,6 +483,9 @@ h| Table Row Head +
Table Row Subhead | Value
----

// end::tables-iho[]

// tag::inline-iho[]
== Inline

=== Cross-references
Expand Down Expand Up @@ -511,3 +516,5 @@ Hello.footnote:abc[This is a footnote]
Repetition.footnote:abc[]
----

// end::inline-iho[]
7 changes: 7 additions & 0 deletions author/jis.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
layout: jis-flavor
title: Write JIS documents with Metanorma
---
:page-liquid:

{% include flavor-quickstart-steps.adoc flavor=layout.jis_flavor %}
4 changes: 4 additions & 0 deletions author/jis/ref.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
---
layout: jis-flavor
title: Metanorma-JIS reference guides
---
110 changes: 110 additions & 0 deletions author/jis/ref/document-attributes.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,110 @@
---
layout: jis-flavor
---

= Metanorma JIS document attributes

[[note_general_doc_ref_doc_attrib_jis]]
[NOTE]
====
Document attributes listed below are unique to the processing of JIS documents in Metanorma.
For _common document attributes_, see link:/author/ref/document-attributes/[Document attributes reference] in general Metanorma author's documentation. That page describes attributes that apply to all Metanorma flavors, not just JIS.
For an _introduction to Metanorma AsciiDoc document attributes_ and how Metanorma uses them, see link:/author/topics/document-format/meta-attributes/[the corresponding topic].
====

== Document information

`:doctype`::
Document type. The default is `japanese-industrial-standard`. Supported:
+
--
* `japanese-industrial-standard`
* `technical-report`
* `technical-specification`
* `amendment`
* `expert-commentary`. Personal authors are supported for this document type.
--

`:title-main-ja:`, `:title-main-en:`::
Main title of the document, in Japanese or English

`:title-intro-ja:`, `:title-intro-en:`::
Introduction to title of the document, in Japanese or English

`:title-part-ja:`, `:title-part-en:`::
Part title of the document, in Japanese or English

`:title-amendment-ja:`, `:title-amendment-en:`::
Amendment title of the document, in Japanese or English

`:docnumber:`::
The number for the document.

`:partnumber:`::
The part number for the document.

`:docseries:`::
The series for the document.

`:amendment-number:`::
The amendment number for the document.

`:updates:`::
Identifier of document that this document is an update of.

`:language:` :: The language of the document (support `en`, `ja`) (default: `ja`)

`:copyright-year:`:: The year associated with the copyright for the document.

== Contributor Information

All the following attributes can be specified multilingually, by adding `-ja` or `-en` after each attribute name
(e.g. `:fullname-en:`, `:investigative-organization-ja_2`)

`:fullname_{i}:`::
Name of personal author for this document (for expert commentary)

`:givenname_{i}:`::
Given Name of personal author for this document (for expert commentary)

`:surname_{i}:`::
Surname of personal author for this document (for expert commentary)

`:affiliation_{i}:`::
Name of organization or company for personal author for this document (for expert commentary)

`:address_{i}:`::
Address of personal author for this document (for expert commentary)

`:email_{i}:`::
Email of personal author for this document (for expert commentary)

`:role_{i}:`::
Role of personal author for this document (for expert commentary) (default: `author`)

`:publisher_{i}:`::
Publisher for this document (default: `JIS`)

`:copyright-holder_{i}:`::
Copyright holder for this document (default: `JIS`)

`:investigative-organization_{i}`::
Investigative organization for this document

`:investigative-committee{i}`::
Investigative committee for this document

`:publisher-abbr_{i}:`::
Abbreviation of publisher for this document

`:publisher-logo_{i}:`::
Logo of publisher for this document (image file)

`:subdivision_{i}:``
Subdivision of organization responsible for this document as author and publisher

`:subdivision-abbr_{i}:``
Abbreviation of subdivision of organization responsible for this document as author and publisher

25 changes: 25 additions & 0 deletions author/jis/sample.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
---
layout: jis-flavor
title: "Metanorma JIS samples"
---
:page-liquid:

{% include flavor-sample-summary.html flavor=layout.jis_flavor
markup_link="../authoring/" %}

== Building the sample

Clone the repository:

[source,console]
--
git clone https://github.com/metanorma/mn-samples-jis/
--

Install required gems and build the documents via the provided Makefile from within repository root:

[source,console]
--
bundle
make
--
4 changes: 4 additions & 0 deletions author/jis/topics.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
---
layout: jis-flavor
title: Using Metanorma-JIS
---
17 changes: 17 additions & 0 deletions author/jis/topics/markup.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
layout: jis-flavor
title: Metanorma for JIS markup
---

== Sections

=== Commentary

Commentary clauses are marked up as annexes with a `commentary` option attribute:

[source,asciidoc]
----
[appendix%commentary]
== Commentary
...
----
12 changes: 6 additions & 6 deletions author/topics/document-format/requirements-modspec.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -1295,7 +1295,7 @@ and to the identifier labels of requirements.

[example]
.Setting a document-wide identifier base prefix
====
=====
[source,adoc]
-----
:modspec-identifier-base: http://www.example.com
Expand Down Expand Up @@ -1344,11 +1344,11 @@ h| Included in | Requirement class 1: `/req/class1`
h| Statement | A requirement.
|===
____
====
=====

[example]
.Setting a identifier base prefix at a class instance
====
=====
[source,adoc]
-----
[requirement,type=requirements_class]
Expand Down Expand Up @@ -1388,11 +1388,11 @@ h| Included in | Requirements class 1: `/class1`
h| Statement | A requirement.
|===
____
====
=====

[example]
.Setting identifier base prefixes for document-wide and at the class instance level
====
=====
[source,adoc]
-----
:modspec-identifier-base: http://www.example.com
Expand Down Expand Up @@ -1456,7 +1456,7 @@ h| Included in | Requirements class 2: `/req/class2`
h| Statement | See also Requirement 1: `/req/class1/req1`
|===
____
====
=====

=== Rendering of ModSpec instances

Expand Down
Loading

0 comments on commit 7f4d5a3

Please sign in to comment.