DEV Community

Cover image for Git with Android Studio
Shahab Alam
Shahab Alam

Posted on

Git with Android Studio

Introduction

In this Articles i am going to tell you how you can easily minimize your work by integrating Version Control System with the Android Studio in few simple steps.

Setup

GIT Integration with Android Studio

  • Open non-Git project on Android Studio.
  • First Test Git Configured
  • Settings > Version Control > Git.
  • Now press Test Button (It will show you Git Version installed).
    Add Account

  • Settings > Version Control > Github.

  • If it’s showing error try this.

  • Settings > Version Control > Git.

  • File > new > Project from VC > Github > give Token.

  • Steps for Creating Repository

Add

  • VCS > Import into VC > Create Git Repository. (All Files will become brown)
  • Select Your Project Folder OR Click On (Android Icon) Project Directory.
  • Now Select your Project folder in left Project section.
  • VCS > GIT > Add (ctrl + alt + A) (All files will turn green).

Commit

  • In Tool Bar, Click purple arrow button (commit) (ctrl + k)
  • Unselect those files whome u don’t want to commit
  • Give commit msg.
  • press commit button
    .
    Push

  • Now In Tool Bar, Press push button (Green Arrow) (ctrl + shift + k)

  • Create repo in Github, copy the URL

  • Come to A.S , Press on Define Remote

  • Paste in the URL press OK.

  • Press Push button.


Git In Android Studio

Image description

Android Studio Toolbar with Git commands

Image description

Details about Git in Android Studio

  • Press (Alt + 9)

Image description

Log Screen with plenty of options

Image description

Github Link https://github.com/IamShahabAlam/VCS-with-Android-Studio


CREDITS

Shahab Alam

Follow Here

Github

Facebook

Twitter

DEV

BuyMeACoffee

πŸ’™ Fluttering

Top comments (0)