Working with Git commands can sometimes be exhausting. With GitHub desktop, we could perform these same commands without relying on the command line or a web browser. GitHub Desktop simplifies the process of working with GitHub quickly and easily. Let's get into it!
GitHub Desktop is an open-source application that lets us interact with GitHub via a graphic user interface (GUI) instead of relying on a command line.
GitHub Desktop is supported on the following operating systems:
Windows 7 64-bit or later
Mac OS 10.12 or later
If you do not have a GitHub account, create a GitHub account here. To configure GitHub Desktop, click "File" in the navbar and then "Options." To access our repositories directly from GitHub, click the "Sign in" button.
Note: When we click the "Sign in" button, GitHub Desktop will instantly redirect the user to a browser window where user can input your GitHub account credentials. After a successful sign-in, the browser will prompt the user to return to the GitHub Desktop app.
To create a new repository, click "File" on the navbar and select "Create a New Repository."
What we see happening in the image above is:
Repository name: This is where you specify the name of the repository you want for your project.
Description: A brief and straightforward explanation of what the repository is for.
Local path: You can locate all created or copied repositories here. If you want to change the location, click “Choose” and select your preferred path.
Initialize with a README: A README provides an overview of what the repository contains.
Git ignore: Git ignore is a feature of Git that allows us to specify files or directories that Git should ignore when tracking changes in our project.
Cloning a repository can easily be done using the URL tab in File:
To clone a repository, follow these simple steps:
To use the URL option, get the link to the repository or the GitHub username and repository.
Paste the copied link into the field and click "Clone."
Once we have made changes to our project, we proceed to record those changes in our remote repository by committing them. In the image below, we can see the new changes we made, highlighted in green, and the changes we removed, highlighted in red.
Before pushing the changes, we provide a short explanation in the input box at the lower left corner.
In the repository bar, click "Push" to push your local changes to the remote repository.
And that's it! Get started with GitHub desktop using this simple guide.