Giter Club home page Giter Club logo

phase-0-wsl2-env-git-github's Introduction

Configuring Git and GitHub on WSL2

Create a GitHub Account

To work on and get credit for the labs and lessons that you do during the program, you will need to sign up for a GitHub account if you don't already have one.

Action Item

  1. Open the GitHub signup webpage at https://github.com/join
  2. Fill out the form and create your account
  3. Verify the email address connected to your GitHub account

Check Your Work

<iframe width="560" height="315" src="https://www.youtube.com/embed/f2yf1RJUAp4" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>

If you were able to verify your email address, continue below.

Configure Git and GitHub

Git is the tool that we'll use to download and upload the work we do in labs and lessons. To use Git without signing in every time, you can create a Secure Shell (SSH) key and associate that to your GitHub account. You will also need to run a few commands to make sure that when you use Git, you get the proper credit for your work. This step will ask you to do work both in your browser and your terminal.

Action Item: Update Git

  1. Open the "Ubuntu" application using the "Start" menu
  2. Type sudo add-apt-repository ppa:git-core/ppa and press <Enter> to add a package repository for downloading the latest version of Git. Follow the prompts in the terminal.
  3. Type sudo apt update and press <Enter> to update your local repository cache
  4. Type sudo apt install git and press <Enter> to install the latest version of Git

Check Your Work

<iframe width="560" height="315" src="https://www.youtube.com/embed/hgAurDMhKAc" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>

You can check your work by typing git --version in the terminal. You should see a version greater than 2.33.0.

Action Item: Configure Git

  1. Open the "Ubuntu" application using the "Start" menu
  2. Type git config --global color.ui true and press <Enter>
  3. Type git config --global user.name + <Space> + your name and press <Enter> (Note: this should be your full name, not your GitHub username, in quotes.)
  4. Type git config --global user.email + <Space> + the email address you used to sign up to GitHub and press <Enter>
  5. Type git config --global init.defaultBranch main to update the default branch name to main
  6. Type ssh-keygen and press <Enter>. For each prompt do not type anything, just continue to press <Enter>. It's particularly important that you do not enter a passphase; you should leave the passphrase empty when prompted. If you enter a passphrase here, you'll have to enter it every time you interact with GitHub (which will happen a lot during the program). You may also run into issues submitting assignments later.
  7. Type cat ~/.ssh/id_rsa.pub | clip.exe and press <Enter>. This will copy your SSH key to your clipboard
  8. Open the GitHub New SSH key form (https://github.com/settings/ssh/new) (Note: you need to be logged in to GitHub to access that link.)
  9. Type "My personal PC" in the "Title" input field
  10. Paste what's on your clipboard from step seven in the "Key" input field
  11. Click "Add SSH Key"

Check Your Work

<iframe width="560" height="315" src="https://www.youtube.com/embed/bRCOqNaYnKQ" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>

If you see your new SSH key beneath the "SSH keys" heading, continue to the next lesson, Configuring the Flatiron Student Portal.

phase-0-wsl2-env-git-github's People

Contributors

ihollander avatar lizbur10 avatar maxwellbenton avatar bal360 avatar timothylevi avatar jlboba avatar timothylevi-test avatar

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.