티스토리 뷰
Git 최초 설정
Git을 설치 후 먼저 사용하기 위하여 몇 가지 환경을 설정해야 하는데 git config 명령어로 설정 내용을 확인하고 변경할 수 있다.
사용자 정보 설정
$ git config --global user.name "사용자 이름"
$ git config --global user.email "이메일 주소"
사용할 편집기 설정
$ git config --global core.editor emacs
이후 설정한 정보를 확인을 하려면 git config --list 명령어를 실행하면 설정 내용을 확인할 수 있다.
$ git config --list
user.name=John Doe
user.email=johndoe@example.com
color.status=auto
color.branch=auto
color.interactive=auto
color.diff=auto
...
git config <key> 명령으로 Git이 특정 Key에 대해 어떤 값을 사용하는지 확인할 수 있다.
$ git config user.name
John Doe
추가로 명령어에 대한 도움말이 필요할 경우 git help <verb>를 입력하면 확인할 수 있고 Git에서도 확인 가능하다.
$ git add -h
usage: git add [<options>] [--] <pathspec>...
-n, --dry-run dry run
-v, --verbose be verbose
-i, --interactive interactive picking
-p, --patch select hunks interactively
-e, --edit edit current diff and apply
-f, --force allow adding otherwise ignored files
-u, --update update tracked files
-N, --intent-to-add record only the fact that the path will be added
later
-A, --all add changes from all tracked and untracked files
--ignore-removal ignore paths removed in the working tree (same
as --no-all)
--refresh don't add, only refresh the index
--ignore-errors just skip files which cannot be added because of
errors
--ignore-missing check if - even missing - files are ignored in
dry run
--chmod <(+/-)x> override the executable bit of the listed files
내용 참고 및 이미지 출처 - Pro Git
'study > Git' 카테고리의 다른 글
Git-remote, push, pull (0) | 2022.06.08 |
---|---|
Git-branch (0) | 2022.06.06 |
Git- Staged (0) | 2022.06.05 |
Git - init, add, commit (0) | 2022.06.04 |
Git 알아보기 (0) | 2022.06.02 |
댓글
공지사항
최근에 올라온 글
최근에 달린 댓글
- Total
- Today
- Yesterday
링크
TAG
- git공부
- Magazine K
- git 공부
- error: failed to push some refs to 'https://github.com/
- 톰캣
- 배열
- authenticate()
- Java
- 혼자 공부하는 파이썬
- 회원 로그인
- django
- 암호화
- 면접을 위한 CS 전공 지식 노트
- django-environ
- API
- 커맨드 객체
- python3
- musma
- 웹페이지
- django.contrib.auth
- 환경 변수 설정
- 검색 결과 내 페이지네이션
- 한글 형태소 분석기
- Spring
- path variable
- Python
- 디자인 패턴
- git
- Django tutorial
- 회원가입
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 |
글 보관함