Setting up an SCM repository

When refactoring COBOL applications into new COBOL services for transformation, use an SCM system, like Git, to store the COBOL source code, copybooks, DDLs, and other related files. This makes it easier to get the COBOL code ready for transformation and to provide a good mechanism to review the code before you hand the service over to a Java developer to do the transformation.

  1. Create a repository and give access to your COBOL developers to commit changes, make pull requests, and approve changes.

  2. Create folder structures for the repository to enable easier integration with the preparation stage of transformation.
    • Make sure that all COBOL programs are in a single folder directory tree structure (meaning they can also be in sub-directories under that single top-level directory).

    • Make sure that system copybooks and referenced COBOL copybooks are in the repository, but in a separate location from the COBOL programs. Place any system copybooks in a folder named copybooks. Other copybooks that are explicitly referenced in the COBOL source can be located in any folder, including the copybooks folder, but must not be in the same folder as the COBOL programs.

    • Make sure that all table definitions used by the business service to be transformed are in a ddl folder.

    • Make sure that all database descriptions are in a DBD folder.

    • Make sure that all program specification blocks are in a PSB folder.

    • Make sure that all transaction to program definitions are in a TRAN folder.

    Note: If you are using Z Refactoring Assistant to generate services, the related PSB and DBD files are retrieved for you.

    Here is an example of a repository structure:

    • COBOL source: MyRepository/cobol/
    • System copybooks: MyRepository/copybooks/
    • Other copybooks: MyRepository/othercopybooks/
    • DDL files: MyRepository/ddl/
    • IMS-related files: MyRepository/DBD/ MyRepository/PSB/ MyRepository/TRAN/
  3. Finally, give your Java™ developers access to clone the repository but not to make changes (assuming you want to store your Java code in a separate repository).