code: public void prepareUpdateStep5() {
  
          if (isInitialized()) {
              try {
                  String fileName = getWebAppRfsPath() + FOLDER_UPDATE + "cmsupdate";
                  // read the file
                  FileInputStream fis = new FileInputStream(fileName + CmsConfigurationManager.POSTFIX_ORI);
                  String script = "";
                  int readChar = fis.read();
                  while (readChar > -1) {
                      script += (char)readChar;
                      readChar = fis.read();
                  }
                  fis.close();
                  // substitute macros
                  script = CmsStringUtil.substitute(script, C_ADMIN_USER, getAdminUser());
                  script = CmsStringUtil.substitute(script, C_ADMIN_PWD, getAdminPwd());
                  script = CmsStringUtil.substitute(script, C_UPDATE_PROJECT, getUpdateProject());
                  script = CmsStringUtil.substitute(script, C_UPDATE_SITE, getUpdateSite());
                  script = CmsStringUtil.substitute(script, C_ADMIN_GROUP, getAdminGroup());
                  // write the new script
                  FileOutputStream fos = new FileOutputStream(fileName + ".txt");
                  fos.write(script.getBytes());
                  fos.close();
              } catch (IOException e) {
                  e.printStackTrace();
                  throw new RuntimeException(e);
              }
          }
      }
docs: Prepares step 5 of the update wizard.<p>