git의cat-file 명령 사용법
1673 단어 git
명령 옵션
git cat-file Provide content or type and size information for repository objects.
git cat-file
명령은 버전 라이브러리 객체의 내용, 유형 및 크기 정보를 표시합니다.object
The name of the object to show. For a more complete list of ways to spell object names, see the “SPECIFYING REVISIONS” section in gitrevisions(7).
-t Instead of the content, show the object type identified by object. 객체의 유형을 표시합니다.
-s Instead of the content, show the object size identified by object. 객체의 크기를 표시합니다.
-e Suppress all output; instead exit with zero status if object exists and is a valid object. 객체가 존재하고 유효한 경우 명령 종료 상태 반환 값은 0입니다.
-p
Pretty-print the contents of object based on its type. 대상의 유형에 따라 우아한 방식으로 대상의 내용을 현시한다.
type Typically this matches the real type of object but asking for a type that can trivially be dereferenced from the given object is also permitted. An example is to ask for a “tree” with object being a commit object that contains it, or to ask for a “blob” with object being a tag object that points at it.
사용 예
sha1sum
명령은 문자열 "Git"의 해시 값을 생성합니다.printf Git | sha1sum
생성
HEAD
대상의 하희값:(printf "%s %d\000" `git cat-file -t HEAD` `git cat-file -s HEAD`; git cat-file -p HEAD) | sha1sum
참고 자료
git-cat-file gitrevisions
이 내용에 흥미가 있습니까?
현재 기사가 여러분의 문제를 해결하지 못하는 경우 AI 엔진은 머신러닝 분석(스마트 모델이 방금 만들어져 부정확한 경우가 있을 수 있음)을 통해 가장 유사한 기사를 추천합니다:
Heroku H10/503 오류 해결 방법 - 이야기오후 2시 30분까지 내 이해 수준에 따라 배포할 준비가 된 내 코드 를 완성했습니다. 몇 달 전에 플랫폼에 Node.js 앱을 배포하여 을 따르기로 결정했습니다. How to solve Heroku H10 erro...
텍스트를 자유롭게 공유하거나 복사할 수 있습니다.하지만 이 문서의 URL은 참조 URL로 남겨 두십시오.
CC BY-SA 2.5, CC BY-SA 3.0 및 CC BY-SA 4.0에 따라 라이센스가 부여됩니다.