This document should show a user how to setup the ERP5Forge business template to be able to use git inside ERP5.
Please note that this document doesn't concern Products (or ERP5 Core) development.
Table of Contents
Start by installing the ERP5Forge business template (bt5). See How To Install Business Templates in case you don't know how to work with business templates.
To be able to connect from within ERP5 to the repository you'll first need to update your preferences. Navigate to your preferences:
My Favorites > Preferences
and locate the VCS tab which has been added when installing ERP5Forge.
The Working Copies Preference needs to contain the location of the working copies of your "git" repositories and is required to use git from within ERP5. To set this up go to the webrunner interface of the runner your current ERP5 instance is installed on.
Open a terminal. You should be in the "working" directory of your webrunner, containing the instance, software, and project directories. If you run
You should see something like :
You now need to find the correct slappart containing the zope instance. To do so, try entering:
Your zope instance is in the slappart which contains a zope-0 binary in its etc/run folder.
Alternatively you can pick any service PID running on the services tab and grep it using ps -edf | grep 30426. The result should also point you to the correct software release.
ps -edf | grep 30426
Navigate to your instance erp5shared folder using:
cd instance/slappartX/srv/erp5shared/ # slappartX being the slappart found previously
Clone ERP5's repository here, and eventually your project's custom repository :
git clone https://lab.nexedi.com/nexedi/erp5.git
You will have a fresh erp5 repository containing 2 sub-directories where BT5s can be found : erp5/bt5, and erp5/product/ERP5/bootstrap. You can retrieve their exact paths by cd into them and then running pwd.
The final step is to add these BT5 paths to the working copies field inside ERP5. Include your email address and save.
If this is a newly created BT5, don't forget to create a working copy. See How To Commit New Business Template
If you now navigate back to business templates and clone an existing template you should have the Git tab available to commit the changes you have made.
Please refer to How To Use ERP5 Subversion for learning how to work with this buinesss template and commit your code to a repository.
If the Git tab does not show up, you can check any of the following:
Check the beginning of this tutorial
Make sure your preferences are active. For this, check the Active property of your preferences :