Engineering Workflow Management (EWM) SCM Utils / Rational Team Concert (RTC) SCM Utils - A collection of utility commands providing custom operations on EWM/RTC data related to a file system and EWM SCM.
- A group of SCM operations support exporting SCM content. The export operation stores the current latest component file content as zip files and the workspace and component structure as a JSON file. The exported component data can be randomized, obfuscated or left unchanged. The data can be imported into the same or another repository using related commands.
- Another group of operations helps analyzing SCM Workspaces, Streams and sandboxes and generate sizing statistics. Includdes a framework that allows to implement own commands.
- A third group allows to share and update data in components in a stream as well as download component data into the local file system. A temporary repository workspace will be used for upload. The local data will not be a sandbox connected to Jazz SCM but remain disconnected.
SCMUtils Version: 2.7
This software is licensed under the MIT license which is as follows: MIT License
All content is provided "as is" and without warranties. I am not responsible for any harm or damage caused by this material to you, your computer, your software, or anything else.
This software is open source and not supported by IBM. Do not open support cases at IBM against this software. If you have questions open an issue here and/or ask a question in the Jazz.net Forum.
- The EWM SCM Utils require an up to date working Java 8.
- The EWM SCM Utils require the RTC/EWM Plain Java Client Libraries.
Download the Plain Java Client Libraries from the 'All Downloads' tab of the download page for your version of EWM. Unzip the Plain Java Client Libraries into a folder on your local disc for example C:\ELM702\PlainJavaAPI. The JAR files are supposed to be in this specific folder.
To run the EWM SCM Utils, edit the SCMUtils.bat or SCMUtils.sh and change the environment variables JAVA_HOME and PLAIN_JAVA to your Java JRE and the Plain Java Client Libraries you installed to your values e.g.
PLAIN_JAVA=C:\ELM702\PlainJavaAPI
-command commandName {[-parameter] [parameterValue]}
The source code ships start scripts, a batch file and a sell script, that can be used to launch the tool. Please note that long running operations on large sets of data can cause out of memory exceptions. The scripts have a built in option to set the heap size, consider increasing the value if you run into out of memory errors.
The tool requires the EWM/RTC Plain Java Client Libraries. https://github.com/jazz-community/ewm-scm-utils/blob/master/com.ibm.js.team.scm.supporttools/ReadMe%20-%20HowToRelease.txt explains how to release the tool.
Analyzes streams in a RTC SCM repository. Each stream is analyzed, the referenced components and the component substructure to provide metrics information such as number of folders, files, depth, content size and other information. The analysis data is stored in a set of Excel shets.
-command analyzeScmRepository
-url "https://<server>:port/<context>/"
-user <userId>
-password <password>
-command The command to execute.
-url The Public URI of the application.
-user The user ID of a user.
-password The password of the user.
-connectionOwnerScope "<processAreaName>{&<processAreaName>}"
-outputFolder <outputFolderPath>
-connectionOwnerScope Filter and analyze only the connections owned by the process areas in the scope
-outputFolder The folder where the resulting data is written.
-command analyzeScmRepository -url https://elm.example.com:9443/rm/ -user myadmin -password ****** -connectionOwnerScope "Project1 (Change Management)&Project2 (Change Management)/SCM Expert Team" -outputFolder "C:\Temp\ScmExport"
Analyses a folder and its substructure to provide metrics information such as number of folders, files, depth, content size and other information. The analysis data is stored in a set of Excel shets.
-command analyzeSandbox
-sandboxFolder <sandboxFolderPath>
-command The command to execute.
-sandboxFolder The folder to be analyzed.
-outputFolder <outputFolderPath>
-outputFolder The folder where the resulting data is written.
-command=analyzeSandbox -sandboxFolder="C:\Temp\ExampleSandbox" -outputFolder="C:\temp\AnalyzeSandboxReport"
Analyses a RTC SCM workspace connection, the referencecd components and the component substructure to provide metrics information such as number of folders, files, depth, content size and other information. The analysis data is stored in a set of Excel shets.
-command analyzeScmWorkspace
-url "https://<server>:port/<context>/"
-user <userId>
-password <password>
-workspaceConnection <workspaceNameOrId>
-command The command to execute.
-url The Public URI of the application.
-user The user ID of a user.
-password The password of the user.
-workspaceConnection The repository workspace to export.
-outputFolder <outputFolderPath>
-outputFolder The folder where the resulting data is written.
-command analyzeScmWorkspace -url "https://elm.example.com:9443/ccm/" -user myadmin -password ******* -workspaceConnection "JKE Banking Integration Stream Workspace" -outputFolder "C:\Temp\ScmAnalyzeWorkspace"
Exports the contents of a workspace (a repository workspace or stream) into a set of zip files. Exports the component hierarchy structure of the workspace into a JSON file. The structure, file- and folder names are preserved, the file content can be randomized.
-command exportScmWorkspace
-url "https://<server>:port/<context>/"
-user <userId>
-password <password>
-workspaceConnection <workspaceNameOrId>
-command The command to execute.
-url The Public URI of the application.
-user The user ID of a user.
-password The password of the user.
-outputFolder <outputFolderPath>
-exportmode <exportmode>
-outputFolder The folder where the resulting data is written.
-exportmode The mode to export the data. Available modes are: randomize, obfuscate, preserve. Default mode if parameter is omitted is: randomize
- Export mode randomize changes all bytes of the filecontent with random bytes.
- Export mode obfuscate replaces all lines in the files with lines of sample text of similar length, taken from the file CodeSampleInput.txt.
- Export mode preserve keeps the file content as it is.
-command exportScmWorkspace -url https://elm.example.com:9443/ccm/ -user ADMIN -password ****** -workspaceConnection "Debs JKE Banking Integration Stream Workspace" -outputFolder "C:\Temp\ScmExport"
Imports a repository workspace from export data conforming to the result of the command exportScmWorkspace. Creates a repository workspace and its components from a JSON file describing the workspace component hierarchy structure. Imports the folder and file content for each component from a zip file representing the component.
-command importScmWorkspace
-url "https://<server>:port/<context>/"
-user <userId>
-password <password>
-projectarea <project_area>
-workspaceConnection <workspaceNameOrId>
-inputFolder <inputFolderPath>
-command The command to execute.
-url The Public URI of the application.
-user The user ID of a user.
-password The password of the user.
-projectarea A project Area name, for the project area to import into.
-workspaceConnection The repository workspace to import..
-inputFolder The folder where the input information is expected to be. This is the folder and content created in the command exportScmWorkspace.
-componentNameModifier <modifier>
-reuseExistingWorkspace
-skipUploadingExistingComponents
-componentNameModifier A prefix to be added to component names to force creation of new components and support component name uniqueness.
-reuseExistingWorkspace If provided, an existing workspace is used and the configuration is overwritten by the import.
-skipUploadingExistingComponents If provided, components that already exist are not recreated and and no data is uploaded. This allows to recover and restart after a problem. e.g. rename the component that failed and restart the import to continue.
-command importScmWorkspace -url "https://elm.example.com:9443/ccm/" -user myadmin -password ******* -projectarea "JKE Banking (Change Management)" -workspaceConnection "Imported JKE Banking Stream Workspace" -inputFolder "C:\temp\ScmExport" -componentNameModifier="TestImport1_" -reuseExistingWorkspace -skipUploadingExistingComponents
Convertes the component ID's in an existing Load Rule File based on the mapping created for an import using the command importScmWorkspace.
-command convertLoadrule
-inputFolder <inputFolderPath>
-sourceLoadruleFile <sourceLoadRule>
-targetLoadruleFile <targetLoadRule>
-command The command to execute.
-inputFolder The folder where the input information is expected to be. This is the folder and content created in the command exportScmWorkspace. In addtion the command importScmWorkspace must have been ecxecuted using this folder creating the UUID mapping required.
-sourceLoadruleFile Full path and filename to an existing loadrule file that needs the source UUID's to be converted to the target UUID's.
-targetLoadruleFile Full path and filename of the resulting loadrule of the conversion.
-command convertLoadrule -inputFolder "C:\Temp\ScmExport" -sourceLoadruleFile "C:\Temp\example.loadrule" -targetLoadruleFile "C:\Temp\converted.loadrule"
Iterates a loadrule and modifies pathPrefix entries for sandboxRelativePath. The modification replaces all / by _ except for the first /. This creates a flat loadrule from a loadrule that has hierarcy.
-command flattenLoadrule
-sourceLoadruleFile <sourceLoadRule>
-targetLoadruleFile <targetLoadRule>
-sourceLoadruleFile Full path and filename to an existing loadrule file that needs the source UUID's to be converted to the target UUID's.
-targetLoadruleFile Full path and filename of the resulting loadrule of the conversion.
-command sourceLoadruleFile -"C:\Temp\example.loadrule" targetLoadruleFile -"C:\Temp\converted.loadrule"
Uploads a folder and its content as component to a stream and baselines the content. The folder name is used as the component name. The component is created if it does not yet exists. Ownership and visibility of the component is the project area. The component is added to the stream if it is not yet in it. All changes are contained in one change set.
When a build result UUID is provided as optional parameter the command will publish the URIs for the stream, the baseline and the component as external links to the build result.
-command uploadToStream
-url "https://<server>:port/<context>/"
-user <userId>
-password <password>
-projectarea <project_area>
-streamName <streame_name>
-inputFolder <inputFolder>
-command The command to execute.
-url The Public URI of the application.
-user The user ID of a user.
-password The password of the user.
-projectarea The name of the project area
-streamName The name of the stream to add the component if it is not already in it.
-inputFolder The path to the folder that is the source to upload.
-buildResultId <buildResultUUID>
-buildResultId The UUID of an existing build result.
-command uploadToStream -url https://clm.example.com:9443/ccm/ -user ADMIN -password ****** -projectarea "JKE Banking (Requirements Management)" -streamName "JKE Banking Integration Stream" -inputFolder "C:\Temp\ScmExport" -buildResultId _oS2f0A1iEeuxvceFG0DbZg
Downloads the content of a component selected by a baseline into a local file system folder. The component name is created as folder and the content of the component is loaded into that folder.
-command downloadComponentBaseline
-url "https://<server>:port/<context>/"
-user <userId>
-password <password>
-component <component_name>
-baseline <baseline_name>
-outputFolder <outputFolderPath>
-command The command to execute.
-url The Public URI of the application.
-user The user ID of a user.
-password The password of the user.
-component The name of the component.
-baseline The name of the baseline on the component.
-outputFolder The path to the folder that is the target of the download.
-command downloadComponentBaseline -url https://elm.example.com:9443/ccm/ -user ADMIN -password ****** -component "Test Component" -baseline "Baseline V2" -outputFolder "C:\Temp\ScmExport"