Integrate RPGLE from GitHub to iSeries (IBM i)

We are looking at using Git for all our sources. We have different languages (PHP, SQL, RPGLE, JavaScript, etc), and want to try to centralize the source locations. Also, Git offers a plethora of other advantages over the iSeries based SCM.

Getting the sources to Git is fairly straight forward, what I am struggling with is how to move the code from the Git repos to the iSeries.

We use RDi for our IDE, and I have installed the eGit plugin, but I am struggling on how to move the modified sources from my local PC to the iSeries (developer's personal libraries).

Has any one done this? Can you assist me in getting this setup running?


  • OK, I think I got this solved. Here is what I did:

    Install eGit

    Projects: To get this working, you will need to use projects. This part will be a slight learning curve, but it is really easy once you get the hang of it.

    Configure I Projects: We do not want line numbers and dates (causes errors on push/pulls).
    Navigate to Window > Preferences > I Projects Click ‘Remove sequence number and date fields on download’ Click ‘Enable add and remove sequence number actions’

    Create iSeries Project: Click File > New > Project Search for IBM Select the IBM I Project Click Next Name the project Click Next Select your connection to your remote server Select an associated Library (your PD lib is best) Click finish

    You should see a project in the Project explorer.

    Navigate to the Remote System Explorer Create an object filter for your Q* source files In the context of the filter, right click and select ‘Add to I Project’

    Now you should have the entire Qblah source file in the project

    Create Git Project Right click in the project explorer and select import. (May need to pick Import > Import) Type Git Select Projects from Git Click Next

    Here you can use an existing local checkout, or clone a new repo.
    Select clone URI Click next Enter the protocol/URI (just like in the wiki you visited earlier) Select branch(s) you want to import (recommend Master) Click Next Select destination folder Click Next Make sure ‘Import as a general project’ and click next Name your project (Recommend Git-repoName) Click finish

    You should now see two projects listed.

    Editing You can select the source and edit in the Git project. It will open the correct lpex editor and you are good to go.

    Sending to iSeries This is where things get a bit tricky.
    When it is time to send to the iSeries and compile, right click on the modified source in the Git repo Select Copy Right click on the appropriate Q* in your IBM project source file and select paste

    Next go to the remote reconciler tab Right click on the source or file and select ‘push to’, then select the remote entry

    BAM! Code is on the iSeries, ready for compilation.

    Commit back to Git In the Git project, right click and select Team > Commit. Select/de-select the desired changed sources Enter message Click commit (local commit only) or commit and push (commit to remote repo)

    Done! Now you can start importing the iSeries based code to Git!