Repository navigation
Conversation
fluxxBot
suggested changes
Dec 11, 2025
nitinp19
requested review from
agrasth,
bhanurp,
itsmeleela and
naveenku-jfrog
December 12, 2025 09:49
fluxxBot
suggested changes
Dec 16, 2025
| } | ||
|
|
||
| // FlexPack native mode for Gradle (bypasses config file requirements) | ||
| if nativeMode && !configExists { |
Contributor
There was a problem hiding this comment.
already a function exists for this in build-info-go
| } | ||
|
|
||
| configFilePath, err := getProjectConfigPathOrThrow(project.Gradle, "gradle", "gradle-config") | ||
| nativeMode := os.Getenv("JFROG_RUN_NATIVE") == "true" |
Contributor
There was a problem hiding this comment.
Comment on lines
+638
to
+661
| // FlexPack native mode for Gradle (bypasses config file requirements) | ||
| if nativeMode && !configExists { | ||
| log.Debug("Routing to Gradle FlexPack implementation") | ||
| if c.NArg() < 1 { | ||
| return cliutils.WrongNumberOfArgumentsHandler(c) | ||
| } | ||
| args := cliutils.ExtractCommand(c) | ||
| filteredGradleArgs, buildConfiguration, err := build.ExtractBuildDetailsFromArgs(args) | ||
| if err != nil { | ||
| return err | ||
| } | ||
|
|
||
| // Create Gradle command with FlexPack (no config file needed) | ||
| gradleCmd := gradle.NewGradleCommand().SetConfiguration(buildConfiguration).SetTasks(filteredGradleArgs).SetConfigPath("") | ||
| return commands.Exec(gradleCmd) | ||
| } | ||
|
|
||
| // If config file is missing and not in native mode, return the standard missing-config error. | ||
| if !configExists { | ||
| if configFilePath, err = getProjectConfigPathOrThrow(project.Gradle, "gradle", "gradle-config"); err != nil { | ||
| return err | ||
| } | ||
| } | ||
|
|
Contributor
There was a problem hiding this comment.
can we improve this entire conditional logic?
Contributor
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.

Challenge- Currently we don't support run native any gradle commands. We have our own custom command "artifactoryPublish" to publish the build info for the gradle.
Implementation- We are using the flexpack which will help us to collect the build info for the gradle run-native command