PushOk Installation and Configuration
To get Magic xpa to work with Git via PushOk plugin, you need to install the PushOk Git SCC plug-in. You can download it from: http://www.pushok.com/software/download.html?idprogram=8.
PushOk Prerequisites
After installation, check the registry and verify that Git is defined as the Source Code Control Provider. Refer the Registry Definitions help topic of Magic xpa help at: Home > Reference Guide > Version Control > Working with Version Control.

PushOk Registration
When the GITSCC provider is defined in the registry and you run Magic xpa Studio for the first time, you will see the PushOk registration wizard. Follow the instructions provided by the PushOk registration process in the wizard.

PushOk registration should be completed once you obtain the valid license key from PushOk Software. After successful registration, start the Magic xpa studio and you will get the Git plug-in option as shown below:

On the Magic xpa main menu, click on File > Version Control > Git Plug-in option. It opens the Git plug-in, where you can generally perform the local and remote operations on the repository.


|
Recently, Git engineering team announced the deprecation of several weak cryptographic standards. On February 22, 2018 they have permanently disabled TLSv1/TLSv1.1. This applies to all HTTPS connections, including web, API, and Git connections to https://github.com and https://api.github.com. From now onwards, Github and api.github will not support TLSV1 to https connections.
Check out link recent updates on Git https://githubengineering.com/crypto-removal-notice/. Pushok bundles old version of Git executables (version 1.7.0.2). While using this version, you will get an error "error: 1407742E: SSL routines: SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version while accessing". You will have to install an upgraded version of Git, preferably 2.0 or later (https://git-scm.com/download/win) and update the plug-in settings for the environment variables from new Git install directory.
|

Change the highlighted environment variables as per below:
-
In Magic xpa Studio open Plug-in settings option from the Git Plug-in.
-
Navigate to the Environment section.
-
Define the following:
· Git executable: <Git Install Dir>\bin\git.exe
· SSH askpass utility: <Git Install Dir>\mingw64\libexec\git-core\git-gui--askpass
· SSH executable: <Git Install Dir>\bin\git.exe
Configuring Multiple Developers Support
When working with Git, the Check-out of an object is done on the local repository and not on the remote repository. This way, multiple developers can work on the same object such as a program. To identify the changes that each developer made distinctly, you need to configure Magic xpa to provide a distinguished ID for the representation of internal objects in the source files.
To support multiple developers working on the same program, you need to:
-
Insert a line SpecialMultipleCheckout=Y to the [MAGIC_SPECIALS] section in the Magic.ini file.
-
For each developer, define a unique value in the Version Control ID environment setting. This setting adds a prefix to the current ISN number of objects in the source files. The purpose of this setting is to provide a distinguished ID for the representation of internal objects in the source files. This provides the proper infrastructure for third party apps, such as compare and merge tools.

|
The RM Converter utility does not support applications that use this setting. So, if you have Record Main Compatible logic units in your application, you will not be able to use the RM Converter utility after setting the Version Control ID environment setting.
|
Preparing the Source Files
The Merge tool supports source files saved in Magic xpa 3.1 or later. Source files saved in Magic xpa V2.x are still in the old structure.
If your project was developed or was upgraded to a version prior to Magic xpa 3.1, you should update the source files before adding them to the remote repository. This can be done by selecting the Update Project Source Files entry from the Options menu.
Configuring Magic Merge tool
When multiple developers are working on the same object, there might be conflicts. For example, if two users changed the name of a variable. In such a conflicting case, the Merge tool is launched.
Since the Magic xpa source files are different than code files, you are recommended to use the Magic Merge tool for merging. You can define it in PushOk as follows:
-
Open the Configure plug-in utility from the Start\PushOk Software\GitSCC windows menu or from the Magic xpa Studio by opening the Plug-in changes option from the Git Plug-in.
-
Navigate to the Merge Tool section.
-
Define the following:
· Default merge tool = External tool
· External merge tool = Magic Merge tool
· External merge tool arguments = "%THEIRS%" "%MINE%" "%BASE%" "%MERGED%"

Defining SSL Certificate for Git Repository
You now need to define your SSL certificate for the Git repository. You can do this by either using the command prompt or by updating the Git config file directly. You can use your SSL certificate, or a default certificate that comes with PushOk Git plug-in, or not use any certificate at all.
-
Open the command prompt (for example: cmd) in Administrator mode.
-
Navigate to the PushOk Git plug-in (for example: cd Program Files (x86)\PushOk Software\GITSCC\GIT\bin\).
-
Run one of the following commands as per the requirement:
· No use of SSL certificate: git config --system http.sslverify false.
For example, Program Files (x86)\PushOk Software\GITSCC\GIT\bin\> git config --system http.sslverify false
· Use of your SSL certificate: git config --system http.sslcainfo "C:\mypath\my-ca-bundle.crt"
· Use of the Default certificate: git config --system http.sslcainfo "C:\Program Files (x86)\PushOk Software\GITSCC\GIT\bin\curl-ca-bundle.crt"

|
To verify that your SSL certificate was defined (or to define it without using the command prompt), navigate to the etc folder under the Git plug-in folder (usually C:\Program Files (x86)\PushOk Software\GITSCC\GIT\bin\etc) and open the gitconfig file in a text editor. You will see that it includes the following lines:
[http]
sslverify = false
OR
[http]
sslcainfo = "C:\\Program Files (x86)\\PushOk Software\\GITSCC\\GIT\\bin\\curl-ca-bundle.crt"
|
Introduction to Git
PushOk Git Plugin
Creating Remote Git Repository
Branching with Git
Merging with Magic Merge Tool
Working with Source Tree
Connecting Magic xpa with Git Repository