본문 바로가기
개발자 도전기

[Git] 설치 / 폴더 지정 / git init (윈도우OS 기준)

by 개발하는아빠 2022. 10. 24.

작업환경 : 윈도우 PC

 

1. Git 설치

설치 사이트에 접속하여 안내에 따라 설치

https://git-scm.com/book/en/v2/Getting-Started-Installing-Git

 

Git - Installing Git

This book was written using Git version 2. Since Git is quite excellent at preserving backwards compatibility, any recent version should work just fine. Though most of the commands we use should work even in ancient versions of Git, some of them might not

git-scm.com

 

 

2. 버전관리를 시작할 폴더 지정

  1) 폴더 생성

 

  2) Git Bash Here 선택

 

 

3. Git 명령어 사용

  1) 이메일과 이름 등록

git config --global user.email "test@naver.com"
git config --global user.name "test

 

  2) git init

  - git 소프트웨어가 해당 폴더를 모니터링하기 시작함.

  - .git 폴더가 생성됨 (git 파일이 저장되는 장소로 생각됨)

 

 

 

 

  2) git add 파일명

 

  3) git commit -m '메세지 내용 입력'

    : 영구적으로 기록됨