File tree 2 files changed +85
-2
lines changed 2 files changed +85
-2
lines changed Original file line number Diff line number Diff line change @@ -23,6 +23,39 @@ import (
23
23
24
24
// GetRawFile get a file by path on a repository
25
25
func GetRawFile (ctx * context.APIContext ) {
26
+ // swagger:operation GET /repos/{owner}/{repo}/raw/{ref}/{filepath} repository repoGetRawFileOld
27
+ // ---
28
+ // summary: Get a file from a repository
29
+ // deprecated: true
30
+ // produces:
31
+ // - application/json
32
+ // parameters:
33
+ // - name: owner
34
+ // in: path
35
+ // description: owner of the repo
36
+ // type: string
37
+ // required: true
38
+ // - name: repo
39
+ // in: path
40
+ // description: name of the repo
41
+ // type: string
42
+ // required: true
43
+ // - name: filepath
44
+ // in: path
45
+ // description: filepath of the file to get
46
+ // type: string
47
+ // required: true
48
+ // - name: ref
49
+ // in: path
50
+ // description: "The name of the commit/branch/tag. Default to the repository’s default branch (usually master)"
51
+ // type: string
52
+ // deprecated: true
53
+ // responses:
54
+ // 200:
55
+ // description: success
56
+ // "404":
57
+ // "$ref": "#/responses/notFound"
58
+
26
59
// swagger:operation GET /repos/{owner}/{repo}/raw/{filepath} repository repoGetRawFile
27
60
// ---
28
61
// summary: Get a file from a repository
@@ -46,7 +79,7 @@ func GetRawFile(ctx *context.APIContext) {
46
79
// required: true
47
80
// - name: ref
48
81
// in: query
49
- // description: "The name of the commit/branch/tag. Default the repository’s default branch (usually master)"
82
+ // description: "The name of the commit/branch/tag. Default to the repository’s default branch (usually master)"
50
83
// type: string
51
84
// required: false
52
85
// responses:
Original file line number Diff line number Diff line change 8214
8214
},
8215
8215
{
8216
8216
"type": "string",
8217
- "description": "The name of the commit/branch/tag. Default the repository’s default branch (usually master)",
8217
+ "description": "The name of the commit/branch/tag. Default to the repository’s default branch (usually master)",
8218
8218
"name": "ref",
8219
8219
"in": "query"
8220
8220
}
8229
8229
}
8230
8230
}
8231
8231
},
8232
+ "/repos/{owner}/{repo}/raw/{ref}/{filepath}": {
8233
+ "get": {
8234
+ "produces": [
8235
+ "application/json"
8236
+ ],
8237
+ "tags": [
8238
+ "repository"
8239
+ ],
8240
+ "summary": "Get a file from a repository",
8241
+ "operationId": "repoGetRawFileOld",
8242
+ "deprecated": true,
8243
+ "parameters": [
8244
+ {
8245
+ "type": "string",
8246
+ "description": "owner of the repo",
8247
+ "name": "owner",
8248
+ "in": "path",
8249
+ "required": true
8250
+ },
8251
+ {
8252
+ "type": "string",
8253
+ "description": "name of the repo",
8254
+ "name": "repo",
8255
+ "in": "path",
8256
+ "required": true
8257
+ },
8258
+ {
8259
+ "type": "string",
8260
+ "description": "filepath of the file to get",
8261
+ "name": "filepath",
8262
+ "in": "path",
8263
+ "required": true
8264
+ },
8265
+ {
8266
+ "type": "string",
8267
+ "description": "The name of the commit/branch/tag. Default to the repository’s default branch (usually master)",
8268
+ "name": "ref",
8269
+ "in": "path"
8270
+ }
8271
+ ],
8272
+ "responses": {
8273
+ "200": {
8274
+ "description": "success"
8275
+ },
8276
+ "404": {
8277
+ "$ref": "#/responses/notFound"
8278
+ }
8279
+ }
8280
+ }
8281
+ },
8232
8282
"/repos/{owner}/{repo}/releases": {
8233
8283
"get": {
8234
8284
"produces": [
You can’t perform that action at this time.
0 commit comments