Skip to content

Latest commit

 

History

History
67 lines (39 loc) · 2.89 KB

File metadata and controls

67 lines (39 loc) · 2.89 KB

Github Cheatsheet

Git is a version control software that allows tracking of changes. It's commonly used for software development and is great tool for working in teams.

This guide does not cover in detail the functionality and awesome-ness of Git and Github. However, it will be enough for you to get started.

To get started

Create an account at github.com.
For pricing plans choose Free.

Installing git on your machine:
(Required if you want to use git commands from your local machine)

  • Go to the git-scm website and download the appropriate installer.
  • After downloading click on the file to begin set up.
  • Finish setup by keeping default options.

Making Pull request

Forking a Repository

After choosing a repository to contribute to, you need to fork it i.e. create a copy of it. Forks are normally used to either propose changes to someone else's project or to use someone else's project as a starting point for your own idea.

Create a Branch

It's recommended to create a new branch as a branch isolates development work without affecting other branches in the repository.

Contributing

Solutions can be contributed in many ways, for our repository we require a solution file to be uploaded. You can contribute online through Github's Website, through your laptop directly using a Command Line Interface or tools like Github Desktop, some code editors even allow importing and working with Github projects directly.

Here's how to add a file using the Github website

Creating a Pull Request

Once you are satisfied with the changes you've made you can create a pull request to merge your work with the original repository.
The decision to merge a PR is taken by the maintainers of that repository.

Github Lingo

  • Repository: A repository is essentially a project. For example loop2019-20sem1 is the name of this repository.

  • PR : A pull request lets people know of changes added to a repository. After changes are "committed" to a file a PR is created. This PR is then checked by concerned parties, in this case us, to review and accept the changes.

  • Fork : A fork is a copy of a repository. Forking a repository allows you to freely experiment with changes without affecting the original project.

For more about Git and Github