[Git] Github & ๋ฐฐํฌ
by ๋๋ถ๋1. Github ๊ธฐ์ด
1.1 Git
- ํ์ผ์ ๋ณ์ฒ์ฌ๋ฅผ ์ ์ฅํ๋ ์ญํ
- ๋๊ฐ, ๋ฌด์์, ์ด๋์, ์ธ์ ๋ณ๊ฒฝํ๋์ง์ ๋ํ ๋ด์ฉ ๊ธฐ๋ก ⇒ ์ฝ๋์ ๋ณํ ๊ธฐ๋ก
1.2 Github
- git๊ณผ ์ฝ๋๋ฅผ ์ ์ฅํ๊ณ ๊ด๋ฆฌํ๋ ์๋น์ค
- ๊ฐ๋ฐ์์ ํฌํธํด๋ฆฌ์ค ์ญํ
1.3 Github ํ๊ฒฝ์ค์
- Git, Git Bash ๋ค์ด ๋ฐ GitHub ๊ณ์ ์์ฑ
1.4 Repository ์์ฑ ๋ฐ ์ฒซ Push
- Github ์น์ฌ์ดํธ์์ Repository ์์ฑ
git init
git remote add origin Repository_address
git add . # directory์ ์๋ ๋ชจ๋ ํ์ผ์ด ์
๋ก๋ ์ค๋น ์ํ์ ๋ค์ด๊ฐ
git commit -m "(์ํ๋ ๋ด์ฉ)"
git push origin master # push๋ฅผ ํด์ผ Repository์ ์
๋ก๋๋จ
- Github์ Local PC๊ฐ ์ฐ๊ฒฐ๋์ด ์๊ณ (์ ์ ), local์์ repository์ ํ์ผ์ ์ ๋ก๋(ํ์ดํ)
2. Netlify ๋ฐฐํฌ
2.1 ์ ์ , ๋์ ํ์ด์ง
- ์ ์ ํ์ด์ง (Static page)
- ๋์ ํ์ด์ง (Dynamic page)
2.2 Netlify ๋ฐฐํฌ๊ณผ์
- Netlify์ ๊ฒฝ์ฐ ์ ์ ํ์ด์ง๋ง ์ ๋ก๋ ํ ์ ์์
- ์ค์ ๋ก ๋ฐฐํฌํด ๋ด! (likelion8th-session repository)
- My Notes
3. Github ์ฌ์ฉ๋ฒ ๋ฐ ํ์
3.1 ์์ฃผ ์ฐ๋ Git ๋ช ๋ น์ด
git init
: git ์ ์ฅ์๋ฅผ ์ด๊ธฐํgit add .
: ํด๋์ ๋ณ๊ฒฝ๋ ๋ชจ๋ ํ์ผ staging area์ ์ฌ๋ฆฌ๊ธฐgit commit -m "์ปค๋ฐ์ ๋ํ ์ค๋ช "
: ์ ์ฌ์ ๋์๊ฐ ์ ์๋ ์ ์ฅ์์ ์ฒดํฌ ํฌ์ธํธ ์์ฑgit remote add origin http://์๊ฒฉ ์ ์ฅ์ ์ฃผ์.git
: ์๊ฒฉ ์ ์ฅ์ (remote repository) ์ฐ๊ฒฐ- ๊ธฐ๋ณธ์ ์ธ Git ๋ช ๋ น์ด์ ์ํ ๊ณผ์
git branch ๋ธ๋์น๋ช
: ์๋ก์ด ๋ธ๋์น ์์ฑgit checkout ๋ธ๋์น๋ช
: ํด๋น ๋ธ๋์น๋ก ์์ฑgit push origin ๋ธ๋์น
: ์๊ฒฉ ์ ์ฅ์์ ํน์ ๋ธ๋์น์ ํ๋ก์ ํธ ์ ์ฅgit pull origin ๋ธ๋์น
: ์๊ฒฉ ์ ์ฅ์์ ํน์ ๋ธ๋์น์์ ๋ณ๊ฒฝ์ฌํญ pullgit clone http://์๊ฒฉ ์ ์ฅ์ ์ฃผ์.git
: ์๊ฒฉ ์ ์ฅ์์ ์๋ ํ์ผ ์ ์ฒด ๋ณต์ฌgit status
: git ์ ์ฅ์์ ์ํ ํ์ธ
3.2 Github๋ฅผ ์ด์ฉํ ํ์
- ์๊ฒฉ ์ ์ฅ์ ์์ฑ (Github repository ์์ฑ)
- ํ์์ Collaborator๋ก ์ถ๊ฐ
- ์ด๊ธฐ ํ๋ก์ ํธ push
- ํ์๋ค์ ๋ก์ปฌ์ ํ๋ก์ ํธ pull
- ํ์ ๊ฐ์์ ๋ธ๋์น๋ฅผ ์์ฑํ์ฌ ์์
- ๋ธ๋์น์ ์์ ํ ๋ด์ฉ์ push
- Master์ merge ํ๊ธฐ ์ pull request
- Pull request ํ์ธ ํ Mater์ merge
3.3 Fork๋ฅผ ์ด์ฉํ ํ์
- ์์ ํ๊ณ ์ถ์ Repository fork ํด์ค๊ธฐ
- ์์ ์ ๋ก์ปฌ์์ ์์
- ๋ณ๊ฒฝ์ฌํญ์ ์์ ์ ๋ธ๋์น์ Push
- ์๋ณธ Repository ์์ ์์๊ฒ Pull Request ์์ฒญ
- ์์ ์๊ฐ Pull Request๋ฅผ ์น์ธํ์ฌ mergeํ๋ฉด ์๋์ผ๋ก Collaborator ์ถ๊ฐ
'Git' ์นดํ ๊ณ ๋ฆฌ์ ๋ค๋ฅธ ๊ธ
Github License ์ถ๊ฐํ๊ธฐ (0) | 2023.06.27 |
---|---|
[Git] GitKraken Install (0) | 2021.07.05 |
[Git] GitBash 2.32.0 version Windows Install (0) | 2021.07.05 |
[Git] GitKraken์ ํ์ฉํ branch (0) | 2020.05.27 |
๋ธ๋ก๊ทธ์ ์ ๋ณด
๋๋ถ๋์ Devlog
๋๋ถ๋