fix: Support escaped delimiters in --package for Maven packages#584
Open
HuyPhanNguyen wants to merge 1 commit intomainfrom
Open
fix: Support escaped delimiters in --package for Maven packages#584HuyPhanNguyen wants to merge 1 commit intomainfrom
HuyPhanNguyen wants to merge 1 commit intomainfrom
Conversation
Maven package IDs contain colons (e.g. com.yourcompany:project-name) which conflict with the delimiter used to separate package ID from version. Add backslash escape support (\: \/ \=) so users can specify Maven packages: --package "com.yourcompany\:project-name:1.0-SNAPSHOT" Also escape delimiter chars when reconstructing override strings for the server API.
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
\:\/\=) tosplitPackageOverrideStringso Maven package IDs containing colons can be correctly specified via--packageToPackageOverrideStringso the reconstructed string sent to the server API is also parseableFixes #547
Related: https://linear.app/octopus/issue/FD-135
Requires companion server PR: OctopusDeploy/OctopusDeploy#41734
Context
Maven package IDs use the format
Group:Artifact(e.g.com.juliusbaer.fi-master:deployment). The CLI's--packageargument uses:as a delimiter between package ID and version, making it impossible to specify Maven packages correctly.With this fix, users can escape the colon:
Test plan
ParsePackageOverrideStringtests pass (no regression)ToPackageOverrideStringtests pass (no regression)ResolvePackageOverrideandApplyPackageOverridetests pass