How to update the JHipster project after updating JHipster generator?

后端 未结 7 2083
栀梦
栀梦 2020-12-29 08:37

I updated my JHipster installation as per this page by running the command

npm update -g generator-jhipster

But to update my application I

相关标签:
7条回答
  • 2020-12-29 09:00

    If you want to update all entities you need to run

    yo jhipster --with-entities
    

    from the root of your project

    0 讨论(0)
  • 2020-12-29 09:01

    JHipster developers replied over twitter saying that yo jhipster has to be executed at the project root folder.

    0 讨论(0)
  • 2020-12-29 09:01

    jhipster --force --with-entities this is how i do it (npm)

    0 讨论(0)
  • 2020-12-29 09:03

    JHipster now has a page on Upgrading an application.

    https://jhipster.github.io/upgrading-an-application/

    TL;DR

    Running the upgrade sub-generator

    Go into the application’s root directory:

    cd myapplication/

    To upgrade your application, type:

    yo jhipster:upgrade

    If you want to run the upgrade sub-generator even if no new JHipster version is available, type:

    yo jhipster:upgrade --force

    0 讨论(0)
  • 2020-12-29 09:05

    Our jHipster monolithic project is based on an older build of the generator, and still reliant on bower / angularjs for the client. Thus the auto-update ability would never work.

    I've been manually updating spring-boot-starter-parent every other sprint to try and bring it up into 2.x parity, but am still unable to leave the 1.5.x version stream due to various dependency issues with (mainly) Hibernate.

    As a possible suggestion if you're in the same boat with your own monolithic project:

    • Pull down select versions of the jhipster-generator
    • Generate a "hello world" starter monolithic project
    • Compare the generated pom.xml with your own project
    • Compare the generated entity and configuration files with your own project
    0 讨论(0)
  • 2020-12-29 09:14

    Run below command at the root of your project. Also, make sure to delete nodemodules and target folders before upgrading the project.

    yo jhipster:upgrade

    0 讨论(0)
提交回复
热议问题