From f5013e569367f0b3e953920e9344c4e836024c3a Mon Sep 17 00:00:00 2001 From: Delyan Angelov Date: Fri, 19 Dec 2025 17:24:22 +0200 Subject: [PATCH] examples: move flag/ .v files 1 level up, to prevent module lookup confusion for unrelated examples --- examples/{flag => }/animated_help_text.v | 0 examples/{flag => }/flag_layout_editor.v | 0 vlib/flag/README.md | 16 ++++++++-------- 3 files changed, 8 insertions(+), 8 deletions(-) rename examples/{flag => }/animated_help_text.v (100%) rename examples/{flag => }/flag_layout_editor.v (100%) diff --git a/examples/flag/animated_help_text.v b/examples/animated_help_text.v similarity index 100% rename from examples/flag/animated_help_text.v rename to examples/animated_help_text.v diff --git a/examples/flag/flag_layout_editor.v b/examples/flag_layout_editor.v similarity index 100% rename from examples/flag/flag_layout_editor.v rename to examples/flag_layout_editor.v diff --git a/vlib/flag/README.md b/vlib/flag/README.md index f4c20fa3e..fd02b362a 100644 --- a/vlib/flag/README.md +++ b/vlib/flag/README.md @@ -67,12 +67,12 @@ fn main() { documentation := flag.to_doc[Config]( version: '1.0' // NOTE: this overrides the `@[version: '1.2.3']` struct attribute fields: { - 'level': 'This is a doc string of the field `level` on struct `Config`' - 'example': 'This is another doc string' - 'multi': 'This flag can be repeated' - '-e, --extra': 'Extra flag that does not exist on the struct, but we want documented (in same format as the others)' - '-q, --quiet-and-quite-long-flag ': 'This is a flag with a long name' - 'square': '.____.\n| |\n| |\n|____|' + 'level': 'This is a doc string of the field `level` on struct `Config`' + 'example': 'This is another doc string' + 'multi': 'This flag can be repeated' + '-e, --extra': 'Not on the struct, with documentation (in same format as the others)' + '-q, --long-flag ': 'This is a flag with a long name' + 'square': '.____.\n| |\n| |\n|____|' } )! println(documentation) @@ -119,7 +119,7 @@ documentation. The documentation can be tweaked in several ways to suit any spec user needs via the `DocConfig` configuration struct or directly via attributes on the struct itself and it's fields. -See also `examples/flag/flag_layout_editor.v` for a WYSIWYG editor. +See also `examples/flag_layout_editor.v` for a WYSIWYG editor. # Sub commands @@ -210,4 +210,4 @@ fn main() { println('an_int: ${an_int} | a_bool: ${a_bool} | a_float: ${a_float} | a_string: "${a_string}" ') println(additional_args.join_lines()) } -``` \ No newline at end of file +``` -- 2.39.5