UI/git || github
[git bash] local <--> remote 데이터 전송하기
Soo_Parkle
2023. 11. 30. 10:45
☆Github 저장소를 로컬 git에서 별칭으로 만들어 관리하기
1. github 와 연결
$ git remote add origin(별칭) github's URL(내가 앞으로 올릴 repository URL)
2. Local git 에서 remote github로
$ git remote push origin(별칭) main(git hub default branch name)
※ 주의 Local과 remote의 데이터 상태가 동일하지 않을 경우 push가 불가능.
따라서 pull을 통해서 local === remote 데이터 상태를 동일화 시킨후 push 가능 url.
Basic concept
master(main) = local repository
orgin/master(main)[보통 최신 버전을 가리킴] = remote repository
pull = fetch(당겨온다, 읽어 온다) + merge
fetch 를 하면 가장 최신 업데이트 된 repository정보를 가져옴 from branch(없으면 안 가져오겠지염?)
github desktop에서 publish = push