Re: Maven goal for dependencies

2020-11-11 Thread Karl Heinz Marbaise

On 11.11.20 10:16, Milan Tomic wrote:

Hello
I have a Maven Java project which produces a JAR (packaging = JAR). I am using external 
SonarQube scanner to scan my source code (SonarQube is not configured inside pom.xml). I 
am first building my project using "mvn clean package", then I execute 
SonarQube Scanner on it.
The issue is that SonarQube requires my project's dependencies to be on the 
path in order to properly scan my code. So, I need some Maven goal which will 
collect all dependencies in my project and place them inside of the /lib 
folder. Which Maven goal should I use?
Final result should be /lib folder containing apache, spring... dependencies.
Thank you in advance,Milan


will handle that on plain command line without copying dependencies etc.
you might need to configure the sonar host/branch/login via the given
properties:

mvn clean verify \
  -Dsonar.host.url=URL \
  -Dsonar.login=SONARTOKEN \
  -Dsonar.branch.name=NAME \
  org.sonarsource.scanner.maven:sonar-maven-plugin:3.7.0.1746:sonar


Kind regards
Karl Heinz Marbaise

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: Maven goal for dependencies

2020-11-11 Thread Oliver B. Fischer

mvn dependency:copy-dependencies might be your friend...

https://maven.apache.org/plugins/maven-dependency-plugin/copy-dependencies-mojo.html

Am 11.11.20 um 10:16 schrieb Milan Tomic:

Hello
I have a Maven Java project which produces a JAR (packaging = JAR). I am using external 
SonarQube scanner to scan my source code (SonarQube is not configured inside pom.xml). I 
am first building my project using "mvn clean package", then I execute 
SonarQube Scanner on it.
The issue is that SonarQube requires my project's dependencies to be on the 
path in order to properly scan my code. So, I need some Maven goal which will 
collect all dependencies in my project and place them inside of the /lib 
folder. Which Maven goal should I use?
Final result should be /lib folder containing apache, spring... dependencies.
Thank you in advance,Milan


--
N Oliver B. Fischer
A Schönhauser Allee 64, 10437 Berlin, Deutschland/Germany
P +49 30 44793251
M +49 178 7903538
E o.b.fisc...@swe-blog.net
S oliver.b.fischer
J oliver.b.fisc...@jabber.org
X http://xing.to/obf


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Maven goal for dependencies

2020-11-11 Thread Milan Tomic
Hello
I have a Maven Java project which produces a JAR (packaging = JAR). I am using 
external SonarQube scanner to scan my source code (SonarQube is not configured 
inside pom.xml). I am first building my project using "mvn clean package", then 
I execute SonarQube Scanner on it.
The issue is that SonarQube requires my project's dependencies to be on the 
path in order to properly scan my code. So, I need some Maven goal which will 
collect all dependencies in my project and place them inside of the /lib 
folder. Which Maven goal should I use?
Final result should be /lib folder containing apache, spring... dependencies.
Thank you in advance,Milan