Github 코드 올리는 방법

1 개념[ | ]

Github에 코드 올리는 방법
  • 우분투에서 GitHub에 코드 올리는 방법

2 순서[ | ]

  • 1.Github에서 무료 계정 생성
https://github.com/ 에 접속하여 무료 계정 생성
  • 2.GitHub에서 새 저장소 생성
new repository 버튼을 눌러 레파지토리 생성
저장소 URL을 복사
  • 3.내 컴퓨터에서 GitHub 연결
아래 명령을 추가하여 .git/config 파일을 설정
$ git remote add origin https://github.com/USERNAME/REPOSITORY_NAME.git # Remote Repository 추가
$ git push -u origin master
.git/config 파일 내용 참조
[core]
	repositoryformatversion = 0
	filemode = true
	bare = false
	logallrefupdates = true
[branch "master"]
	remote = origin
	merge = refs/heads/master
[remote "origin"]
	url = https://github.com/USERNAME/REPOSITORY_NAME.git
	fetch = +refs/heads/*:refs/remotes/origin/*
문서 댓글 ({{ doc_comments.length }})
{{ comment.name }} {{ comment.created | snstime }}