Difficulty: Beginner
Estimated Time: 15 Minutes

The definition of each step of this tutorial can be found at https://github.com/devonfw-tutorials/tutorials/tree/main/devon4j-migrate.

Feel free to report any errors to us or fix them yourself. Errors can be reported by creating an issue in the tutorials repository. To fix the error fork the repository and create a pull request. Errors in the wiki can be reported and fixed in the tutorial-compiler repository. You can find a description of what to look for when creating a pull request at the devonfw contribution guide: https://devonfw.com/website/pages/community/community.html#community.asciidoc_contributing-to-devonfw. If you want to create a tutorial you can start with the katacoda tutorial and read the description for creating your own tutorials: https://github.com/devonfw-tutorials/tutorials/wiki/Development.

This tutorial mainly focuses on migrating an older version of devon4j project to the latest version using devon4j migrate command.

Prerequisites

  • devonfw IDE

Learning goals.

Here in this tutorial you will learn

  • How to migrate an older version of devon4j project to the latest version.

Conclusion

You have successfully migrated the sample project from an older version to the latest version using command line!!

For more details on devon4j java commands for various functionalities and the arguments (devon java «args») follow https://devonfw.com/website/pages/docs/devonfw-ide-usage.asciidoc.html#java.asciidoc

Migrate a devon4j project to the latest version

Execute Migrate Command

To demonstrate devon4j migrate you would need a sample devon4j project with any older version. Here, we have already created a project with an older version i.e. 2020.08.001 for you.

It is already cloned in workspace.

Execute below command for project migration from an older version to the latest version.

Please change the folder to 'devonfw/workspaces/main/devon4j-app-4tutorial'.

cd devonfw/workspaces/main/devon4j-app-4tutorial

Run devon java migrate with this command. devon java migrate

You will see the message similar to the one below, if project migrated successfully. Successfully applied 4 migrations to migrate project from version devon4j:2020.08.001 to devon4j:2021.04.002.

Here, 2020.08.001 is the devon4j's older version and 2021.04.002 is devon4j's latest version.