This commit is contained in:
2025-10-21 08:49:11 +02:00
parent b538540cd4
commit f69078a42e
8 changed files with 615 additions and 7 deletions

View File

@@ -146,17 +146,17 @@ pub fn generate(args_ GenerateArgs) ! {
description: 'Are there builders for the installers (compilation)'
)!
}
// args.reset = myconsole.ask_yesno(
// description: 'Reset, overwrite code.'
// question: 'This will overwrite all files in your existing dir, be carefule?'
// )!
meta.path = args.path
println(meta)
create_heroscript(meta)!
generate_exec(args.path, true)!
}
pub fn create_heroscript(args ModuleMeta) ! {
mut script := ''
if args.path == '' {
return error('no path provided to create heroscript')
}
if args.cat == .installer {
script = "
!!hero_code.generate_installer
@@ -205,7 +205,7 @@ pub fn create_heroscript(args ModuleMeta) ! {
'1'
} else {
'0'
}}
}
}"
}
if !os.exists(args.path) {