본문 바로가기
CS/Git

[Git/GitHub] git push 하는 법/첫 push/로컬저장소 원격저장소 연결

by Code Song 2024. 1. 29.

처음 repository에서 push 할 때, 아래와 같은 방법으로 진행할 수 있습니다.

 

  1. 원격저장소(git 사이트의 repository)를 만듭니다.
  2. 로컬저장소(내 컴퓨터의 폴더)를 만듭니다.
  3. 로컬저장소에서 우클릭 후 git bash here
    1. git initori
    2. git add .
    3. git commit -m "Initial commit"
    4. git remote add origin [repository 주소]
    5. git push -u origin main

 

 

아래는 참조한 글입니다

 

https://velog.io/@hyeongjun/Git-GitHub-Repository%EC%97%90-push-%ED%95%98%EB%8A%94-%EB%B0%A9%EB%B2%95-%ED%8C%8C%EC%9D%BC-%EC%98%AC%EB%A6%AC%EA%B8%B0

 

[Git] GitHub Repository에 push 하는 방법 (파일 올리기)

GitHub 간단 사용법

velog.io

 

댓글