Git

From David's Wiki
Revision as of 19:25, 30 September 2019 by David (talk | contribs) (Created page with "Git is the famous version control system made by Linus Torvalds. =Usage= ==Basic Usage== <syntaxhighlight> # Clone or download a repository git clone <url> # Stage your chan...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
\( \newcommand{\P}[]{\unicode{xB6}} \newcommand{\AA}[]{\unicode{x212B}} \newcommand{\empty}[]{\emptyset} \newcommand{\O}[]{\emptyset} \newcommand{\Alpha}[]{Α} \newcommand{\Beta}[]{Β} \newcommand{\Epsilon}[]{Ε} \newcommand{\Iota}[]{Ι} \newcommand{\Kappa}[]{Κ} \newcommand{\Rho}[]{Ρ} \newcommand{\Tau}[]{Τ} \newcommand{\Zeta}[]{Ζ} \newcommand{\Mu}[]{\unicode{x039C}} \newcommand{\Chi}[]{Χ} \newcommand{\Eta}[]{\unicode{x0397}} \newcommand{\Nu}[]{\unicode{x039D}} \newcommand{\Omicron}[]{\unicode{x039F}} \DeclareMathOperator{\sgn}{sgn} \def\oiint{\mathop{\vcenter{\mathchoice{\huge\unicode{x222F}\,}{\unicode{x222F}}{\unicode{x222F}}{\unicode{x222F}}}\,}\nolimits} \def\oiiint{\mathop{\vcenter{\mathchoice{\huge\unicode{x2230}\,}{\unicode{x2230}}{\unicode{x2230}}{\unicode{x2230}}}\,}\nolimits} \)

Git is the famous version control system made by Linus Torvalds.

Usage

Basic Usage

# Clone or download a repository
git clone <url>

# Stage your changes
git add <my files>
# Stage all files
git add .

# Make a commit
git commit -m "My commit message"

# Push your changes to the repository
git push

# Pull the latest changes from the repository
# Equivalent to git fetch && git merge FETCH_HEAD
git pull

Branches

Pull Requests

Git Large File Storage (LFS)

Reference