Git Product home page Git Product logo

git_tutorial's Introduction

git_tutorial

Git and GitHub are tools that enable efficient collaborative software development. In this tutorial, we will cover a few fundamental tools, namely:

  • Issues
  • Commits
  • Forking
  • Pull Requests

The focus of this tutorial will be farmiliarizing yourself with git, not writing code. To do this I have written a very simple python3 script, main.py. In order to run main.py from the command line, simply execute the following:

python3 main.py

Instructions

Before the tutorial

Please make sure you

  1. Install git on your computer
  2. Create a GiHub account
  3. Install python3 on your computer (not strickly necessary, but very illustrative).

Farmiliarize yourself with the issue we will collaboratively solve

You can read the issue here. At the begining of the tutorial I will assign you are group number which will indicate exactly what change you should make.

Creating a fork

  1. Log into GitHub
  2. Create a fork of this repository into your own GitHub account
  3. Navigate to your fork and clone to your local machine via a terminal window, e.g.
git clone https://github.com/eric-fork/git_tutorial.git
git remote add git_tutorial https://github.com/eric-fork/git_tutorial

But make sure to update the URL above to your own fork!

Make local changes

Make your assigned change to main.py as indicated in the issue. Save main.py and then commit and push to GitHub. Make sure to provide a descriptive commit message, e.g.

git add main.py
git commit -m "Uncommenting group 1 print statement" 
git push origin master

Share your changes with the world by opening a pull request in the original GitHub repoistory

Create a new pull request in the orignal GitHub repository here. Click the green "New Pull Request" button and then the "compare accross forks" link. Define the base (where you want to send your changes) and head (where your changes are coming from) repositories. Then click the green "Create pull request button" and provide a description of your changes, example here.

git_tutorial's People

Contributors

erickeenan avatar nmfreeman avatar

Watchers

James Cloos avatar  avatar

git_tutorial's Issues

Bug in main.py - print statements are commented.

Hi team, I noticed a bug in main.py. Several print statements are commented out. To fix this we need each group to uncomment their assigned print statement. For example, Group 2 should replace

# print("Group 2")

with

print("Group 2")

While Group 5, should replace

# print("Group 5")

with

print("Group 5")

Once all print statements have been uncommented, the desired behavior of main.py should be to output:

Group 1
Group 2
Group 3
Group 4
Group 5
Group 6

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.