Written by students who passed Immediately available after payment Read online or as PDF Wrong document? Swap it for free 4.6 TrustPilot
logo-home
Class notes

GIT and GITHUB for Beginners

Rating
-
Sold
-
Pages
3
Uploaded on
16-05-2023
Written in
2022/2023

This notes provides explaination of GIT from the basics.IT covers all the topics of GIT and GITHUB and we will be uploading other notes og these as well.

Institution
Course

Content preview

Introduction to Git and GitHub
Git is an open source and free source control management system that allows you to
manage changes to files over time and go back to see what those changes were.
GitHub is a hosting platform where you can collaborate with others on your Git
repositories. In this tutorial, we will learn how to use both Git and GitHub.

What is Git?
With Git, you can manage changes to files over time and go back and see what those
changes were. For example, if you need to update a text on your website, you can
create another version of the website, make the update, and then merge it back into
the main branch. You can also revert back to a previous version if needed.

Installing Git
To install Git, go to the Git website and download the appropriate version for your
operating system. Once installed, you can use any terminal to interact with Git.
You can use Git Bash, PowerShell, or Command Prompt on Windows, or the Terminal app
on Mac. You can also download third-party terminals like Hyper.

Configuring Git
Before using Git, you need to configure it by specifying your name, email address,
and default branch name. To do this, open Git Bash and type the following commands:

git config global user.name "Your Name"
git config global user.email "Your Email"
git config global init.defaultBranch main
You can use the git config command to configure other settings as well. If you're
not sure what a command does or what options it has, you can ask Git for help by
typing git help <command>.

Creating a Git Repository
To use Git for source control, you need to turn your project folder into a Git
repository. To do this, navigate to your project folder in Git Bash and type git
init. This will create a new folder called .git that contains all the necessary
repository files.

You can use the git status command to see the status of your repository and make
sure everything is up to date.

Introduction to Git
Git is a version control system that allows you to track changes made to files over
time. In this tutorial, we will cover the basics of Git and how to use it to manage
your project files.

Tracking Files with Git
When you start using Git, all of your files are untracked. This means that Git is
not keeping track of any changes made to those files. To track a file, you can use
the command git add filename. This will add the file to Git's tracking system.

To confirm which files are currently being tracked, use the command git status.
If you no longer want to track a file, use the command git rm --cached filename.
Ignoring Files with .gitignore
You may have certain files that you want to ignore and not track with Git. To do
this, you can create a .gitignore file in your project directory. In this file, you
can list all of the files and directories that you want Git to ignore.

To create a .gitignore file, right-click in your project directory and select "New"
> "Text Document".
Rename the file to .gitignore.
Open the file in a text editor and list the files and directories you want Git to

Written for

Course

Document information

Uploaded on
May 16, 2023
Number of pages
3
Written in
2022/2023
Type
Class notes
Professor(s)
-
Contains
Github and git

Subjects

$8.99
Get access to the full document:

Wrong document? Swap it for free Within 14 days of purchase and before downloading, you can choose a different document. You can simply spend the amount again.
Written by students who passed
Immediately available after payment
Read online or as PDF

Get to know the seller
Seller avatar
prathammalagi

Get to know the seller

Seller avatar
prathammalagi
Follow You need to be logged in order to follow users or courses
Sold
-
Member since
2 year
Number of followers
0
Documents
1
Last sold
-

0.0

0 reviews

5
0
4
0
3
0
2
0
1
0

Recently viewed by you

Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Working on your references?

Create accurate citations in APA, MLA and Harvard with our free citation generator.

Working on your references?

Frequently asked questions