【发布时间】:2017-01-23 23:15:05
【问题描述】:
我有一个在 hipster 3.6.1 上运行的现有项目,我想将其升级到 3.12.2。我按照jhipster网站描述的升级过程,但是生成的hipster_upgrade分支还是提到了旧版本的子生成器。
使用 npm 强制更新
在运行以下命令 npm install -g generator-jhipster 时,它会显示以下内容
npm WARN deprecated node-uuid@1.4.7: use uuid module instead
npm WARN deprecated npmconf@2.1.2: this package has been reintegrated into npm and is now out of date with respect to npm
/usr/local/lib
└── generator-jhipster@3.12.2
然后我运行yo jhipster --force --with-entities,这是输出:
Welcome to the JHipster Generator v3.6.1
Documentation for creating an application: https://jhipster.github.io/creating-an-app/
Application files will be generated in folder: /Users/bso/Projects/portal ______________________________________________________________________________
JHipster update available: 3.12.2 (current: 3.6.1)
Run npm install -g generator-jhipster to update.
______________________________________________________________________________
重新安装 jhipster 生成器
在做npm i generator-jhipster时,jhipster生成器更新到3.12.2,但是在重新处理升级时,它又回到了3.6.1。
关于为什么会发生这种情况的任何线索?
【问题讨论】:
-
全局更新,使用 -g 开关,npm install -g generator-jhipster
-
我是这样做的,它没有用...我怎样才能完全删除版本 3.6.1?
-
你试过 jhipster 作为本地生成器吗?喜欢你当地的发电机?如果你尝试过这个 npm link generator-jhipster,那么从本地目录中取消链接或删除生成器
标签: node.js jhipster yeoman-generator