ibmi-brunch-learn

Announcement

Collapse
No announcement yet.

Source Control on Library

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Source Control on Library

    Hi everyone,

    Looking for some advice on setting up some way to help me track changes made to programs

    I have two libraries. One for production and one for test.
    Basically, I want to implement a way in test to help me keep track of changes made to programs and what changes.

    This way I can promote the right programs to production when needed.
    I am familiar with Git from working with it outside of the AS400 environment and it seems like the right solution, but I am struggling to set it up for this library.

    I know there is an easy set up with RDi, which I have used before at a previous company but I am limited at this new company and my programming environment at the moment just consists of ILEditor.

    Any guidance on setting up this in a simple way or any other alternative would be greatly appreciated

  • #2
    One common way to do Git with native IBMi source is to use RDi and iProjects.


    You can also use Subversion for native IBMi source with the help of SVNKIT.

    Comment


    • #3
      Thanks for the reply. I edited my post.

      I forgot to mention if there is a way to do Git without RDi because I my company isn't paying for that right now.
      My IDE right now just consists of the free tool ILEditor since I am the only developer here.

      Comment


      • #4
        Looking into your subversion solution now jtaylor___ thanks

        Comment


        • #5
          Liam Allen - the young genius behind ILEditor is also an expert on integrating git for IBM i - I suggest you contact him. I'll also point him to this conversation.

          Comment


          • #6
            JonBoy Thanks, thats a great suggestion, I will try to reach out to him

            Comment


            • #7
              I don't think ILEditor will help with Git, but it has to be way better than SEU.

              We've used the Subversion techniques outlined in those articles since shortly after they were published (2008). I hope all articles in the series are still available. The only criticism I had is that it uses RUNJVA which causes several JVM startups per commit. That works but just takes more time.

              Comment


              • #8
                You can use the git command line tools from PASE on IBM i (I do this all day every day). That way, it's not necessary for there to be any sort of support built-in to the editor, and you can use it with any editor you like.

                Just use yum to install git, then you can run git commands from QP2TERM, QShell, etc, just like any other platform.

                Comment


                • #9
                  The biggest sticking point is not the client but rather the source PFs. RDi get around this with iProjects and PC-side commits. The SVN article above describes shuffling the source thru IFS files. I have no doubt a similar process could be done with Git.

                  Comment


                  • #10
                    Hello

                    First, thanks for using ILEditor. If you have any feedback for it make sure to open an issue on the GitHub repo and I can take a look.

                    Second of all, the easiest way to start tracking your RPG source really is moving it to the IFS. Install git, setup a repo, move the source, start tracking it.

                    There is also iProjects which others have mentioned, but I am not a fan of that personally.

                    Comment


                    • #11
                      I think the iProjects method is promoted because too many people have reservations about moving their source.

                      Comment


                      • #12
                        Yes, you're right... one big problem with using git is the use of source PFs. But, it's not just because they are PFs, but also because of the way the source-pf paradigm makes you organize your code!

                        In a typical git project (and this is also true of Subversion, CVS, etc) you would have subdirectories where you put the code relevant to a given project. For example, it might contain a bunch of related programs and service programs, including CL programs, RPG programs, DDS or other display logic, all grouped according to that project. You check it out as a project, you commit it and/or push it back as a project of these related sources.

                        With source-pfs that isn't (usually) the case... you throw all RPG code for all projects together in one big huge source file. You throw all CL sources together, all DDS sources together, etc... What do you check in and check out in that case? I guess you could do the entire source of every program for a given language (e.g. the entire QRPGLESRC PF) but this would be rather inefficient... at least in the shops I work in, this could be thousands of source members, and its not very efficient to check out (or clone, pull, etc) all 5000 members when you only need to make changes to one program. Other shops I know use a single source file for all languages combined, which would be even bigger.

                        Moving all of the code to the IFS would not (by itself) solve the problem. You'd also have to reorganize it into appropriate projects that can be committed/pushed separately. To me, this is the bigger and more difficult part of changing how things are done.

                        But, it's definitely the way to go. No matter what editor or change management solution you end up with, it'll all work better if you organize things better and keep them in the IFS.

                        Comment

                        Working...
                        X