How to Sync Red Hat JBoss BPM Suite Processes to a Central Git Repository

We have encountered several problems with Red Hat JBoss BPM Suite during our process development. One of them was losing the processes that we have developed in our local BPM Suite. In order to make sure you never lose your process code, you can sync your local Red Hat BPM Suite repository with a remote repository manager like Bitbucket. Syncing to a central repository also enables multiple developers working on the same BPM project.

Here are the steps you should follow to sync your Red Hat BPM processes to a remote git repo in Bitbucket:

Create a repository in Bitbucket to sync the source code from BPM Suite

Create a new repository in BPM Suite
Go to c/DevEnv/EAP-7.0.0/bin/.niogit/<REPO_NAME_IN_BPMSUITE>.git

Add remote repository (repository you created in Bitbucket) to your git repo created in BPM suite
git remote add origin http://<Username>:<Password>@bitbucket.defence.local:7990/scm/tybs/<REPO_NAME_IN_BITBUCKET>.git

Browse to “hooks” folder (c/DevEnv/EAP-7.0.0/bin/.niogit/<REPO_NAME_IN_BPMSUITE>.git/hooks)
Add a file named “post-commit” with no extension

Add the below contents to this file:
git push origin master

Add git bin (C:\Program Files\Git\bin) to “system path”

Install Cygwin
Add Cygwin to “system path” (C:\cygwin64\bin)

Restart windows

This procedure is for Windows 10, but philosophy applies to other operating systems too. Just change the corresponding paths and if you are on Linux you won’t need Cygwin.

Hope this helps.
Good Luck,