一:前置条件
安装java java -version
安装node node -v
安装npm npm -v
二:开始安装Jhipster
设置淘宝镜像:npm config set registry https://registry.npmmirror.com
查看设置成功:npm config get registry
安装Jhipster:npm install -g generator-jhipster
查看是否安装成功:jhipster --version
启动:jhipster
三:安装问题
下面是具体问题的意思:
您的项目名是什么?
What is the base name of your application?
您想要创建什么类型的应用?(选项有单体架构和微服务架构等)
Which *type* of application would you like to create?
您的项目包名是什么?(这里会给个默认的包名,可自行修改)
What is your default Java package name?
您想通过maven还是gradle方式构建项目?
Would you like to use Maven or Gradle for building the backend?
您想创建一个spring webflux响应式项目吗?
Do you want to make it reactive with Spring WebFlux?
您想用哪种权限校验方式?
Which *type* of authentication would you like to use?
除了junit,您还想用哪种测试框架?(不需要其他测试框架直接回车)
Besides JUnit, which testing frameworks would you like to use?
您想用哪种类型数据库?
Which *type* of database would you like to use?
您的生产数据库具体想使用哪一种数据库?(即线上数据库类型)
Which *production* database would you like to use?
您的本地数据库具体想使用哪一种数据库?(即本地数据库类型)
Which *development* database would you like to use?
您想使用哪种缓存?(根据需要选择,不需要直接回车)
Which cache do you want to use?
您还想使用哪些其他技术?(根据需要选择即可)
Which other technologies would you like to use?
您想为前端选择哪个使用框架?
Which *framework* would you like to use for the client?
您是否需要生成管理界面?
Do you want to generate the admin UI?
您想使用哪种Bootswatch主题?(可打开bootswatch官网查看对应的主题)
Would you like to use a Bootswatch theme (https://bootswatch.com/)?
您想选择哪个Bootswatch导航栏主题?(这里我选择默认的Primary)
Choose a Bootswatch variant navbar theme (https://bootswatch.com/)?
您是否需要国际化支持?
Would you like to enable internationalization support?
请选择您应用的母语(我选的是中文简体)
Please choose the native language of the application
请选择您应用的其次语言(我选的是英语,通过上下箭头选择)
Please choose additional languages to install
四:然后就生成了很多代码