code: protected void updateModule(String moduleName, String importFile, I_CmsReport report) throws Exception {
  
          String fileName = getModuleFolder() + importFile;
  
          report.println(
              Messages.get().container(Messages.RPT_BEGIN_UPDATE_MODULE_1, moduleName),
              I_CmsReport.FORMAT_HEADLINE);
          removeModule(moduleName, report);
          OpenCms.getPublishManager().stopPublishing();
          OpenCms.getPublishManager().startPublishing();
          OpenCms.getPublishManager().waitWhileRunning();
          OpenCms.getImportExportManager().importData(m_cms, report, new CmsImportParameters(fileName, "/", true));
          report.println(
              Messages.get().container(Messages.RPT_END_UPDATE_MODULE_1, moduleName),
              I_CmsReport.FORMAT_HEADLINE);
          OpenCms.getPublishManager().stopPublishing();
          OpenCms.getPublishManager().startPublishing();
          OpenCms.getPublishManager().waitWhileRunning();
      }
docs: Imports a module (zipfile) from the default module directory,
  creating a temporary project for this.<p>
  
  @param moduleName the name of the module to replace
  @param importFile the name of the import .zip file located in the update module directory
  @param report the shell report to write the output
  
  @throws Exception if something goes wrong
  
  @see org.opencms.importexport.CmsImportExportManager#importData(org.opencms.file.CmsObject, I_CmsReport, org.opencms.importexport.CmsImportParameters)