![](/cvo_files/imgs_sap_abap/logos/logo_cvo_academy_it.png)
✒️SAP Fiori La conexión al GitHub mediante la terminal en el BAS
SAP Fiori La conexión al GitHub mediante la terminal en el BAS
![SAP Fiori La conexión al GitHub mediante la terminal en el BAS SAP Fiori La conexión al GitHub mediante la terminal en el BAS](https://www.cvosoft.com/cvo_files/imgs_sap_abap/og-images/381.jpg)
1 | Git Version in BAS
Git provides a tool called git config, which allows us to get and set configuration variables that control Git's behavior and appearance. One of the first steps is to configure your username and email address, as Git uses this information to label your commits. This information becomes a permanent part of any commits you make.
You only need to set this once using the --global option, as Git will then use it for all repositories on that system. If you need to override this information for a specific project, you can run the command without --global when inside that project.
2 | Global Configurations
The git config command allows us to configure basic repository settings such as our username and email, which are used to identify our commits.
To globally set your GitHub email and username in Business Application Studio (BAS), use the following commands:
git config --global user.email "example@gmail.com"
git config --global user.name "Name Surname"
Remote repositories (origin) are hosted on servers like GitLab, GitHub, or personal servers. The local repository on our machine is stored in a .git subdirectory containing all necessary files.
Next, we initialize our local repository in Business Application Studio. Using the terminal in SAP BAS, we initialize Git with the command git init, as shown below.
git init
3 | Initializing Remote Repository
The git init command creates a local repository in your project folder. It creates a hidden folder named .git to store all repository information.
To set the remote origin URL, use the command:
git remote add origin https://github.com/paht1/repository.git
You can find the remote repository URL on GitHub by clicking on the "Code" button.
4 | Adding Changes to Local Repository
The git status command helps us understand the current state of files in the repository—whether they are untracked, modified, or staged for commit.
To add changes to the staging area (preparing them for a commit), use:
git add "filename"git add . // All files
This command stages all changes. Check the status again with git status -s to ensure your changes are staged correctly.
To commit changes to the local repository, use:
git commit -m "commit message"
This command captures a snapshot of the changes you've staged (in the HEAD), but they are not yet pushed to the remote repository.
5 | Pushing Changes to Remote Repository
The git push command is used to publish local changes to a remote repository (like GitHub, GitLab, or Bitbucket).
git push origin "branchName"
This command pushes committed changes to the master branch of the remote repository. You may need to provide your GitHub username and token.
To generate a token for GitHub, navigate to your repository's settings and find the developer settings to generate a personal access token.
 
 
 
Sobre el autor
Publicación académica de Jaime Eduardo Gomez Arango, en su ámbito de estudios para la Carrera Consultor en SAP Fiori.
Jaime Eduardo Gomez Arango
Profesión: Ingeniero de Sistemas y Computación - España - Legajo: SW34C
✒️Autor de: 149 Publicaciones Académicas
🎓Cursando Actualmente: Consultor en SAP Fiori
🎓Egresado de los módulos:
Disponibilidad Laboral: FullTime
Presentación:
Ingeniero de sistemas y computación con 8 años de experiencia el desarrollo frontend & backend (react/node) y en cloud (aws), actualmente desarrollando habilidades en sap btp, ui5, abap y fiori.
Certificación Académica de Jaime Gomez