Skip to content

Commit a903996

Browse files
committed
Add the module type attribute; Issue #18
See also redhat-documentation/modular-docs#151
1 parent 2b1386f commit a903996

9 files changed

+54
-0
lines changed

data/generated/con_a-title-that-tests-a-concept.adoc

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,14 @@ Base the file name and the ID on the module title. For example:
55
* Title: = My concept module A
66
////
77

8+
////
9+
Indicate the module type in one of the following
10+
ways:
11+
Add the prefix con- or con_ to the file name.
12+
Add the following attribute before the module ID:
13+
////
14+
:_module-type: CONCEPT
15+
816
////
917
The ID is an anchor that links to the module. Avoid changing it after the module has been published to ensure existing links are not broken.
1018

data/generated/minimal-concept.adoc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
:_module-type: CONCEPT
2+
13
[id="minimal-concept_{context}"]
24
= Minimal concept
35

data/generated/minimal-procedure.adoc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
:_module-type: PROCEDURE
2+
13
[id="minimal-procedure_{context}"]
24
= Minimal procedure
35

data/generated/minimal-reference.adoc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
:_module-type: REFERENCE
2+
13
[id="minimal-reference_{context}"]
24
= Minimal reference
35

data/generated/proc_testing-a-procedure.adoc

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,14 @@ The ID is an anchor that links to the module. Avoid changing it after the module
99
The `context` attribute enables module reuse. Every module ID includes {context}, which ensures that the module has a unique ID even if it is reused multiple times in a guide.
1010
////
1111

12+
////
13+
Indicate the module type in one of the following
14+
ways:
15+
Add the prefix proc- or proc_ to the file name.
16+
Add the following attribute before the module ID:
17+
////
18+
:_module-type: PROCEDURE
19+
1220
[id="proc_testing-a-procedure_{context}"]
1321
= Testing a procedure
1422
////

data/generated/ref_the-lines-in-a-reference-module.adoc

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,14 @@ The ID is an anchor that links to the module. Avoid changing it after the module
99
The `context` attribute enables module reuse. Every module ID includes {context}, which ensures that the module has a unique ID even if it is reused multiple times in a guide.
1010
////
1111

12+
////
13+
Indicate the module type in one of the following
14+
ways:
15+
Add the prefix ref- or ref_ to the file name.
16+
Add the following attribute before the module ID:
17+
////
18+
:_module-type: REFERENCE
19+
1220
[id="ref_the-lines-in-a-reference-module_{context}"]
1321
= The lines in a reference module
1422
////

data/templates/concept.adoc

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,14 @@ Base the file name and the ID on the module title. For example:
55
* Title: = My concept module A
66
////
77

8+
////
9+
Indicate the module type in one of the following
10+
ways:
11+
Add the prefix con- or con_ to the file name.
12+
Add the following attribute before the module ID:
13+
////
14+
:_module-type: CONCEPT
15+
816
////
917
The ID is an anchor that links to the module. Avoid changing it after the module has been published to ensure existing links are not broken.
1018

data/templates/procedure.adoc

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,14 @@ The ID is an anchor that links to the module. Avoid changing it after the module
99
The `context` attribute enables module reuse. Every module ID includes {context}, which ensures that the module has a unique ID even if it is reused multiple times in a guide.
1010
////
1111

12+
////
13+
Indicate the module type in one of the following
14+
ways:
15+
Add the prefix proc- or proc_ to the file name.
16+
Add the following attribute before the module ID:
17+
////
18+
:_module-type: PROCEDURE
19+
1220
[id="{{module_id}}_{context}"]
1321
= {{module_title}}
1422
////

data/templates/reference.adoc

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,14 @@ The ID is an anchor that links to the module. Avoid changing it after the module
99
The `context` attribute enables module reuse. Every module ID includes {context}, which ensures that the module has a unique ID even if it is reused multiple times in a guide.
1010
////
1111

12+
////
13+
Indicate the module type in one of the following
14+
ways:
15+
Add the prefix ref- or ref_ to the file name.
16+
Add the following attribute before the module ID:
17+
////
18+
:_module-type: REFERENCE
19+
1220
[id="{{module_id}}_{context}"]
1321
= {{module_title}}
1422
////

0 commit comments

Comments
 (0)