| 1 | pub mod align_row;
|
| 2 | pub mod cli;
|
| 3 | pub mod config;
|
| 4 | pub mod datetime;
|
| 5 | pub mod dsl;
|
| 6 | pub mod editor_assist;
|
| 7 | pub mod escpos;
|
| 8 | pub mod help_view;
|
| 9 | pub mod image_load;
|
| 10 | pub mod io;
|
| 11 | pub mod params;
|
| 12 | pub mod pipeline;
|
| 13 | pub mod preview;
|
| 14 | pub mod print;
|
| 15 | pub mod protocol_url;
|
| 16 | pub mod raster;
|
| 17 | pub mod text_wrap;
|
| 18 | pub mod undo;
|
| 19 |
|
| 20 | #[cfg(windows)]
|
| 21 | pub const HELP_CLI_MARKDOWN: &str = include_str!("../docs/HELP-CLI-WINDOWS.md");
|
| 22 |
|
| 23 | #[cfg(not(windows))]
|
| 24 | pub const HELP_CLI_MARKDOWN: &str = include_str!("../docs/HELP-CLI-LINUX.md");
|
| 25 |
|
| 26 | #[cfg(windows)]
|
| 27 | pub const HELP_MARKDOWN: &str = concat!(
|
| 28 | include_str!("../docs/HELP.md"),
|
| 29 | "\n\n",
|
| 30 | include_str!("../docs/HELP-CLI-WINDOWS.md")
|
| 31 | );
|
| 32 |
|
| 33 | #[cfg(not(windows))]
|
| 34 | pub const HELP_MARKDOWN: &str = concat!(
|
| 35 | include_str!("../docs/HELP.md"),
|
| 36 | "\n\n",
|
| 37 | include_str!("../docs/HELP-CLI-LINUX.md")
|
| 38 | );
|
| 39 |
|
| 40 | #[cfg(test)]
|
| 41 | mod tests {
|
| 42 | use super::*;
|
| 43 |
|
| 44 | #[test]
|
| 45 | fn help_markdown_includes_cli_section() {
|
| 46 | assert!(HELP_MARKDOWN.contains("posprint print"));
|
| 47 | assert!(!HELP_CLI_MARKDOWN.is_empty());
|
| 48 | assert!(HELP_MARKDOWN.contains(HELP_CLI_MARKDOWN));
|
| 49 | }
|
| 50 | }
|