diff options
| author | 魏曹先生 <1992414357@qq.com> | 2026-08-09 01:14:19 +0800 |
|---|---|---|
| committer | 魏曹先生 <1992414357@qq.com> | 2026-08-09 01:17:21 +0800 |
| commit | cde7be4e67aea4378fbac8462ba8fff48b73ea1e (patch) | |
| tree | 2740f295a797bce72ad5c6e69bf77a5997568a85 /tools/tscn-to-bsn/src/fallback.rs | |
| parent | dfbc80098c2b46adb14a571947fb7ac8f0169224 (diff) | |
feat(tscn-to-bsn): add global help fallback support
Add a fallback module providing a help command that displays usage
information for the tool.
Diffstat (limited to 'tools/tscn-to-bsn/src/fallback.rs')
| -rw-r--r-- | tools/tscn-to-bsn/src/fallback.rs | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/tools/tscn-to-bsn/src/fallback.rs b/tools/tscn-to-bsn/src/fallback.rs new file mode 100644 index 0000000..99bdd13 --- /dev/null +++ b/tools/tscn-to-bsn/src/fallback.rs @@ -0,0 +1,13 @@ +use mingling::macros::{help, renderer}; + +use crate::EntryFallback; + +#[help] +pub fn help_global(_: EntryFallback) -> String { + include_str!("helps/help.txt").to_string() +} + +#[renderer] +pub fn render_global_hint(_: EntryFallback) -> String { + "Error: unknown command, please use `tscn2bsn /H` for help".into() +} |
