Friday, 16 December 2022

MTA project Integration with Git in Web IDE: HANA XSA

Today I am going to discuss about the MTA project Integration with GitHub as a source control in Web IDE: HANA XSA.

Before perform the steps, I want everybody know the flow and keep the diagram so that you have a clear concept on this migration –

SAP Web IDE, SAP HANA XSA, SAP HANA Exam, SAP HANA Career, SAP HANA Skills, SAP HANA Job

SAP Web IDE, SAP HANA XSA, SAP HANA Exam, SAP HANA Career, SAP HANA Skills, SAP HANA Job

Integration Steps :


1. Open your project from Web IDE : If the project is not there please create it by importing the file or create it from a MTA project template. You can Clone it from the existing project from a git repository also.

SAP Web IDE, SAP HANA XSA, SAP HANA Exam, SAP HANA Career, SAP HANA Skills, SAP HANA Job

SAP Web IDE, SAP HANA XSA, SAP HANA Exam, SAP HANA Career, SAP HANA Skills, SAP HANA Job

1. Create a Local repository and name it suitable with your project :

SAP Web IDE, SAP HANA XSA, SAP HANA Exam, SAP HANA Career, SAP HANA Skills, SAP HANA Job

2. Configure the remote repository for the local repository :

A. Before you configure the remote repository please log into GitHub using the below URL, create an account and create a repository.

https://github.com/login

Copy the repository URL like below. If you working on direct Master node copy the master node URL. It is preferable to create a branch node and working on it, they you need to copy the URL of branch node.

SAP Web IDE, SAP HANA XSA, SAP HANA Exam, SAP HANA Career, SAP HANA Skills, SAP HANA Job

B. In web IDE , right click on your project and click Git -> Set Remote and  in the Configure Git Repository dialog box, enter your GitHub  repository’s URL.

SAP Web IDE, SAP HANA XSA, SAP HANA Exam, SAP HANA Career, SAP HANA Skills, SAP HANA Job

SAP Web IDE, SAP HANA XSA, SAP HANA Exam, SAP HANA Career, SAP HANA Skills, SAP HANA Job

3. Configure Stage Layer : 

It will automatically fetch the Master node and the branches of the remote repository in your Web IDE.

To make sure  the files are staged inside the Git Panel select the checkbox “Stage all”,

Put the commit description and click the commit button.

SAP Web IDE, SAP HANA XSA, SAP HANA Exam, SAP HANA Career, SAP HANA Skills, SAP HANA Job

You can do also using command from terminal –

git init
git add -A
git commit -m “Test Commit"

4. Pull Code from GitHub.

You can pull the data from the GitHub remote repository by either pull or fetch Data. I am going to tell you what is the difference between pull and fetch. Fetch do not change the local dev space artifacts. you can only show the committed changes in remote repo. Better to go with Pull.

SAP Web IDE, SAP HANA XSA, SAP HANA Exam, SAP HANA Career, SAP HANA Skills, SAP HANA Job

SAP Web IDE, SAP HANA XSA, SAP HANA Exam, SAP HANA Career, SAP HANA Skills, SAP HANA Job

You can do pull from Terminal as well.

Pull
git remote add projectm  https://xxxxxx.git
git pull projectm
git clone <repository url>
git fetch
git fetch -all
git checkout Branch1
git clone —-branch Branch1 <remote-repo-url>
git branch –Branch1 
$ git checkout -t projectm/Branch1

5.  Push Code to GitHub and check the changes in GitHub.

Before Push do Pull from remote to update your code artifacts repeating step 4.

Then Push –

SAP Web IDE, SAP HANA XSA, SAP HANA Exam, SAP HANA Career, SAP HANA Skills, SAP HANA Job

You can do pull from Terminal as well.

Push
git remote add projectm  https://xxxxxx.git
git push -u projectm BranchL :Branch1

No comments:

Post a Comment