netodevel / cli-spring-boot-scaffold

command line for generate crud and configs for spring boot projects
131 stars 49 forks source link

'mvn install' step throws compilation errors #53

Closed jmechevarria closed 5 years ago

jmechevarria commented 5 years ago

After successfully installing Spring Boot CLI and cloning the repo to a local folder I try

D:\path\to\cli-spring-boot-scaffold> mvn install

and get tons of errors on the log, the first one being

[ERROR] D:/path/to/cli-spring-boot-scaffold/spring-boot-generate/src/main/java/br/com/example/service/UserService.java:[4,47] package org.springframework.data.jpa.repository does not exist

I've never used Maven, I installed it just for this one task. I use Gradle (not a guru either) in my project.

netodevel commented 5 years ago

Thanks for reporting this issue, I'm already investigating.

netodevel commented 5 years ago

The problem is occurring because in tests it generates test files and is not able to delete ... To get around this as I correct the problem, you can do:

git add .
git stash save
mvn install -Dmaven.test.skip=true
jmechevarria commented 5 years ago

That solved it.

Heads up for Windows' PowerShell users, use this:

mvn install "-Dmaven.test.skip=true"

mind the double quotes

Closing issue now