Daily Develope

[Git] add 응용/명령어 정리 본문

Git

[Git] add 응용/명령어 정리

noggame 2022. 6. 29. 07:55

ㅇ 상태에 따른 파일 조회

# 상태 조회
git ls-files --{status}

# [예1] 삭제파일 조회
git ls-files --deleted

# [예2] 변경파일 조회
git ls-files --modified

# [응용] 삭제된 파일만 추가
git add $(git ls-files --modified)

 

ㅇ 변경사항(Changes)에 대해서만 추가

git add -u

 

'Git' 카테고리의 다른 글

[Git] tag 정리  (0) 2022.12.13
[Git] 오류 정리  (0) 2022.01.07
[Git] .gitignore 작성  (0) 2022.01.07
[Git] 기본 명령어 (init / Add / commit)  (0) 2022.01.07
[GitLab] YAML 파일 작성 예시 (Maven, JUnit 수행)  (0) 2022.01.07
Comments