# Git operations: what Talend Studio does behind the scenes

When working on a Git managed project, you can carry out various Git operations on the branches of your projects. The following table outlines how Talend Studio interacts with GitHub when you carry out Git related operations, and gives the equivalent Git commands corresponding to the Talend Studio actions.

* Available in:
* Big Data
* Big Data Platform
* Cloud API Services Platform
* Cloud Big Data
* Cloud Big Data Platform
* Cloud Data Fabric
* Cloud Data Integration
* Cloud Data Management Platform
* Data Fabric
* Data Integration
* Data Management Platform
* Data Services Platform
* ESB
* Qlik Cloud Enterprise Edition
* Qlik Talend Cloud Enterprise Edition
* Qlik Talend Cloud Premium Edition
* Real-Time Big Data Platform

## Talend Studio actions and equivalent Git commands

| User action in Talend Studio | Git commands performed by Talend Studio |
| --- | --- |
| Save or unlock a project item | <ol> <li>Gets Git                              status.<pre><code><pre><code><code>git status &lt;current-project-name&gt;</code></code></pre></code></pre></li> <li>Adds the modified files into                              index.<pre><code><pre><code><code>git add &lt;file&gt;</code></code></pre></code></pre></li> <li>Commits                              changes.<pre><code><pre><code><code>git commit -m &lt;commit-message&gt;</code></code></pre></code></pre></li> <li>Gets Git                              status.<pre><code><pre><code><code>git status &lt;current-project-name&gt;</code></code></pre></code></pre></li> </ol> |
| Select Push from the pull-down menu | <ol> <li>Gets Git status.<pre><code><pre><code><code>git status</code></code></pre></code></pre></li> <li>Stashes other                              changes.<pre><code><pre><code><code>git stash save -u &lt;internal-name&gt;</code></code></pre></code></pre></li> <li>Performs a pull.<pre><code><pre><code><code>git pull</code></code></pre></code></pre></li> <li>Performs a push.<pre><code><pre><code><code>git push</code></code></pre></code></pre></li> <li>Calls the JGit API to apply the stash.</li> <li>Drops the                              stash.<pre><code><pre><code><code>git stash drop &lt;stash-id&gt;</code></code></pre></code></pre></li> <li>Gets Git status.<pre><code><pre><code><code>git status</code></code></pre></code></pre></li> </ol> |
| Select Pull & Merge from the pull-down<br>menu | <ul> <li>If the local branch name is the same as the remote branch name:<ol> <li>Gets Git status.<div><pre><code><code>git status</code></code></pre></div></li> <li>Stashes other                                    changes.<div><pre><code><code>git stash save -u &lt;internal-name&gt;</code></code></pre></div></li> <li>Performs a pull.<div><pre><code><code>git pull</code></code></pre></div></li> <li>Calls the JGit API to apply the stash.</li> <li>Drops the                                    stash.<div><pre><code><code>git stash drop &lt;stash-id&gt;</code></code></pre></div></li> <li>Gets Git status.<div><pre><code><code>git status</code></code></pre></div></li> <li>Deletes local                                    tags.<div><pre><code><code>git tag -d &lt;tag-name&gt;</code></code></pre></div></li> <li>Fetches tags from the Git                                    server.<div><pre><code><code>git fetch -t -p</code></code></pre></div></li> </ol></li> <li>If the local branch name is different from the remote branch name,                              performs a                              merge.<div><pre><code><code>git merge &lt;selected-branch&gt;</code></code></pre></div></li> </ul> |
| Select New Branch from the pull-down menu | Creates a local branch based on the selected<br>branch.<br><br>```<br>git branch <new-branch-name> <base-branch-name><br>``` |
| Select Switch from the pull-down menu | <ol> <li>Gets Git status.<div><pre><code><code>git status</code></code></pre></div></li> <li>Re-logs on to the project on the selected branch.</li> </ol> |
| Select Check out as local from the All<br>branches dialog box | <ul> <li>If the local branch name is the same as the remote branch name,                              creates the local branch based on the selected branch and associates                              the new branch with the base                              branch.<div><pre><code><code>git branch &lt;new-branch-name&gt; &lt;base-branch-name&gt; --track</code></code></pre></div></li> <li>If the local branch name is different from the remote branch name,                              creates the local branch based on the selected                              branch.<div><pre><code><code>git branch &lt;new-branch-name&gt; &lt;base-branch-name&gt;</code></code></pre></div></li> </ul> |
| Select Add Tag from the pull-down menu | <ol> <li>Deletes local                              tags.<div><pre><code><code>git tag -d &lt;tag-name&gt;</code></code></pre></div></li> <li>Fetches tags from the Git                              server.<div><pre><code><code>git fetch -t -p</code></code></pre></div></li> <li>Creates the tag.<div><pre><code><code>git tag &lt;tag-name&gt;</code></code></pre></div></li> <li>Deletes local                              tags.<div><pre><code><code>git tag -d &lt;tag-name&gt;</code></code></pre></div></li> <li>Fetches tags from the Git                              server.<div><pre><code><code>git fetch -t -p</code></code></pre></div></li> </ol> |