Migrate Script File Imports
This section offers step-by-step guidance for migrating DaVinci Configurator Version 5 Automation Interface script file imports to DaVinci ConfiguratorVersion 6 script file imports.
Prerequisites
The migration of Version 5 Automation Interface scripts requires the setup of:
License
-
DaVinci Configurator 6 (see Licenses)
Installation
-
DaVinci Configurator 6 (see Installation)
-
CLI (e.g. CMD, PowerShell, Bash)
-
IDE (see Automation Interface Documentation)
-
JDK (see Automation Interface Documentation)
Input
-
Directory containing CFG5 script files to migrate
|
Assisted Migration
During migration, the Migration Assistant creates a backup copy of the input directory and transforms the script files inside the input directory directly.
If the parent directory of the input directory is not intended for changes, choose a more suitable location for your input directory instead.
|
Assisted Migration via Tool
This section describes steps for migrating Version 5 Automation Interface imports (inside .groovy script files) with the help of the Migration Assistant.
| You can use this functionality if you only want to migrate Version 5 imports automatically. Be aware that the migration of affected script code is still necessary to correctly execute your script file with Version 6 (e.g. compare to the Manual Migration of Script Files). |
Convert to Version 6 Script File Imports
-
Open your CLI.
-
Navigate to the parent directory of the Migration Assistant located inside the Version 6 installation directory (
<cfg6 installation>/migration). -
Run
pai-migration.exe files -s <path to directory containing .groovy script files>to start migrating CFG5 imports of your.groovyfiles to Version 6 imports. -
If the migration of script file imports fails (see CLI status logs of the migration process), follow the error logs to fix your setup and re-run the migration steps once more.
|
Migration Assistant Help
Run pai-migration.exe -h for a more detailed overview of all supported use cases, CLI commands and parameters, and further information.
|
Results
If the migration of script file imports succeeds, two output directories are created in the parent directory of the input directory:
-
A transformed copy of the input directory including transformed Version 5
.groovyscript files with changes for affected imports -
A backup copy of the original input directory
Example
Input for migration:
-
A directory called
myScriptswhich contains:-
A Version 5 script file called
myScriptA.groovy(with Version 5 imports to migrate)
-
Output of migration:
-
A directory called
myScriptswhich contains:-
A transformed copy of the input Version 5 script file
myScriptA.groovy(with migrated Version 6 imports)
-
-
A backup directory called
myScripts_legacy_backupwhich contains:-
A copy of the input directory (see
myScripts)
-