Browse Source

Build outputs: thin-layout make.tcl sync (help pure dry-run + received report)

Assisted-by: harness=claude; primary-model=claude-opus-5[1m]; api-location=anthropic.com
master
Julian Noble 1 week ago
parent
commit
6f41c73324
  1. 81
      src/modules/punk/mix/#modpod-templates-999999.0a1.0/templates/project_layouts/vendor/punk/project-0.1/src/make.tcl
  2. 81
      src/project_layouts/vendor/punk/basic/src/make.tcl
  3. 81
      src/project_layouts/vendor/punk/project-0.1/src/make.tcl

81
src/modules/punk/mix/#modpod-templates-999999.0a1.0/templates/project_layouts/vendor/punk/project-0.1/src/make.tcl vendored

@ -3246,10 +3246,13 @@ if {[info exists ::env(PUNKBOOT_PLAIN)] && [string is true -strict $::env(PUNKBO
help tool build -test 0 punkzip' shows the tool build form, as does help tool build -test 0 punkzip' shows the tool build form, as does
appending -help to the command line itself ('make.tcl tool build appending -help to the command line itself ('make.tcl tool build
-test 0 punkzip -help') - while a line it would reject shows the -test 0 punkzip -help') - while a line it would reject shows the
same usage error the subcommand itself would produce (synopsis plus same usage error the subcommand itself would produce (the error
per-form reasons, exit 1). A bare action word always renders that table carries the forms' synopsis, argument rows and per-form
action's usage, even where the real command needs more arguments reasons; exit 1). An accepted line is confirmed with a one-line
('make.tcl help buildsuite build')." report of where each word landed ('kitname = punk91 -confirm 0'
reveals flag-like words consumed as values); an action word alone
is dry-run too, so a form needing more arguments reports them via
the usage error ('make.tcl help buildsuite build')."
buildsuite buildsuite
" "
Surface for the defined buildsuites under src/buildsuites (zig-built Surface for the defined buildsuites under src/buildsuites (zig-built
@ -3964,43 +3967,61 @@ if {$do_help} {
set usage_id (script)::punkboot::$help_subject set usage_id (script)::punkboot::$help_subject
} }
set usage_args [list] set usage_args [list]
set accepted_note ""
if {[llength $help_words]} { if {[llength $help_words]} {
#G-143 (refined 2026-08-01): help_words is the subject's own command line #G-143 (refined 2026-08-01): help_words is the subject's own command line
#('make.tcl help tool build -test 0 punkzip') and help is a DRY-RUN of #('make.tcl help tool build -test 0 punkzip') and help is a pure DRY-RUN
#it: the words parse through the subject's declaration exactly as #of it: the words parse through the subject's declaration exactly as
#dispatch would parse them (punk::args form auto-selection - literal #dispatch would parse them (punk::args form auto-selection - literal
#action leaders, choice prefixes). A line the subcommand would accept #action leaders, choice prefixes). A line the subcommand would accept
#renders the matched form's single-form usage (whole usage for #renders the matched form's single-form usage (whole usage for
#single-form subjects); a line it would reject gets the same pointed #single-form subjects) plus a one-line report of where each received
#punk::args diagnosis dispatch would give - synopsis plus per-form #word landed; a line it would reject gets the same pointed punk::args
#reasons - on stderr with exit 1, never a plain-help fallback. Note #diagnosis dispatch would give on stderr with exit 1 - the error table
#punk::args' positional model: flag-like words at or after the first #carries the all-forms synopsis, per-form reasons and argument rows,
#value position are consumed as values, so such lines still render #so it IS the form documentation. Deliberately no bare-action
#usage cleanly (and declaration-level passthroughs - shell args, #carve-out: 'help buildsuite build' shows the build form via the
#buildsuite driver args - parse clean by design). #diagnosis that a suitename is still required. Note punk::args'
#One carve-out: a BARE action word (or unambiguous prefix) asks about #positional model: flag-like words at or after the first value
#that form rather than claiming a runnable line - forms with required #position are consumed as VALUES - the accepted-line report makes
#values ('buildsuite build' needs a suitename) would fail a strict #that visible ('kitname = punk91 -confirm 0'); declaration-level
#dry-run, so a single form-matching word renders the form directly. #passthroughs (shell args, buildsuite driver args) parse clean by
set form_names [punk::args::forms $usage_id] #design.
set fmatch "" if {[catch {punk::args::parse $help_words -errorstyle $::punkboot::errstyle withid $usage_id} argd]} {
if {[llength $help_words] == 1 && [llength $form_names] > 1} { puts stderr $argd
set fmatch [tcl::prefix::match -error "" $form_names [lindex $help_words 0]] exit 1
} }
if {$fmatch ne ""} { set form_names [punk::args::forms $usage_id]
lappend usage_args -form $fmatch if {[llength $form_names] > 1} {
} else { lappend usage_args -form [dict get $argd form]
if {[catch {punk::args::parse $help_words -errorstyle $::punkboot::errstyle withid $usage_id} argd]} { }
puts stderr $argd #interim 'where did my words land' clue (punk::args has no annotated
exit 1 #success render yet): name = value pairs for RECEIVED args only
} #(defaulted opts omitted), so a swallowed flag-like word shows up
if {[llength $form_names] > 1} { #against the argument that consumed it.
lappend usage_args -form [dict get $argd form] set recnames [list]
foreach {rn ri} [dict get $argd received] {
if {$rn ni $recnames} {lappend recnames $rn}
}
set parts [list]
foreach section {leaders opts values} {
foreach {an av} [dict get $argd $section] {
if {$an in $recnames} {lappend parts "$an = $av"}
} }
} }
set accepted_note "dry-run: line accepted"
if {[llength $form_names] > 1} {
append accepted_note " (form [dict get $argd form])"
}
if {[llength $parts]} {
append accepted_note " - [join $parts { | }]"
}
} }
if {![catch {punk::args::usage {*}$usage_args $usage_id} usage_out]} { if {![catch {punk::args::usage {*}$usage_args $usage_id} usage_out]} {
puts stdout $usage_out puts stdout $usage_out
if {$accepted_note ne ""} {
puts stdout $accepted_note
}
set availability_note [::punkboot::punkboot_availability_note] set availability_note [::punkboot::punkboot_availability_note]
if {$availability_note ne ""} { if {$availability_note ne ""} {
puts stdout $availability_note puts stdout $availability_note

81
src/project_layouts/vendor/punk/basic/src/make.tcl vendored

@ -3246,10 +3246,13 @@ if {[info exists ::env(PUNKBOOT_PLAIN)] && [string is true -strict $::env(PUNKBO
help tool build -test 0 punkzip' shows the tool build form, as does help tool build -test 0 punkzip' shows the tool build form, as does
appending -help to the command line itself ('make.tcl tool build appending -help to the command line itself ('make.tcl tool build
-test 0 punkzip -help') - while a line it would reject shows the -test 0 punkzip -help') - while a line it would reject shows the
same usage error the subcommand itself would produce (synopsis plus same usage error the subcommand itself would produce (the error
per-form reasons, exit 1). A bare action word always renders that table carries the forms' synopsis, argument rows and per-form
action's usage, even where the real command needs more arguments reasons; exit 1). An accepted line is confirmed with a one-line
('make.tcl help buildsuite build')." report of where each word landed ('kitname = punk91 -confirm 0'
reveals flag-like words consumed as values); an action word alone
is dry-run too, so a form needing more arguments reports them via
the usage error ('make.tcl help buildsuite build')."
buildsuite buildsuite
" "
Surface for the defined buildsuites under src/buildsuites (zig-built Surface for the defined buildsuites under src/buildsuites (zig-built
@ -3964,43 +3967,61 @@ if {$do_help} {
set usage_id (script)::punkboot::$help_subject set usage_id (script)::punkboot::$help_subject
} }
set usage_args [list] set usage_args [list]
set accepted_note ""
if {[llength $help_words]} { if {[llength $help_words]} {
#G-143 (refined 2026-08-01): help_words is the subject's own command line #G-143 (refined 2026-08-01): help_words is the subject's own command line
#('make.tcl help tool build -test 0 punkzip') and help is a DRY-RUN of #('make.tcl help tool build -test 0 punkzip') and help is a pure DRY-RUN
#it: the words parse through the subject's declaration exactly as #of it: the words parse through the subject's declaration exactly as
#dispatch would parse them (punk::args form auto-selection - literal #dispatch would parse them (punk::args form auto-selection - literal
#action leaders, choice prefixes). A line the subcommand would accept #action leaders, choice prefixes). A line the subcommand would accept
#renders the matched form's single-form usage (whole usage for #renders the matched form's single-form usage (whole usage for
#single-form subjects); a line it would reject gets the same pointed #single-form subjects) plus a one-line report of where each received
#punk::args diagnosis dispatch would give - synopsis plus per-form #word landed; a line it would reject gets the same pointed punk::args
#reasons - on stderr with exit 1, never a plain-help fallback. Note #diagnosis dispatch would give on stderr with exit 1 - the error table
#punk::args' positional model: flag-like words at or after the first #carries the all-forms synopsis, per-form reasons and argument rows,
#value position are consumed as values, so such lines still render #so it IS the form documentation. Deliberately no bare-action
#usage cleanly (and declaration-level passthroughs - shell args, #carve-out: 'help buildsuite build' shows the build form via the
#buildsuite driver args - parse clean by design). #diagnosis that a suitename is still required. Note punk::args'
#One carve-out: a BARE action word (or unambiguous prefix) asks about #positional model: flag-like words at or after the first value
#that form rather than claiming a runnable line - forms with required #position are consumed as VALUES - the accepted-line report makes
#values ('buildsuite build' needs a suitename) would fail a strict #that visible ('kitname = punk91 -confirm 0'); declaration-level
#dry-run, so a single form-matching word renders the form directly. #passthroughs (shell args, buildsuite driver args) parse clean by
set form_names [punk::args::forms $usage_id] #design.
set fmatch "" if {[catch {punk::args::parse $help_words -errorstyle $::punkboot::errstyle withid $usage_id} argd]} {
if {[llength $help_words] == 1 && [llength $form_names] > 1} { puts stderr $argd
set fmatch [tcl::prefix::match -error "" $form_names [lindex $help_words 0]] exit 1
} }
if {$fmatch ne ""} { set form_names [punk::args::forms $usage_id]
lappend usage_args -form $fmatch if {[llength $form_names] > 1} {
} else { lappend usage_args -form [dict get $argd form]
if {[catch {punk::args::parse $help_words -errorstyle $::punkboot::errstyle withid $usage_id} argd]} { }
puts stderr $argd #interim 'where did my words land' clue (punk::args has no annotated
exit 1 #success render yet): name = value pairs for RECEIVED args only
} #(defaulted opts omitted), so a swallowed flag-like word shows up
if {[llength $form_names] > 1} { #against the argument that consumed it.
lappend usage_args -form [dict get $argd form] set recnames [list]
foreach {rn ri} [dict get $argd received] {
if {$rn ni $recnames} {lappend recnames $rn}
}
set parts [list]
foreach section {leaders opts values} {
foreach {an av} [dict get $argd $section] {
if {$an in $recnames} {lappend parts "$an = $av"}
} }
} }
set accepted_note "dry-run: line accepted"
if {[llength $form_names] > 1} {
append accepted_note " (form [dict get $argd form])"
}
if {[llength $parts]} {
append accepted_note " - [join $parts { | }]"
}
} }
if {![catch {punk::args::usage {*}$usage_args $usage_id} usage_out]} { if {![catch {punk::args::usage {*}$usage_args $usage_id} usage_out]} {
puts stdout $usage_out puts stdout $usage_out
if {$accepted_note ne ""} {
puts stdout $accepted_note
}
set availability_note [::punkboot::punkboot_availability_note] set availability_note [::punkboot::punkboot_availability_note]
if {$availability_note ne ""} { if {$availability_note ne ""} {
puts stdout $availability_note puts stdout $availability_note

81
src/project_layouts/vendor/punk/project-0.1/src/make.tcl vendored

@ -3246,10 +3246,13 @@ if {[info exists ::env(PUNKBOOT_PLAIN)] && [string is true -strict $::env(PUNKBO
help tool build -test 0 punkzip' shows the tool build form, as does help tool build -test 0 punkzip' shows the tool build form, as does
appending -help to the command line itself ('make.tcl tool build appending -help to the command line itself ('make.tcl tool build
-test 0 punkzip -help') - while a line it would reject shows the -test 0 punkzip -help') - while a line it would reject shows the
same usage error the subcommand itself would produce (synopsis plus same usage error the subcommand itself would produce (the error
per-form reasons, exit 1). A bare action word always renders that table carries the forms' synopsis, argument rows and per-form
action's usage, even where the real command needs more arguments reasons; exit 1). An accepted line is confirmed with a one-line
('make.tcl help buildsuite build')." report of where each word landed ('kitname = punk91 -confirm 0'
reveals flag-like words consumed as values); an action word alone
is dry-run too, so a form needing more arguments reports them via
the usage error ('make.tcl help buildsuite build')."
buildsuite buildsuite
" "
Surface for the defined buildsuites under src/buildsuites (zig-built Surface for the defined buildsuites under src/buildsuites (zig-built
@ -3964,43 +3967,61 @@ if {$do_help} {
set usage_id (script)::punkboot::$help_subject set usage_id (script)::punkboot::$help_subject
} }
set usage_args [list] set usage_args [list]
set accepted_note ""
if {[llength $help_words]} { if {[llength $help_words]} {
#G-143 (refined 2026-08-01): help_words is the subject's own command line #G-143 (refined 2026-08-01): help_words is the subject's own command line
#('make.tcl help tool build -test 0 punkzip') and help is a DRY-RUN of #('make.tcl help tool build -test 0 punkzip') and help is a pure DRY-RUN
#it: the words parse through the subject's declaration exactly as #of it: the words parse through the subject's declaration exactly as
#dispatch would parse them (punk::args form auto-selection - literal #dispatch would parse them (punk::args form auto-selection - literal
#action leaders, choice prefixes). A line the subcommand would accept #action leaders, choice prefixes). A line the subcommand would accept
#renders the matched form's single-form usage (whole usage for #renders the matched form's single-form usage (whole usage for
#single-form subjects); a line it would reject gets the same pointed #single-form subjects) plus a one-line report of where each received
#punk::args diagnosis dispatch would give - synopsis plus per-form #word landed; a line it would reject gets the same pointed punk::args
#reasons - on stderr with exit 1, never a plain-help fallback. Note #diagnosis dispatch would give on stderr with exit 1 - the error table
#punk::args' positional model: flag-like words at or after the first #carries the all-forms synopsis, per-form reasons and argument rows,
#value position are consumed as values, so such lines still render #so it IS the form documentation. Deliberately no bare-action
#usage cleanly (and declaration-level passthroughs - shell args, #carve-out: 'help buildsuite build' shows the build form via the
#buildsuite driver args - parse clean by design). #diagnosis that a suitename is still required. Note punk::args'
#One carve-out: a BARE action word (or unambiguous prefix) asks about #positional model: flag-like words at or after the first value
#that form rather than claiming a runnable line - forms with required #position are consumed as VALUES - the accepted-line report makes
#values ('buildsuite build' needs a suitename) would fail a strict #that visible ('kitname = punk91 -confirm 0'); declaration-level
#dry-run, so a single form-matching word renders the form directly. #passthroughs (shell args, buildsuite driver args) parse clean by
set form_names [punk::args::forms $usage_id] #design.
set fmatch "" if {[catch {punk::args::parse $help_words -errorstyle $::punkboot::errstyle withid $usage_id} argd]} {
if {[llength $help_words] == 1 && [llength $form_names] > 1} { puts stderr $argd
set fmatch [tcl::prefix::match -error "" $form_names [lindex $help_words 0]] exit 1
} }
if {$fmatch ne ""} { set form_names [punk::args::forms $usage_id]
lappend usage_args -form $fmatch if {[llength $form_names] > 1} {
} else { lappend usage_args -form [dict get $argd form]
if {[catch {punk::args::parse $help_words -errorstyle $::punkboot::errstyle withid $usage_id} argd]} { }
puts stderr $argd #interim 'where did my words land' clue (punk::args has no annotated
exit 1 #success render yet): name = value pairs for RECEIVED args only
} #(defaulted opts omitted), so a swallowed flag-like word shows up
if {[llength $form_names] > 1} { #against the argument that consumed it.
lappend usage_args -form [dict get $argd form] set recnames [list]
foreach {rn ri} [dict get $argd received] {
if {$rn ni $recnames} {lappend recnames $rn}
}
set parts [list]
foreach section {leaders opts values} {
foreach {an av} [dict get $argd $section] {
if {$an in $recnames} {lappend parts "$an = $av"}
} }
} }
set accepted_note "dry-run: line accepted"
if {[llength $form_names] > 1} {
append accepted_note " (form [dict get $argd form])"
}
if {[llength $parts]} {
append accepted_note " - [join $parts { | }]"
}
} }
if {![catch {punk::args::usage {*}$usage_args $usage_id} usage_out]} { if {![catch {punk::args::usage {*}$usage_args $usage_id} usage_out]} {
puts stdout $usage_out puts stdout $usage_out
if {$accepted_note ne ""} {
puts stdout $accepted_note
}
set availability_note [::punkboot::punkboot_availability_note] set availability_note [::punkboot::punkboot_availability_note]
if {$availability_note ne ""} { if {$availability_note ne ""} {
puts stdout $availability_note puts stdout $availability_note

Loading…
Cancel
Save