How to integrate Android Studio and Github

ANDROID STUDIO ANDROID GITHUB

Git is a distributed version control system and a source code management system designed and developed by Linus Torvalds.There are many types of source control management (SCM) softwares available in the market, but we will use Git because it is free, open source and easy integrated with Android Studio.In this blog, we will learn how to integrate Github with Android Studio.Let's started with Github!

Generic placeholder image

Getting Started

Let's signup and create a Github account in www.github.com


Install on System

Download git from https://git-scm.com/downloads and install it on your system.


Configure Git

  1. Open Android Studio and go to File > Settings > Version Control > Git
  2. Press Test button to see if Path to Git executables working or not.If everything goes correct you will see the successful message else navigate to git.exe file and press Test button again. Generic placeholder image

  3. Now, go to File > Settings > Github and enter your email and password to login into Github account. Generic placeholder image

  4. Go to VCS > Import into Version Control > Share Project on Github and enter repository name,description then press Share button. Generic placeholder image

  5. Now you will see next window for add files for initial commit.Check all files and press OK Generic placeholder image

  6. If everything goes correct you will see successful message showing Successfully shared project on GitHub. Generic placeholder image

  7. You can see project on Github by clicking on the link provided in that message.


Making Git Add and Commit

When we change something in project we have to make Add and Commit Git in Android Studio.

  1. First of all go to VCS>Git>Add to add file for staging.
  2. You will see your file label color will be changes.
  3. Now to commit final changes navigate to VCS>Git>Commit File Generic placeholder image

  4. You can see the commit log in Version Control tab at bottom of Android Studio.


Conclusion

It is very easy to perform Git operations with Android Studio.Android Studio make it easier to collaborate with other developers.

Gurjit Singh

Hey there! I'm an experienced Android developer and a geek interested in the newest technologies and trends.