From 3d8143c4d1d512f0ce5cd212a609b17fe1f0036e Mon Sep 17 00:00:00 2001 From: meehl <12648828+meehl@users.noreply.github.com> Date: Thu, 27 Nov 2025 10:07:35 +0100 Subject: [PATCH] Add help text to import url argument --- src/args.rs | 5 ++++- src/lua.rs | 4 ++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/src/args.rs b/src/args.rs index 009be2b..d648f3e 100644 --- a/src/args.rs +++ b/src/args.rs @@ -9,7 +9,10 @@ pub struct Args { #[arg(value_enum)] pub game: Game, - pub build_path: Option, + #[arg( + help = "URL of build to import on startup. Needs to use custom protocol schema, e.g. `pob://pobbin/`" + )] + pub import_url: Option, } #[derive(Debug, Clone, ValueEnum)] diff --git a/src/lua.rs b/src/lua.rs index f05b123..40cee44 100644 --- a/src/lua.rs +++ b/src/lua.rs @@ -170,9 +170,9 @@ impl LuaInstance { // SAFETY: use `unsafe_new` to allow loading of C modules let lua = unsafe { Lua::unsafe_new() }; - // expose build arg to lua + // expose import url to lua let args = Args::parse(); - let args_table = lua.create_sequence_from(std::iter::once(args.build_path))?; + let args_table = lua.create_sequence_from(std::iter::once(args.import_url))?; lua.globals().set("arg", args_table)?; Self::register_package_paths(&lua)?;