在旧项目上升级 jhipster 版本
Upgrading jhipster version on old project
我有一个旧的 jhipster 项目,它是使用版本 3.9.1(最初)生成的,在不得不再次处理它之后,我想要做的第一件事就是将 jhipster 升级到最新版本,因为已经有很多改进。
我克隆了 repo,安装了所有必要的东西并尝试 运行 这个项目。一切正常!所以我 运行 yo jhipster:upgrade
在项目的根文件夹上。在出现一些权限问题和一些丢失的软件包之后,它终于升级到了 3.12.2 版而不是 4.6.1(最新)。
此时我必须解决一些冲突才能再次获得项目 运行ning,没问题。我检查了一下,我的包 "generator-jhipster" 的版本确实是 4.6.1(最新)。
我已经尝试 运行ning 升级过程几次,甚至强制使用 --target-version=4.6.1
版本,但在升级看似顺利之后,项目仍在 运行ning jhipster 3.12.2.
我在这里 尝试了解决方案,但没有成功。
我做错了什么?或者成功升级的步骤是什么? jhipster网站上的升级页面很模糊...
这是典型的升级日志:
Welcome to the JHipster Upgrade Sub-Generator
This will upgrade your current application codebase to the latest JHipster version
Looking for latest generator-jhipster version...
New generator-jhipster version found: 4.6.1
Git repository detected
Updating generator-jhipster. This might take some time...
Updated generator-jhipster to version 4.6.1
Checked out branch "jhipster_upgrade"
Cleaned up directory
Regenerating app with jhipster 4.6.1...
██ ██ ██ ████████ ███████ ██████ ████████ ████████ ███████
██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
██ ████████ ██ ███████ █████ ██ ██████ ███████
██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
██████ ██ ██ ████████ ██ ██████ ██ ████████ ██ ██
http://jhipster.github.io
Welcome to the JHipster Generator v3.12.2
Documentation for creating an application: https://jhipster.github.io/creating-an-app/
Application files will be generated in folder: C:\Users\quosei\Documents\GitHub\Agora
______________________________________________________________________________
JHipster update available: 4.6.1 (current: 3.12.2)
Run npm install -g generator-jhipster to update.
______________________________________________________________________________
This is an existing project, using the configuration from your .yo-rc.json file
to re-generate the project...
[A LOT OF FILE CHANGES (SKIPPED FOR READABILITY)]
Successfully regenerated app with jhipster 4.6.1
Committed with message "Generated with JHipster 4.6.1"
Checked out branch "master"
Merging changes back to master...
Merge done!
I'm all done. Running npm install && bower install for you to install the required dependencies. If this fails, try running the command yourself.
[NPM INSTALL && BOWER INSTALL RUN WITHOUT PROBLEM (SKIPPED FOR READABILITY)]
> yodoctor
Yeoman Doctor
Running sanity checks on your system
√ Global configuration file is valid
√ NODE_PATH matches the npm root
√ Node.js version
√ No .bowerrc file in home directory
√ No .yo-rc.json file in home directory
√ npm version
Everything looks all right!
> optipng-bin@3.1.4 postinstall C:\Users\quosei\Documents\GitHub\Agora\node_modules\optipng-bin
> node lib/install.js
√ optipng pre-build test passed successfully
> jpegtran-bin@3.2.0 postinstall C:\Users\quosei\Documents\GitHub\Agora\node_modules\jpegtran-bin
> node lib/install.js
√ jpegtran pre-build test passed successfully
> gifsicle@3.0.4 postinstall C:\Users\quosei\Documents\GitHub\Agora\node_modules\gifsicle
> node lib/install.js
√ gifsicle pre-build test passed successfully
> spawn-sync@1.0.15 postinstall C:\Users\quosei\Documents\GitHub\Agora\node_modules\spawn-sync
> node postinstall
added 1485 packages in 101.329s
[09:45:32] Using gulpfile ~\Documents\GitHub\Agora\gulpfile.js
[09:45:32] Starting 'install'...
[09:45:32] Starting 'inject:test'...
[09:45:33] Starting 'inject:vendor'...
[09:45:33] Starting 'ngconstant:dev'...
[09:45:33] Finished 'install' after 177 ms
[09:45:33] Finished 'ngconstant:dev' after 122 ms
[09:45:33] gulp-inject 33 files into karma.conf.js.
[09:45:33] gulp-inject 36 files into index.html.
[09:45:33] Finished 'inject:test' after 261 ms
[09:45:33] Finished 'inject:vendor' after 202 ms
[09:45:33] Starting 'inject:dep'...
[09:45:33] Finished 'inject:dep' after 6.74 μs
[09:45:33] Starting 'copy:languages'...
[09:45:33] Finished 'copy:languages' after 9.7 ms
[09:45:33] Starting 'inject:app'...
[09:45:33] gulp-inject 205 files into index.html.
[09:45:33] Finished 'inject:app' after 319 ms
[09:45:33] Starting 'inject:troubleshoot'...
[09:45:33] gulp-inject Nothing to inject into index.html.
[09:45:33] Finished 'inject:troubleshoot' after 12 ms
Upgraded successfully. Please now fix conflicts if any, and commit!
非常感谢!
JHipster 升级问题
如果不起作用
yarn global upgrade generator-jhipster
然后
yarn global add generator-jhipster
yarn global upgrade generator-jhipster
或
yo
我有一个旧的 jhipster 项目,它是使用版本 3.9.1(最初)生成的,在不得不再次处理它之后,我想要做的第一件事就是将 jhipster 升级到最新版本,因为已经有很多改进。
我克隆了 repo,安装了所有必要的东西并尝试 运行 这个项目。一切正常!所以我 运行 yo jhipster:upgrade
在项目的根文件夹上。在出现一些权限问题和一些丢失的软件包之后,它终于升级到了 3.12.2 版而不是 4.6.1(最新)。
此时我必须解决一些冲突才能再次获得项目 运行ning,没问题。我检查了一下,我的包 "generator-jhipster" 的版本确实是 4.6.1(最新)。
我已经尝试 运行ning 升级过程几次,甚至强制使用 --target-version=4.6.1
版本,但在升级看似顺利之后,项目仍在 运行ning jhipster 3.12.2.
我在这里
我做错了什么?或者成功升级的步骤是什么? jhipster网站上的升级页面很模糊...
这是典型的升级日志:
Welcome to the JHipster Upgrade Sub-Generator This will upgrade your current application codebase to the latest JHipster version Looking for latest generator-jhipster version... New generator-jhipster version found: 4.6.1 Git repository detected Updating generator-jhipster. This might take some time... Updated generator-jhipster to version 4.6.1 Checked out branch "jhipster_upgrade" Cleaned up directory Regenerating app with jhipster 4.6.1... ██ ██ ██ ████████ ███████ ██████ ████████ ████████ ███████ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ████████ ██ ███████ █████ ██ ██████ ███████ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██████ ██ ██ ████████ ██ ██████ ██ ████████ ██ ██ http://jhipster.github.io Welcome to the JHipster Generator v3.12.2 Documentation for creating an application: https://jhipster.github.io/creating-an-app/ Application files will be generated in folder: C:\Users\quosei\Documents\GitHub\Agora ______________________________________________________________________________ JHipster update available: 4.6.1 (current: 3.12.2) Run npm install -g generator-jhipster to update. ______________________________________________________________________________ This is an existing project, using the configuration from your .yo-rc.json file to re-generate the project... [A LOT OF FILE CHANGES (SKIPPED FOR READABILITY)] Successfully regenerated app with jhipster 4.6.1 Committed with message "Generated with JHipster 4.6.1" Checked out branch "master" Merging changes back to master... Merge done! I'm all done. Running npm install && bower install for you to install the required dependencies. If this fails, try running the command yourself. [NPM INSTALL && BOWER INSTALL RUN WITHOUT PROBLEM (SKIPPED FOR READABILITY)] > yodoctor Yeoman Doctor Running sanity checks on your system √ Global configuration file is valid √ NODE_PATH matches the npm root √ Node.js version √ No .bowerrc file in home directory √ No .yo-rc.json file in home directory √ npm version Everything looks all right! > optipng-bin@3.1.4 postinstall C:\Users\quosei\Documents\GitHub\Agora\node_modules\optipng-bin > node lib/install.js √ optipng pre-build test passed successfully > jpegtran-bin@3.2.0 postinstall C:\Users\quosei\Documents\GitHub\Agora\node_modules\jpegtran-bin > node lib/install.js √ jpegtran pre-build test passed successfully > gifsicle@3.0.4 postinstall C:\Users\quosei\Documents\GitHub\Agora\node_modules\gifsicle > node lib/install.js √ gifsicle pre-build test passed successfully > spawn-sync@1.0.15 postinstall C:\Users\quosei\Documents\GitHub\Agora\node_modules\spawn-sync > node postinstall added 1485 packages in 101.329s [09:45:32] Using gulpfile ~\Documents\GitHub\Agora\gulpfile.js [09:45:32] Starting 'install'... [09:45:32] Starting 'inject:test'... [09:45:33] Starting 'inject:vendor'... [09:45:33] Starting 'ngconstant:dev'... [09:45:33] Finished 'install' after 177 ms [09:45:33] Finished 'ngconstant:dev' after 122 ms [09:45:33] gulp-inject 33 files into karma.conf.js. [09:45:33] gulp-inject 36 files into index.html. [09:45:33] Finished 'inject:test' after 261 ms [09:45:33] Finished 'inject:vendor' after 202 ms [09:45:33] Starting 'inject:dep'... [09:45:33] Finished 'inject:dep' after 6.74 μs [09:45:33] Starting 'copy:languages'... [09:45:33] Finished 'copy:languages' after 9.7 ms [09:45:33] Starting 'inject:app'... [09:45:33] gulp-inject 205 files into index.html. [09:45:33] Finished 'inject:app' after 319 ms [09:45:33] Starting 'inject:troubleshoot'... [09:45:33] gulp-inject Nothing to inject into index.html. [09:45:33] Finished 'inject:troubleshoot' after 12 ms Upgraded successfully. Please now fix conflicts if any, and commit!
非常感谢!
JHipster 升级问题
如果不起作用
yarn global upgrade generator-jhipster
然后
yarn global add generator-jhipster
yarn global upgrade generator-jhipster
或
yo