From aabec42a02805fe1294798764b1a73a5b25e1588 Mon Sep 17 00:00:00 2001
From: Andrew Frantz
Date: Mon, 16 Dec 2024 16:47:47 -0500
Subject: [PATCH 1/5] feat: pretty print HTML
---
wdl-doc/src/lib.rs | 4 +-
wdl-doc/src/parameter.rs | 6 +-
wdl-doc/src/struct.rs | 4 +-
wdl-doc/src/task.rs | 4 +-
wdl-doc/src/workflow.rs | 5 +-
.../flag_filter/FlagFilter-struct.html | 17 +++++-
.../data_structures/flag_filter/index.html | 6 +-
.../validate_flag_filter-workflow.html | 39 ++++++++++++-
...e_string_is_12bit_oct_dec_or_hex-task.html | 39 ++++++++++++-
.../read_group/ReadGroup-struct.html | 47 ++++++++++++++-
.../read_group/get_read_groups-task.html | 48 +++++++++++++++-
.../data_structures/read_group/index.html | 6 +-
.../read_group/read_group_to_string-task.html | 39 ++++++++++++-
.../read_group/validate_read_group-task.html | 57 ++++++++++++++++++-
14 files changed, 296 insertions(+), 25 deletions(-)
diff --git a/wdl-doc/src/lib.rs b/wdl-doc/src/lib.rs
index e17e89ce5..bc5dd62eb 100644
--- a/wdl-doc/src/lib.rs
+++ b/wdl-doc/src/lib.rs
@@ -93,8 +93,8 @@ impl Display for Document {
let mut preamble = String::new();
pulldown_cmark::html::push_html(&mut preamble, parser);
- write!(f, "{}", document_name)?;
- write!(f, "{}", version)?;
+ write!(f, "{:?}", document_name)?;
+ write!(f, "{:?}", version)?;
write!(f, "{}", preamble)
}
}
diff --git a/wdl-doc/src/parameter.rs b/wdl-doc/src/parameter.rs
index 78cc6a4bd..d67a5afd6 100644
--- a/wdl-doc/src/parameter.rs
+++ b/wdl-doc/src/parameter.rs
@@ -60,8 +60,8 @@ impl Display for Parameter {
.build()
};
- write!(f, "{}", parameter_name)?;
- write!(f, "{}", parameter_type)?;
- write!(f, "{}", parameter_expr)
+ write!(f, "{:?}", parameter_name)?;
+ write!(f, "{:?}", parameter_type)?;
+ write!(f, "{:?}", parameter_expr)
}
}
diff --git a/wdl-doc/src/struct.rs b/wdl-doc/src/struct.rs
index bd191a4f8..063ec7ac9 100644
--- a/wdl-doc/src/struct.rs
+++ b/wdl-doc/src/struct.rs
@@ -49,7 +49,7 @@ impl Display for Struct {
}
let members = members.build();
- write!(f, "{}", struct_name)?;
- write!(f, "{}", members)
+ write!(f, "{:?}", struct_name)?;
+ write!(f, "{:?}", members)
}
}
diff --git a/wdl-doc/src/task.rs b/wdl-doc/src/task.rs
index b38e0a8e4..f5e956eb9 100644
--- a/wdl-doc/src/task.rs
+++ b/wdl-doc/src/task.rs
@@ -103,7 +103,7 @@ impl Display for Task {
.build(),
);
- write!(f, "{}", task_name)?;
- write!(f, "{}", content.build())
+ write!(f, "{:?}", task_name)?;
+ write!(f, "{:?}", content.build())
}
}
diff --git a/wdl-doc/src/workflow.rs b/wdl-doc/src/workflow.rs
index f4010e260..c71ed2d9e 100644
--- a/wdl-doc/src/workflow.rs
+++ b/wdl-doc/src/workflow.rs
@@ -1,5 +1,6 @@
//! Create HTML documentation for WDL tasks.
+use std::fmt::Debug;
use std::fmt::Display;
use html::content;
@@ -103,7 +104,7 @@ impl Display for Workflow {
.build(),
);
- write!(f, "{}", task_name)?;
- write!(f, "{}", content.build())
+ write!(f, "{:?}", task_name)?;
+ write!(f, "{:?}", content.build())
}
}
diff --git a/wdl-doc/tests/output_docs/data_structures/flag_filter/FlagFilter-struct.html b/wdl-doc/tests/output_docs/data_structures/flag_filter/FlagFilter-struct.html
index bad00e5a2..d2cad40aa 100644
--- a/wdl-doc/tests/output_docs/data_structures/flag_filter/FlagFilter-struct.html
+++ b/wdl-doc/tests/output_docs/data_structures/flag_filter/FlagFilter-struct.html
@@ -1 +1,16 @@
-FlagFilter
- include_if_all: String
- exclude_if_any: String
- include_if_any: String
- exclude_if_all: String
\ No newline at end of file
+
+ FlagFilter
+
+ -
+ include_if_all: String
+
+ -
+ exclude_if_any: String
+
+ -
+ include_if_any: String
+
+ -
+ exclude_if_all: String
+
+
\ No newline at end of file
diff --git a/wdl-doc/tests/output_docs/data_structures/flag_filter/index.html b/wdl-doc/tests/output_docs/data_structures/flag_filter/index.html
index 4c1fd8562..03710860d 100644
--- a/wdl-doc/tests/output_docs/data_structures/flag_filter/index.html
+++ b/wdl-doc/tests/output_docs/data_structures/flag_filter/index.html
@@ -1,4 +1,8 @@
-flag_filter
WDL Version: 1.1
FlagFilter
+
+ flag_filter
+
+ WDL Version: 1.1
+
FlagFilter
A struct to represent the filtering flags used in various samtools
commands.
The order of precedence is include_if_all
, exclude_if_any
, include_if_any
,
and exclude_if_all
.
diff --git a/wdl-doc/tests/output_docs/data_structures/flag_filter/validate_flag_filter-workflow.html b/wdl-doc/tests/output_docs/data_structures/flag_filter/validate_flag_filter-workflow.html
index 21ffcf094..f9047a422 100644
--- a/wdl-doc/tests/output_docs/data_structures/flag_filter/validate_flag_filter-workflow.html
+++ b/wdl-doc/tests/output_docs/data_structures/flag_filter/validate_flag_filter-workflow.html
@@ -1,6 +1,41 @@
-
validate_flag_filter
- Meta:meta {
+
+ validate_flag_filter
+
+ -
+ Meta:
+ meta {
description: "Validates a FlagFilter struct."
outputs: {
check: "Dummy output to enable caching."
}
- }
- Inputs:
flags
Type: FlagFilter
Expr: None
- Outputs:
check
Type: String
Expr: "passed"
\ No newline at end of file
+ }
+
+ -
+ Inputs:
+
+ -
+
+ flags
+
+ Type: FlagFilter
+
+ Expr: None
+
+
+
+
+ -
+ Outputs:
+
+ -
+
+ check
+
+ Type: String
+
+ Expr: "passed"
+
+
+
+
+
\ No newline at end of file
diff --git a/wdl-doc/tests/output_docs/data_structures/flag_filter/validate_string_is_12bit_oct_dec_or_hex-task.html b/wdl-doc/tests/output_docs/data_structures/flag_filter/validate_string_is_12bit_oct_dec_or_hex-task.html
index bb350a18c..4f05578ec 100644
--- a/wdl-doc/tests/output_docs/data_structures/flag_filter/validate_string_is_12bit_oct_dec_or_hex-task.html
+++ b/wdl-doc/tests/output_docs/data_structures/flag_filter/validate_string_is_12bit_oct_dec_or_hex-task.html
@@ -1,7 +1,42 @@
-validate_string_is_12bit_oct_dec_or_hex
- Meta:meta {
+
+ validate_string_is_12bit_oct_dec_or_hex
+
+ -
+ Meta:
+ meta {
description: "Validates that a string is a octal, decimal, or hexadecimal number and less than 2^12."
help: "Hexadecimal numbers must be prefixed with '0x' and only contain the characters [0-9A-F] to be valid (i.e. [a-f] is not allowed). Octal number must start with '0' and only contain the characters [0-7] to be valid. And decimal numbers must start with a digit between 1-9 and only contain the characters [0-9] to be valid."
outputs: {
check: "Dummy output to enable caching."
}
- }
- Inputs:
number
Type: String
Expr: None
- Outputs:
check
Type: String
Expr: "passed"
\ No newline at end of file
+ }
+
+ -
+ Inputs:
+
+ -
+
+ number
+
+ Type: String
+
+ Expr: None
+
+
+
+
+ -
+ Outputs:
+
+ -
+
+ check
+
+ Type: String
+
+ Expr: "passed"
+
+
+
+
+
\ No newline at end of file
diff --git a/wdl-doc/tests/output_docs/data_structures/read_group/ReadGroup-struct.html b/wdl-doc/tests/output_docs/data_structures/read_group/ReadGroup-struct.html
index d15f4b441..b359bdb31 100644
--- a/wdl-doc/tests/output_docs/data_structures/read_group/ReadGroup-struct.html
+++ b/wdl-doc/tests/output_docs/data_structures/read_group/ReadGroup-struct.html
@@ -1 +1,46 @@
-ReadGroup
- ID: String
- BC: String?
- CN: String?
- DS: String?
- DT: String?
- FO: String?
- KS: String?
- LB: String?
- PG: String?
- PI: Int?
- PL: String?
- PM: String?
- PU: String?
- SM: String?
\ No newline at end of file
+
+ ReadGroup
+
+ -
+ ID: String
+
+ -
+ BC: String?
+
+ -
+ CN: String?
+
+ -
+ DS: String?
+
+ -
+ DT: String?
+
+ -
+ FO: String?
+
+ -
+ KS: String?
+
+ -
+ LB: String?
+
+ -
+ PG: String?
+
+ -
+ PI: Int?
+
+ -
+ PL: String?
+
+ -
+ PM: String?
+
+ -
+ PU: String?
+
+ -
+ SM: String?
+
+
\ No newline at end of file
diff --git a/wdl-doc/tests/output_docs/data_structures/read_group/get_read_groups-task.html b/wdl-doc/tests/output_docs/data_structures/read_group/get_read_groups-task.html
index b04938e49..ca3a7f24a 100644
--- a/wdl-doc/tests/output_docs/data_structures/read_group/get_read_groups-task.html
+++ b/wdl-doc/tests/output_docs/data_structures/read_group/get_read_groups-task.html
@@ -1,6 +1,50 @@
-get_read_groups
- Meta:meta {
+
+ get_read_groups
+
+ -
+ Meta:
+ meta {
description: "Gets read group information from a BAM file and writes it out as JSON which is converted to a WDL struct."
outputs: {
read_groups: "An array of ReadGroup structs containing read group information."
}
- }
- Inputs:
bam
Type: File
Expr: None
modify_disk_size_gb
Type: Int
Expr: 0
- Outputs:
\ No newline at end of file
+ }
+
+ -
+ Inputs:
+
+ -
+
+ bam
+
+ Type: File
+
+ Expr: None
+
+
+ -
+
+ modify_disk_size_gb
+
+ Type: Int
+
+ Expr: 0
+
+
+
+
+ -
+ Outputs:
+
+
+
\ No newline at end of file
diff --git a/wdl-doc/tests/output_docs/data_structures/read_group/index.html b/wdl-doc/tests/output_docs/data_structures/read_group/index.html
index 854680ed8..fcc4a7a00 100644
--- a/wdl-doc/tests/output_docs/data_structures/read_group/index.html
+++ b/wdl-doc/tests/output_docs/data_structures/read_group/index.html
@@ -1,4 +1,8 @@
-read_group
WDL Version: 1.1
Read groups are defined in the SAM spec
+
+ read_group
+
+ WDL Version: 1.1
+
Read groups are defined in the SAM spec
- ID: Read group identifier. Each Read Group must have a unique ID.
The value of ID is used in the RG tags of alignment records.
diff --git a/wdl-doc/tests/output_docs/data_structures/read_group/read_group_to_string-task.html b/wdl-doc/tests/output_docs/data_structures/read_group/read_group_to_string-task.html
index 55aaf2a64..011922831 100644
--- a/wdl-doc/tests/output_docs/data_structures/read_group/read_group_to_string-task.html
+++ b/wdl-doc/tests/output_docs/data_structures/read_group/read_group_to_string-task.html
@@ -1,6 +1,41 @@
-read_group_to_string
- Meta:meta {
+
+ read_group_to_string
+
+ -
+ Meta:
+ meta {
description: "Stringifies a ReadGroup struct"
outputs: {
stringified_read_group: "Input ReadGroup as a string"
}
- }
- Inputs:
read_group
Type: ReadGroup
Expr: None
- Outputs:
\ No newline at end of file
+ }
+
+ -
+ Inputs:
+
+ -
+
+ read_group
+
+ Type: ReadGroup
+
+ Expr: None
+
+
+
+
+ -
+ Outputs:
+
+
+
\ No newline at end of file
diff --git a/wdl-doc/tests/output_docs/data_structures/read_group/validate_read_group-task.html b/wdl-doc/tests/output_docs/data_structures/read_group/validate_read_group-task.html
index 6322bc053..eda77af76 100644
--- a/wdl-doc/tests/output_docs/data_structures/read_group/validate_read_group-task.html
+++ b/wdl-doc/tests/output_docs/data_structures/read_group/validate_read_group-task.html
@@ -1,6 +1,59 @@
-validate_read_group
- Meta:meta {
+
+ validate_read_group
+
+ -
+ Meta:
+ meta {
description: "Validate a ReadGroup struct's fields are defined"
outputs: {
check: "Dummy output to indicate success and enable call-caching"
}
- }
- Inputs:
read_group
Type: ReadGroup
Expr: None
required_fields
Type: Array[String]
Expr: []
restrictive
Type: Boolean
Expr: true
- Outputs:
check
Type: String
Expr: "passed"
\ No newline at end of file
+ }
+
+ -
+ Inputs:
+
+ -
+
+ read_group
+
+ Type: ReadGroup
+
+ Expr: None
+
+
+ -
+
+ required_fields
+
+ Type: Array[String]
+
+ Expr: []
+
+
+ -
+
+ restrictive
+
+ Type: Boolean
+
+ Expr: true
+
+
+
+
+ -
+ Outputs:
+
+ -
+
+ check
+
+ Type: String
+
+ Expr: "passed"
+
+
+
+
+
\ No newline at end of file
From dffba376671e5cf755e9a74694292f38a6a4bfa4 Mon Sep 17 00:00:00 2001
From: Andrew Frantz
Date: Mon, 16 Dec 2024 16:51:54 -0500
Subject: [PATCH 2/5] Update CHANGELOG.md
---
wdl-doc/CHANGELOG.md | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/wdl-doc/CHANGELOG.md b/wdl-doc/CHANGELOG.md
index 622f46df1..183d3c048 100644
--- a/wdl-doc/CHANGELOG.md
+++ b/wdl-doc/CHANGELOG.md
@@ -10,3 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Added
* `wdl-doc` crate for documenting WDL codebases ([#258](https://github.com/stjude-rust-labs/wdl/pull/248)).
+
+### Changed
+
+* Pretty print HTML ([#270](https://github.com/stjude-rust-labs/wdl/pull/270)).
From 18c4c126fef67ba702649fd64f23b924f6f241c1 Mon Sep 17 00:00:00 2001
From: Andrew Frantz
Date: Mon, 16 Dec 2024 18:15:12 -0500
Subject: [PATCH 3/5] Update wdl-doc/CHANGELOG.md
Co-authored-by: Clay McLeod <3411613+claymcleod@users.noreply.github.com>
---
wdl-doc/CHANGELOG.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/wdl-doc/CHANGELOG.md b/wdl-doc/CHANGELOG.md
index 183d3c048..add51058a 100644
--- a/wdl-doc/CHANGELOG.md
+++ b/wdl-doc/CHANGELOG.md
@@ -13,4 +13,4 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Changed
-* Pretty print HTML ([#270](https://github.com/stjude-rust-labs/wdl/pull/270)).
+* Updates HTML generation to be pretty printed ([#270](https://github.com/stjude-rust-labs/wdl/pull/270)).
From 1f47498789f9ee7a17ec9d5b7b6c4205cfd18103 Mon Sep 17 00:00:00 2001
From: Andrew Frantz
Date: Mon, 16 Dec 2024 18:18:00 -0500
Subject: [PATCH 4/5] revise: add newline after Debug print of html
---
wdl-doc/src/lib.rs | 4 +--
wdl-doc/src/parameter.rs | 6 ++--
wdl-doc/src/struct.rs | 4 +--
wdl-doc/src/task.rs | 4 +--
wdl-doc/src/workflow.rs | 4 +--
.../flag_filter/FlagFilter-struct.html | 5 +--
.../data_structures/flag_filter/index.html | 6 ++--
.../validate_flag_filter-workflow.html | 19 +++++++----
...e_string_is_12bit_oct_dec_or_hex-task.html | 19 +++++++----
.../read_group/ReadGroup-struct.html | 5 +--
.../read_group/get_read_groups-task.html | 26 ++++++++++-----
.../data_structures/read_group/index.html | 6 ++--
.../read_group/read_group_to_string-task.html | 19 +++++++----
.../read_group/validate_read_group-task.html | 33 +++++++++++++------
14 files changed, 105 insertions(+), 55 deletions(-)
diff --git a/wdl-doc/src/lib.rs b/wdl-doc/src/lib.rs
index bc5dd62eb..b98ca998d 100644
--- a/wdl-doc/src/lib.rs
+++ b/wdl-doc/src/lib.rs
@@ -93,8 +93,8 @@ impl Display for Document {
let mut preamble = String::new();
pulldown_cmark::html::push_html(&mut preamble, parser);
- write!(f, "{:?}", document_name)?;
- write!(f, "{:?}", version)?;
+ write!(f, "{:?}\n", document_name)?;
+ write!(f, "{:?}\n", version)?;
write!(f, "{}", preamble)
}
}
diff --git a/wdl-doc/src/parameter.rs b/wdl-doc/src/parameter.rs
index d67a5afd6..70f65aff1 100644
--- a/wdl-doc/src/parameter.rs
+++ b/wdl-doc/src/parameter.rs
@@ -60,8 +60,8 @@ impl Display for Parameter {
.build()
};
- write!(f, "{:?}", parameter_name)?;
- write!(f, "{:?}", parameter_type)?;
- write!(f, "{:?}", parameter_expr)
+ write!(f, "{:?}\n", parameter_name)?;
+ write!(f, "{:?}\n", parameter_type)?;
+ write!(f, "{:?}\n", parameter_expr)
}
}
diff --git a/wdl-doc/src/struct.rs b/wdl-doc/src/struct.rs
index 063ec7ac9..fe848bd9a 100644
--- a/wdl-doc/src/struct.rs
+++ b/wdl-doc/src/struct.rs
@@ -49,7 +49,7 @@ impl Display for Struct {
}
let members = members.build();
- write!(f, "{:?}", struct_name)?;
- write!(f, "{:?}", members)
+ write!(f, "{:?}\n", struct_name)?;
+ write!(f, "{:?}\n", members)
}
}
diff --git a/wdl-doc/src/task.rs b/wdl-doc/src/task.rs
index f5e956eb9..6b50ae1d4 100644
--- a/wdl-doc/src/task.rs
+++ b/wdl-doc/src/task.rs
@@ -103,7 +103,7 @@ impl Display for Task {
.build(),
);
- write!(f, "{:?}", task_name)?;
- write!(f, "{:?}", content.build())
+ write!(f, "{:?}\n", task_name)?;
+ write!(f, "{:?}\n", content.build())
}
}
diff --git a/wdl-doc/src/workflow.rs b/wdl-doc/src/workflow.rs
index c71ed2d9e..dbb3a940c 100644
--- a/wdl-doc/src/workflow.rs
+++ b/wdl-doc/src/workflow.rs
@@ -104,7 +104,7 @@ impl Display for Workflow {
.build(),
);
- write!(f, "{:?}", task_name)?;
- write!(f, "{:?}", content.build())
+ write!(f, "{:?}\n", task_name)?;
+ write!(f, "{:?}\n", content.build())
}
}
diff --git a/wdl-doc/tests/output_docs/data_structures/flag_filter/FlagFilter-struct.html b/wdl-doc/tests/output_docs/data_structures/flag_filter/FlagFilter-struct.html
index d2cad40aa..97a72acba 100644
--- a/wdl-doc/tests/output_docs/data_structures/flag_filter/FlagFilter-struct.html
+++ b/wdl-doc/tests/output_docs/data_structures/flag_filter/FlagFilter-struct.html
@@ -1,6 +1,7 @@
FlagFilter
-
+
+
-
include_if_all: String
@@ -13,4 +14,4 @@
-
exclude_if_all: String
-
\ No newline at end of file
+
diff --git a/wdl-doc/tests/output_docs/data_structures/flag_filter/index.html b/wdl-doc/tests/output_docs/data_structures/flag_filter/index.html
index 03710860d..edcd2576a 100644
--- a/wdl-doc/tests/output_docs/data_structures/flag_filter/index.html
+++ b/wdl-doc/tests/output_docs/data_structures/flag_filter/index.html
@@ -1,8 +1,10 @@
flag_filter
-
+
+
WDL Version: 1.1
-
FlagFilter
+
+FlagFilter
A struct to represent the filtering flags used in various samtools
commands.
The order of precedence is include_if_all
, exclude_if_any
, include_if_any
,
and exclude_if_all
.
diff --git a/wdl-doc/tests/output_docs/data_structures/flag_filter/validate_flag_filter-workflow.html b/wdl-doc/tests/output_docs/data_structures/flag_filter/validate_flag_filter-workflow.html
index f9047a422..a5c5a80b0 100644
--- a/wdl-doc/tests/output_docs/data_structures/flag_filter/validate_flag_filter-workflow.html
+++ b/wdl-doc/tests/output_docs/data_structures/flag_filter/validate_flag_filter-workflow.html
@@ -1,6 +1,7 @@
validate_flag_filter
-
+
+
-
Meta:
meta {
@@ -16,11 +17,14 @@
-
flags
-
+
+
Type: FlagFilter
-
+
+
Expr: None
+
@@ -30,12 +34,15 @@
-
check
-
+
+
Type: String
-
+
+
Expr: "passed"
+
-
\ No newline at end of file
+
diff --git a/wdl-doc/tests/output_docs/data_structures/flag_filter/validate_string_is_12bit_oct_dec_or_hex-task.html b/wdl-doc/tests/output_docs/data_structures/flag_filter/validate_string_is_12bit_oct_dec_or_hex-task.html
index 4f05578ec..b5cc51167 100644
--- a/wdl-doc/tests/output_docs/data_structures/flag_filter/validate_string_is_12bit_oct_dec_or_hex-task.html
+++ b/wdl-doc/tests/output_docs/data_structures/flag_filter/validate_string_is_12bit_oct_dec_or_hex-task.html
@@ -1,6 +1,7 @@
validate_string_is_12bit_oct_dec_or_hex
-
+
+
-
Meta:
meta {
@@ -17,11 +18,14 @@
-
number
-
+
+
Type: String
-
+
+
Expr: None
+
@@ -31,12 +35,15 @@
-
check
-
+
+
Type: String
-
+
+
Expr: "passed"
+
-
\ No newline at end of file
+
diff --git a/wdl-doc/tests/output_docs/data_structures/read_group/ReadGroup-struct.html b/wdl-doc/tests/output_docs/data_structures/read_group/ReadGroup-struct.html
index b359bdb31..c95360a31 100644
--- a/wdl-doc/tests/output_docs/data_structures/read_group/ReadGroup-struct.html
+++ b/wdl-doc/tests/output_docs/data_structures/read_group/ReadGroup-struct.html
@@ -1,6 +1,7 @@
ReadGroup
-
+
+
-
ID: String
@@ -43,4 +44,4 @@
-
SM: String?
-
\ No newline at end of file
+
diff --git a/wdl-doc/tests/output_docs/data_structures/read_group/get_read_groups-task.html b/wdl-doc/tests/output_docs/data_structures/read_group/get_read_groups-task.html
index ca3a7f24a..d716b5361 100644
--- a/wdl-doc/tests/output_docs/data_structures/read_group/get_read_groups-task.html
+++ b/wdl-doc/tests/output_docs/data_structures/read_group/get_read_groups-task.html
@@ -1,6 +1,7 @@
get_read_groups
-
-
\ No newline at end of file
+
diff --git a/wdl-doc/tests/output_docs/data_structures/read_group/index.html b/wdl-doc/tests/output_docs/data_structures/read_group/index.html
index fcc4a7a00..34411dc7e 100644
--- a/wdl-doc/tests/output_docs/data_structures/read_group/index.html
+++ b/wdl-doc/tests/output_docs/data_structures/read_group/index.html
@@ -1,8 +1,10 @@
read_group
-
+
+
WDL Version: 1.1
-
Read groups are defined in the SAM spec
+
+Read groups are defined in the SAM spec
- ID: Read group identifier. Each Read Group must have a unique ID.
The value of ID is used in the RG tags of alignment records.
diff --git a/wdl-doc/tests/output_docs/data_structures/read_group/read_group_to_string-task.html b/wdl-doc/tests/output_docs/data_structures/read_group/read_group_to_string-task.html
index 011922831..ea15e7efc 100644
--- a/wdl-doc/tests/output_docs/data_structures/read_group/read_group_to_string-task.html
+++ b/wdl-doc/tests/output_docs/data_structures/read_group/read_group_to_string-task.html
@@ -1,6 +1,7 @@
read_group_to_string
-
-
\ No newline at end of file
+
diff --git a/wdl-doc/tests/output_docs/data_structures/read_group/validate_read_group-task.html b/wdl-doc/tests/output_docs/data_structures/read_group/validate_read_group-task.html
index eda77af76..4b0c50291 100644
--- a/wdl-doc/tests/output_docs/data_structures/read_group/validate_read_group-task.html
+++ b/wdl-doc/tests/output_docs/data_structures/read_group/validate_read_group-task.html
@@ -1,6 +1,7 @@
validate_read_group
-
+
+
-
Meta:
meta {
@@ -16,29 +17,38 @@
-
read_group
-
+
+
Type: ReadGroup
-
+
+
Expr: None
+
-
required_fields
-
+
+
Type: Array[String]
-
+
+
Expr: []
+
-
restrictive
-
+
+
Type: Boolean
-
+
+
Expr: true
+
@@ -48,12 +58,15 @@
-
check
-
+
+
Type: String
-
+
+
Expr: "passed"
+
-
\ No newline at end of file
+
From a27e0b2fe0a8c9a0b7ada909487a9ac7c89cb7f7 Mon Sep 17 00:00:00 2001
From: Andrew Frantz
Date: Tue, 17 Dec 2024 08:40:05 -0500
Subject: [PATCH 5/5] chore: clippy
---
wdl-doc/src/lib.rs | 4 ++--
wdl-doc/src/parameter.rs | 6 +++---
wdl-doc/src/struct.rs | 4 ++--
wdl-doc/src/task.rs | 4 ++--
wdl-doc/src/workflow.rs | 4 ++--
5 files changed, 11 insertions(+), 11 deletions(-)
diff --git a/wdl-doc/src/lib.rs b/wdl-doc/src/lib.rs
index b98ca998d..a8448952c 100644
--- a/wdl-doc/src/lib.rs
+++ b/wdl-doc/src/lib.rs
@@ -93,8 +93,8 @@ impl Display for Document {
let mut preamble = String::new();
pulldown_cmark::html::push_html(&mut preamble, parser);
- write!(f, "{:?}\n", document_name)?;
- write!(f, "{:?}\n", version)?;
+ writeln!(f, "{:?}", document_name)?;
+ writeln!(f, "{:?}", version)?;
write!(f, "{}", preamble)
}
}
diff --git a/wdl-doc/src/parameter.rs b/wdl-doc/src/parameter.rs
index 70f65aff1..c0bcead55 100644
--- a/wdl-doc/src/parameter.rs
+++ b/wdl-doc/src/parameter.rs
@@ -60,8 +60,8 @@ impl Display for Parameter {
.build()
};
- write!(f, "{:?}\n", parameter_name)?;
- write!(f, "{:?}\n", parameter_type)?;
- write!(f, "{:?}\n", parameter_expr)
+ writeln!(f, "{:?}", parameter_name)?;
+ writeln!(f, "{:?}", parameter_type)?;
+ writeln!(f, "{:?}", parameter_expr)
}
}
diff --git a/wdl-doc/src/struct.rs b/wdl-doc/src/struct.rs
index fe848bd9a..0683701e1 100644
--- a/wdl-doc/src/struct.rs
+++ b/wdl-doc/src/struct.rs
@@ -49,7 +49,7 @@ impl Display for Struct {
}
let members = members.build();
- write!(f, "{:?}\n", struct_name)?;
- write!(f, "{:?}\n", members)
+ writeln!(f, "{:?}", struct_name)?;
+ writeln!(f, "{:?}", members)
}
}
diff --git a/wdl-doc/src/task.rs b/wdl-doc/src/task.rs
index 6b50ae1d4..4a7f87696 100644
--- a/wdl-doc/src/task.rs
+++ b/wdl-doc/src/task.rs
@@ -103,7 +103,7 @@ impl Display for Task {
.build(),
);
- write!(f, "{:?}\n", task_name)?;
- write!(f, "{:?}\n", content.build())
+ writeln!(f, "{:?}", task_name)?;
+ writeln!(f, "{:?}", content.build())
}
}
diff --git a/wdl-doc/src/workflow.rs b/wdl-doc/src/workflow.rs
index dbb3a940c..8828c5a72 100644
--- a/wdl-doc/src/workflow.rs
+++ b/wdl-doc/src/workflow.rs
@@ -104,7 +104,7 @@ impl Display for Workflow {
.build(),
);
- write!(f, "{:?}\n", task_name)?;
- write!(f, "{:?}\n", content.build())
+ writeln!(f, "{:?}", task_name)?;
+ writeln!(f, "{:?}", content.build())
}
}