웹 프로그래밍

[GitHub] 저장소 생성과 프로젝트 원격 저장(Git Bash) 본문

GitHub

[GitHub] 저장소 생성과 프로젝트 원격 저장(Git Bash)

B. C Choi 2022. 6. 16. 19:18
반응형

1.  GitHub 설치

https://git-scm.com/downloads

 

Git - Downloads

Downloads macOS Windows Linux/Unix Older releases are available and the Git source repository is on GitHub. GUI Clients Git comes with built-in GUI tools (git-gui, gitk), but there are several third-party tools for users looking for a platform-specific exp

git-scm.com

위 링크 이동 후 OS에 맞추어 설치를 진행합니다.

 

 

2. GitHub 로그인

https://github.com/login

 

GitHub: Where the world builds software

GitHub is where over 83 million developers shape the future of software, together. Contribute to the open source community, manage your Git repositories, review code like a pro, track bugs and feat...

github.com

 

 

3. GitHub 저장소 생성

New를 클릭하고 Repository 설정을 진행합니다.

1) 저장소 이름 입력.

2) public(전체 공개) or private(비공개, 일부 공개).

3) README file을 생성.

4) 저장소 생성

 

 

4. 저장소 링크 저장(Git Bash 안에서는 붙여넣기가 안 되기 때문에 직접 입력을 권장)

 

 

5. 원격 저장을 위한 프로젝트 폴더 우클릭 -> Git Bash Here

 

 

6. Git Bash 명령어를 입력합니다.

 

1) git config --global user.name "이름"     - 초기 이름 설정

2) git config --global user.email "이메일"  - 초기 이메일 설정

3) git init                                                       - .git 파일 생성

 

 

4) git add .                                                 - 프로젝트 추가

5) git status                                               - 상태

 

6) git commit -m "내용"

7) git remote add origin 링크주소

링크 주소는 4번에서 저장한 링크를 사용하시면 됩니다.

 

 

8) git push -u origin master

명령어 입력후 Connect to GitHub 창이 뜨시면 Token 탭을 선택합니다.

Token 얻는 방법.

 

7. 끝

반응형