-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
7ec0c1d
commit 27d469c
Showing
2 changed files
with
41 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# git λͺ λ Ήμ΄ μμ‘΄μ© ν€νΈ - 1 | ||
|
||
##1. λ‘컬 μ μ₯μ λ§λ€κΈ°, gitμ κ³μ μ€μ : init, config | ||
- ### git init | ||
νμ¬ ν΄λλ₯Ό κΉμ΄ κ΄λ¦¬νλ νλ‘μ νΈ λλ ν 리(=working directory)λ‘ μ€μ | ||
-> κ·Έ μμ μ μ₯μ(.git ν΄λ) μμ± | ||
- ### git config user.name, git config user.email | ||
```commandline | ||
git comfig user.name 'my_name' | ||
git config user.email '[email protected]' | ||
``` | ||
μ¬μ©μμ μμ΄λμ μ΄λ©μΌμ μ€μ (컀λ°ν λ νμν¨) | ||
##2. μ€ν μ΄μ§ μμμ μ¬λ¦¬κΈ° : add | ||
- **git add** : μμ μ¬νμ΄ μλ νΉμ νμΌμ **staging area(μ€ν μ΄μ§ μμ)** μ μ¬λ¦¬κΈ° | ||
```commandline | ||
git add [νμΌλͺ ] # ν΄λΉ νμΌ | ||
git add [λλ ν 리λͺ ] # ν΄λΉ λλ ν 리 λ΄μ λͺ¨λ νμΌ | ||
git add . # (ν΄λΉ working directory λ΄μ) λͺ¨λ νμΌ | ||
``` | ||
|
||
##3. μ€ν μ΄μ§ μμμμ λ΄λ¦¬κΈ° : reset | ||
- **git reset** : **staging area(μ€ν μ΄μ§ μμ)** μ μ¬λ Έλ νμΌμ λ€μ λ΄λ¦¬κΈ° | ||
```commandline | ||
git reset [νμΌλͺ ] | ||
``` | ||
|
||
##4. νλ‘μ νΈ κ΄λ ¨ μν 보기 : status | ||
- **git status** : κΉμ΄ νμ¬ μΈμνλ νλ‘μ νΈ κ΄λ ¨ λ΄μ©λ€ μΆλ ₯ | ||
μ€ν μ΄μ§ μμ μνλ λ³Ό μ μμ, νλ‘μ νΈμ λ¬Έμ κ° μκ²Όμ λ μ΄ λͺ λ Ήμ΄ νμ© | ||
|
||
##5. μ€ν μ΄μ§ μμ -> μ μ₯μ μμμΌλ‘ μ¬λ¦¬κΈ° : commit | ||
- **git commit -m "μ»€λ° λ©μμ§"** : νμ¬ **staging area(μ€ν μ΄μ§ μμ)** μ λ΄μμ 컀λ°μΌλ‘ μ μ₯μμ μ¬λ¦¬κΈ° | ||
|
||
##6. λμ! : help | ||
- **git help [컀맨λ μ΄λ¦]** : μ¬μ©λ²μ΄ κΆκΈν κΉ λͺ λ Ήμ΄μ 곡μ λ©λ΄μΌ λ΄μ© μΆλ ₯ |