Git LFS
리포지토리에 대해 Git 대용량 파일 스토리지(LFS)을 사용하거나 사용하지 않도록 설정할 수 있습니다.
Git LFS API 정보
Git LFS를 사용하여 Git 리포지토리에 대용량 파일을 저장할 수 있습니다. Git LFS API를 사용하면 개별 리포지토리에 대한 기능을 사용하거나 사용하지 않도록 설정할 수 있습니다. Git LFS에 대한 자세한 내용은 "Git LFS정보"를 참조하세요.
리포지토리에 대한 관리자 액세스 권한이 있는 사람 Git LFS API를 사용할 수 있습니다.
Git LFS의 사용량은 청구될 수 있습니다. 자세한 내용은 “Git 대용량 파일 스토리지 요금 청구 정보”를 참조하세요.
조직에 속한 리포지토리에 대해 Git LFS API를 사용하려면 역할에서 조직의 청구에 대한 액세스 권한을 제공해야 합니다. 자세한 내용은 "조직의 역할"을 참조하세요.
Enable Git LFS for a repository
Enables Git LFS for a repository. Access tokens must have the admin:enterprise scope.
매개 변수
| Headers |
|---|
| Name, Type, Description |
acceptstringSetting to |
| Path parameters |
| Name, Type, Description |
ownerstringRequiredThe account owner of the repository. The name is not case sensitive. |
repostringRequiredThe name of the repository. The name is not case sensitive. |
HTTP 응답 상태 코드
| 상태 코드 | 설명 |
|---|---|
202 | Accepted |
403 | We will return a 403 with one of the following messages:
|
코드 샘플
curl \
-X PUT \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>"\
-H "X-GitHub-Api-Version: 2022-11-28" \
https://api.github.com/repos/OWNER/REPO/lfsAccepted
Status: 202Disable Git LFS for a repository
Disables Git LFS for a repository. Access tokens must have the admin:enterprise scope.
매개 변수
| Headers |
|---|
| Name, Type, Description |
acceptstringSetting to |
| Path parameters |
| Name, Type, Description |
ownerstringRequiredThe account owner of the repository. The name is not case sensitive. |
repostringRequiredThe name of the repository. The name is not case sensitive. |
HTTP 응답 상태 코드
| 상태 코드 | 설명 |
|---|---|
204 | No Content |
코드 샘플
curl \
-X DELETE \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>"\
-H "X-GitHub-Api-Version: 2022-11-28" \
https://api.github.com/repos/OWNER/REPO/lfsResponse
Status: 204