형상관리/Git
깃 Clone : 깃허브에 로컬 폴더 연결하고 commit, push까지
Rainbow🌈Coder
2022. 1. 8. 16:22
728x90
[Git] 깃허브에 로컬 폴더 연결하기(clone) (velog.io)
[Git] 깃허브에 로컬 폴더 연결하기(clone)
1. PC(로컬)에 새로운 폴더 생성 **2. 마우스 오른쪽 - Git Bash Here * mac은 terminal에서 열기* 3. 깃 계정
velog.io
위의 포스팅을 참고하여 레포지토리 링크 복사 후
$ git clone 레포지토리링크 를 통해
clone하고 나면,
해당 로컬 폴더에서 Git Bash here을 통해 깃bash를 열고 수정을 가한 후
이 모든 과정은 단 5줄만 입력해주면 된다.
$ git clone
$ git add .
$ git status 설명: 변경사항을 확인해준다.
$ git commit -m "secondTset" 설명 : 커밋할 때마다 꼼꼼하게 쓰는 것을 추천
$ git push origin main 설명 : 푸쉬
$ git pull origin main 설명 : 깃 최신 버전을 로컬에 동기화
$ git clone
~로컬에서 수정 후~
$ git add .
$ git status
On branch main
Your branch is up to date with 'origin/main'.
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
renamed: Pattern/test.txt -> Pattern/test2.txt
new file: Unity/test.txt
$ git commit -m "secondTset"
2 files changed, 1 insertion(+)
rename Pattern/{test.txt => test2.txt} (100%)
create mode 100644 Unity/test.txt
$ git push origin main
remote: Resolving deltas: 100% (1/1), completed with 1 local object.
main -> main
참 쉽죠잉
728x90