Support named parameters in the build script#4
Merged
Conversation
…y support Replace the positional-only build script with a flag-based CLI: - Named flags: -v/--version, -n/--name, -l/--long-name, -o/--output - New -b/--build-number flag for stable CI build numbers (github.run_number) - Legacy positional args (VERSION NAME LONG_NAME) still work for muscle memory - Debug mode (-d), help (-h), and input validation - Update CI workflow to use build.sh with -b for stable build numbers - Update docs (README, introduction, build-from-source) with new usage
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.
Summary
Port of upstream PR criteo#192 onto the fork's main.
Four commits (the original branch's merge-with-upstream commit was skipped — its content is already in main):
Enhance build script with named flags, build number option, and legacy support—build.shrewritten to take-v/-n/-l/-o/-b/-r/-d/-hflags while preserving the legacy positional invocation.Fix markdown lint: add blank lines before fenced code blocks— doc cleanup the linter required.Accept legacy --resign as positional arg for backwards compat— keeps the old./build.sh VERSION NAME LONG_NAME --resignform working.Fix Windows CI: add shell: bash to Build step—build.shis a POSIX shell script; the Build step neededshell: bashso Windows runners invoke Git Bash.CI workflow's Build step now uses
./build.sh -v ... -b ${{github.run_number}} -n cdt -l "Criteo Dev Toolkit" -o ...instead of inlinego build, which gives stable build numbers tied to the GitHub run.Conflicts resolved during cherry-pick:
README.mdandbuild.sh: took the PR's complete versions (the PR rewrote the build script substantially; the legacy positional form is still honored at runtime)..github/workflows/go.yml: auto-merged cleanly (PR Support named parameters in the build script criteo/command-launcher#192'sshell: bash+ new build-script invocation slotted in alongside our action-version bumps).The original branch
build_script_options(which still backs PR criteo#192 upstream) is untouched.Test plan
go vet ./...clean locallygo test ./...passes locally./test/integration.sh18/18 suites pass locally./build.sh -v test-port -n testapp -l "Test App"produces a working binaryshell: bashfix should make Windows happy)