Using GIT in Workflow Development


It is always a good idea to first test your software, or in this case workflows, before you integrate them into your live-system. Not doing this can result in malfunctioning workflows, in some cases even permanent loss of data or other irreparable damage to your system. In the following section we will give you a nice and easy way to develop workflows in the different stages of development (i.e. development, test-phase1, test-phase2, production), synchronize them and cheery-pick selected lines from one stage to the other, via Git. Git is a free software, for almost all plattforms (Windows, MacOS, Linux etc.), which was developped for excactly this purpose. In this little showcase we used Git Extensions the downloadable Git GUI. It is not necessary to download and use the Git Extension. Everything that is going to be shown in the following sections could be just as well done via Git in the command prompt.


The goal of this showcase is to show in detail how to create an architecture that enables you to create and manage different stages of development for your workflows. The following steps are going to be described in detail after some background information about some aspects of Git.

  1. Create a development directory
  2. Create its contents (wfconfing & script)
  3. Initialise Git
  4. Commit the contents of your directory to Git
  5. Create a branch
  6. Create a repository directory
  7. Add the repository to the development directory
  8. Push the contents of the development directory
  9. Copy of the development directory
  10. Rename and change contents of the copy
  11. Create branch of the renamed copy
  12. Push the contents of the copy
  13. Make a change in the development directory
  14. Commit and Push those changes
  15. Pull those changes from the renamed copy branch
  16. Cherry pick the changes you want
  17. Commit and Push those changes
  18. Pull (development)

Creating a Git repository

A repository exisits in two forms in Git:

  1. Personal repository
  2. Central repository

The personal repository is selected for every one of the desired devolpment stages to later link them to a central repository. The central repository functions as the administrator of all the personal repositories. It is the place where the data of the personal repositories is collected.

The first step is creating a folder for the first stage of development. After that you need to create the content of your workflow which consits of at least the workflow-config and one script. At this point you want to initialise this folder as a Git personal repository. To do this right-click at an empty space of the choosen folder and select "GitExt Create new repository...". The first field is the directory, which in the most cases can be left as it is. The second field is the option of the presonal and central repository. Choose personal, since this is your folder for the first stage of development.

The next steps are committing the contents of your development folder via Git and creating a branch. A commit is a snapshot of the current state your data is in a the moment

  1. Commit your files by right-clicking in the development folder and click on "GitExt Commit..." .
  2. Select all the files you want to comming and enter a "Commit message".
  3. Click on the commit button.

Now the data is commited via Git.

After committing the data you need to create a branch. A branch is a pointer to a commit. Each stage of development should have their own branch. To create a branch follow these steps.

  1. Open "Git Browse" by right-clicking somewhere in the development folder.
  2. Right-click on the first entry and select create new branch.
  3. Name the branch in a way that makes it easily distinguishable which stage of development this is.

Now since you created a branch you need to create a central repository. The central repository can be on a server or any other location you choose.

  1. Create a new folder and call it for exemple "Repository".
  2. Open the folder right-click and select "GitExt Create new repository...".
  3. Select "Central repository"

You have created your central repository.

Now you need to link the central repository to your exisiting development stage and the corresponding branch.

  1. Go into "Git Browse" GUI select your branch and
  2. Click on Repository --> Remote repositories
  3. Choose a name of your liking
  4. Enter the URL of the created central repository.

After linking the branch with the central repository you need to "push" the contets of the branch to the central repository. This is done by selecting the blue arrow in the Git browse that point up.

Creating the different development stages

The following steps should be repeated for every stage of development you want to set up.

  1. Copy the folder of your already established devlopment stage.

It is very important that you do this outside of your workflow root directory. If you do not do this kenaflow

will run into errors since it recognizes the "new" workflow and runs it. Due to the fact that both (the original and the copy) have the same ID kenaflow runs into an problem and throws an error for one of these workflows. To prevent this copy the folder outside ot the root directory and change the ID and all the other necessary entries.

The advantage of copying the folder is that the underlying structure (the connection of the personal and central repository) is maintained.

  1. Create a new branch for the newly created development stage in the Git browse.
  2. Push the contents of the new branch.