How to build WAR from command line if premium addons are used

Hello Cuba Team!!

I have downloaded the cuba studio now and while trying to generate the war it is throwing the exception.
For that I have gone through this link.

I tested for rootProject.hasProperty(‘premiumRepoUser’) which is displaying ‘true’ while running the application and taking the license key.
But while generating the war from Command Prompt rootProject.hasProperty(‘premiumRepoUser’) this is displaying ‘false’ and throwing exception.

Please find the below attached images for reference.





If your project uses Premium Add-ons, and you are starting build tasks outside Studio, pass the Premium Add-ons repository credentials in the command line arguments with -P prefix:

> gradle assemble -PpremiumRepoUser=111111222222 -PpremiumRepoPass=abcdefabcdef

See also:

I am able to build the war successfully by using the below one

gradle assemble -PpremiumRepoUser=111111222222 -PpremiumRepoPass=abcdefabcdef

Can you please say me At which location I will be able to get the war?

Because if i build the war with gradlew.bat extWarBuilding
then I can see my generated war in C:\Users\Sushma\Desktop\Project\project_cloud\build\distributions\war

WAR files are built only if your start buildWar task explicitly:

> gradle buildWar -PpremiumRepoUser=111111222222 -PpremiumRepoPass=abcdefabcdef 
1 Like

A post was split to a new topic: Gradle does not download premium artifacts from command line