Skip to main content

One post tagged with "git"

View All Tags

210226

๋นˆ ๋ธŒ๋žœ์น˜ ์ƒ์„ฑํ•˜๊ธฐ#

git checkout --orphan empty-branch
git rm -rf .
# ๋นˆ ์ปค๋ฐ‹ ์ƒ์„ฑํ•˜๊ธฐ
git commit --allow-empty -m "Initial commit"

Git Pull ์ „๋žต#

git pull ์„ ๋ณ„๋„ ์˜ต์…˜ ์—†์ด ์‹คํ–‰ํ–ˆ์„ ๋•Œ ๊ฒฝ๊ณ  ๋ฌธ๊ตฌ๊ฐ€ ๋‚˜ํƒ€๋‚ฌ๋‹ค.

warning: Pulling without specifying how to reconcile divergent branches is
discouraged. You can squelch this message by running one of the following
commands sometime before your next pull:
git config pull.rebase false # merge (the default strategy)
git config pull.rebase true # rebase
git config pull.ff only # fast-forward only
You can replace "git config" with "git config --global" to set a default
preference for all repositories. You can also pass --rebase, --no-rebase,
or --ff-only on the command line to override the configured default per
invocation.
  • default (merge) : ๋กœ์ปฌ ๋ธŒ๋žœ์น˜์™€ ๋ฆฌ๋ชจํŠธ ๋ธŒ๋žœ์น˜์˜ Head๊ฐ€ ๋‹ค๋ฅธ ์œ„์น˜์— ์žˆ์„ ๋•Œ, pull ๋ฐ›์œผ๋ฉด, Merge ์ปค๋ฐ‹์„ ์ƒ์„ฑํ•จ.

  • rebase : ๋กœ์ปฌ ๋ธŒ๋žœ์น˜์™€ ๋ฆฌ๋ชจํŠธ ๋ธŒ๋žœ์น˜์˜ Head๊ฐ€ ๋‹ค๋ฅธ ์œ„์น˜์— ์žˆ์„ ๋•Œ, pull ๋ฐ›์œผ๋ฉด, ๋ฆฌ๋ชจํŠธ ๋ธŒ๋žœ์น˜๋ฅผ rebase ํ•˜์—ฌ history๋ฅผ ์ •๋ฆฌํ•จ.

  • fast-forward only : fast-forward ๊ด€๊ณ„์— ์žˆ์„ ๋•Œ๋งŒ pull ์„ ํ—ˆ์šฉํ•จ.

2021-04-05-210226-image-0

Git - git-pull Documentation

[GIT] Git pull ์ „๋žต (default, --ff -only, --rebase)

GitHub ํ™˜๊ฒฝ์—์„œ์˜ ์‹ค์ „ Git ๋ ˆ์‹œํ”ผ : NHN Cloud Meetup

Conventional Commit#

Conventional Commits

Git commit ๋ฉ”์„ธ์ง€ ๊ทœ์•ฝโ€Š-โ€ŠConventional Commits