Skip to content

Commit

Permalink
maven: improve buildMavenPackage offline mode
Browse files Browse the repository at this point in the history
The maven `dependency:go-offline` plugin has various issues
(see https://issues.apache.org/jira/browse/MDEP-204 and other
issues in that tracker), which the dedicated plugin from
https://github.com/qaware/go-offline-maven-plugin largely
fixes. I have confirmed that for an application I'm packaging
outside of nixpkgs, dependency-track, this indeed makes the
build work while it didn't with `dependency:go-offline`.

The offline mode is only used in one place in nixpkgs, for
lemminx. That build still succeeds and the program starts, though
I haven't tested further.
  • Loading branch information
raboof authored and jsoo1 committed Mar 21, 2024
1 parent 91bdd5b commit 4dccdf4
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ let
buildPhase = ''
runHook preBuild
'' + lib.optionalString buildOffline ''
mvn dependency:go-offline -Dmaven.repo.local=$out/.m2 ${mvnDepsParameters}
mvn de.qaware.maven:go-offline-maven-plugin:1.2.8:resolve-dependencies -Dmaven.repo.local=$out/.m2 ${mvnDepsParameters}
for artifactId in ${builtins.toString manualMvnArtifacts}
do
Expand Down

0 comments on commit 4dccdf4

Please sign in to comment.