Merged
Conversation
bcc309b to
6714d58
Compare
There was a problem hiding this comment.
Pull request overview
This PR updates the builbo CLI script, primarily refactoring how defaults are defined/displayed and how command-line arguments/actions are parsed and validated.
Changes:
- Introduces
DEFAULT_*variables and updatesusage()output to show those defaults. - Refactors argument parsing flow and adds extensive console logging during parsing.
- Adjusts image naming/formatting and expands variable usage to
${...}form.
Comments suppressed due to low confidence (1)
cli/builbo:77
-i/--shellis documented inusage()(and mentioned in the help text), but it is not actually parsed/handled:optstringdoesn’t includei,optstring_longdoesn’t includeshell, and there is nocasearm for it. Either implement the option (setI_SHELL) or remove it from the usage/help text so the CLI contract matches behavior.
[ -s | --build-script (command|path) ] - command or local script (in the CWD) for building the project.
[ -d | --deps (pkg,pkg,pkg,...) ] - additional packages to install (comma-separated)
-i | --shell (bash) ] - sinteractive shell (default: ${DEFAULT_I_SHELL})
[ -h | --help ] - action help: print this usage information
[-t | --test ] - action test: print some diagnostic info for testing this program
[ -b | --build ] - action build: perform a build in the CWD
[ -e | --enter] - action enter: enter container in interactive mode (shell)
The Options -l, -r, -o, and -n in combination determine the buildbox image (by tag) to be used.
The options -h, -t, -e, and -b are the available actions (help, test, enter, and build) to be performed.
Exactly one of the actions must be selected.
The build action requires the additional option -s.
The enter action makes use of the --shell option.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
f7746ae to
774b6e4
Compare
Signed-off-by: Michael Adam <obnox@samba.org>
774b6e4 to
0c97fb5
Compare
1 task
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.