Skip to content

Commit 22fe5e9

Browse files
authored
fix: type updates (allow_forking in repositories, diff item status now has an enum) (#447)
1 parent 27aa8ba commit 22fe5e9

File tree

8 files changed

+42
-24
lines changed

8 files changed

+42
-24
lines changed

docs/migrations/getImportStatus.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ An import that does not have errors will progress through these steps:
2525
If there are problems, you will see one of these in the `status` field:
2626

2727
- `auth_failed` - the import requires authentication in order to connect to the original repository. To update authentication for the import, please see the [Update an import](https://docs.github.com/rest/reference/migrations#update-an-import) section.
28-
- `error` - the import encountered an error. The import progress response will include the `failed_step` and an error message. Contact [GitHub Support](https://support.github.com/contact?tags=rest-api) for more information.
28+
- `error` - the import encountered an error. The import progress response will include the `failed_step` and an error message. Contact [GitHub Support](https://support.github.com/contact?tags=dotcom-rest-api) for more information.
2929
- `detection_needs_auth` - the importer requires authentication for the originating repository to continue detection. To update authentication for the import, please see the [Update an import](https://docs.github.com/rest/reference/migrations#update-an-import) section.
3030
- `detection_found_nothing` - the importer didn't recognize any source control at the URL. To resolve, [Cancel the import](https://docs.github.com/rest/reference/migrations#cancel-an-import) and [retry](https://docs.github.com/rest/reference/migrations#start-an-import) with the correct URL.
3131
- `detection_found_multiple` - the importer found several projects or repositories at the provided URL. When this is the case, the Import Progress response will also include a `project_choices` field with the possible project choices as values. To update project choice, please see the [Update an import](https://docs.github.com/rest/reference/migrations#update-an-import) section.

docs/repos/createFork.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ type: API method
1010

1111
Create a fork for the authenticated user.
1212

13-
**Note**: Forking a Repository happens asynchronously. You may have to wait a short period of time before you can access the git objects. If this takes longer than 5 minutes, be sure to contact [GitHub Support](https://support.github.com/contact?tags=rest-api).
13+
**Note**: Forking a Repository happens asynchronously. You may have to wait a short period of time before you can access the git objects. If this takes longer than 5 minutes, be sure to contact [GitHub Support](https://support.github.com/contact?tags=dotcom-rest-api).
1414

1515
```js
1616
octokit.rest.repos.createFork({

docs/repos/update.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -139,6 +139,11 @@ Either `true` to allow automatically deleting head branches when pull requests a
139139

140140
`true` to archive this repository. **Note**: You cannot unarchive repositories through the API.
141141

142+
</td></tr>
143+
<tr><td>allow_forking</td><td>no</td><td>
144+
145+
Either `true` to allow private forks, or `false` to prevent private forks.
146+
142147
</td></tr>
143148
</tbody>
144149
</table>

docs/repos/uploadReleaseAsset.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ When an upstream failure occurs, you will receive a `502 Bad Gateway` status. Th
2525
**Notes:**
2626

2727
- GitHub renames asset filenames that have special characters, non-alphanumeric characters, and leading or trailing periods. The "[List assets for a release](https://docs.github.com/rest/reference/repos#list-assets-for-a-release)"
28-
endpoint lists the renamed filenames. For more information and help, contact [GitHub Support](https://support.github.com/contact?tags=rest-api).
28+
endpoint lists the renamed filenames. For more information and help, contact [GitHub Support](https://support.github.com/contact?tags=dotcom-rest-api).
2929
- If you upload an asset with the same filename as another uploaded asset, you'll receive an error and must delete the old file before you can re-upload the new asset.
3030

3131
```js

package-lock.json

Lines changed: 7 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
"author": "Gregor Martynus (https://twitter.com/gr2m)",
2525
"license": "MIT",
2626
"dependencies": {
27-
"@octokit/types": "^6.27.2",
27+
"@octokit/types": "^6.28.1",
2828
"deprecation": "^2.3.1"
2929
},
3030
"devDependencies": {

scripts/update-endpoints/generated/endpoints.json

Lines changed: 23 additions & 10 deletions
Large diffs are not rendered by default.

src/generated/method-types.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3990,7 +3990,7 @@ export type RestEndpointMethods = {
39903990
* If there are problems, you will see one of these in the `status` field:
39913991
*
39923992
* * `auth_failed` - the import requires authentication in order to connect to the original repository. To update authentication for the import, please see the [Update an import](https://docs.github.com/rest/reference/migrations#update-an-import) section.
3993-
* * `error` - the import encountered an error. The import progress response will include the `failed_step` and an error message. Contact [GitHub Support](https://support.github.com/contact?tags=rest-api) for more information.
3993+
* * `error` - the import encountered an error. The import progress response will include the `failed_step` and an error message. Contact [GitHub Support](https://support.github.com/contact?tags=dotcom-rest-api) for more information.
39943994
* * `detection_needs_auth` - the importer requires authentication for the originating repository to continue detection. To update authentication for the import, please see the [Update an import](https://docs.github.com/rest/reference/migrations#update-an-import) section.
39953995
* * `detection_found_nothing` - the importer didn't recognize any source control at the URL. To resolve, [Cancel the import](https://docs.github.com/rest/reference/migrations#cancel-an-import) and [retry](https://docs.github.com/rest/reference/migrations#start-an-import) with the correct URL.
39963996
* * `detection_found_multiple` - the importer found several projects or repositories at the provided URL. When this is the case, the Import Progress response will also include a `project_choices` field with the possible project choices as values. To update project choice, please see the [Update an import](https://docs.github.com/rest/reference/migrations#update-an-import) section.
@@ -6379,7 +6379,7 @@ export type RestEndpointMethods = {
63796379
/**
63806380
* Create a fork for the authenticated user.
63816381
*
6382-
* **Note**: Forking a Repository happens asynchronously. You may have to wait a short period of time before you can access the git objects. If this takes longer than 5 minutes, be sure to contact [GitHub Support](https://support.github.com/contact?tags=rest-api).
6382+
* **Note**: Forking a Repository happens asynchronously. You may have to wait a short period of time before you can access the git objects. If this takes longer than 5 minutes, be sure to contact [GitHub Support](https://support.github.com/contact?tags=dotcom-rest-api).
63836383
*/
63846384
createFork: {
63856385
(
@@ -8242,7 +8242,7 @@ export type RestEndpointMethods = {
82428242
*
82438243
* **Notes:**
82448244
* * GitHub renames asset filenames that have special characters, non-alphanumeric characters, and leading or trailing periods. The "[List assets for a release](https://docs.github.com/rest/reference/repos#list-assets-for-a-release)"
8245-
* endpoint lists the renamed filenames. For more information and help, contact [GitHub Support](https://support.github.com/contact?tags=rest-api).
8245+
* endpoint lists the renamed filenames. For more information and help, contact [GitHub Support](https://support.github.com/contact?tags=dotcom-rest-api).
82468246
* * If you upload an asset with the same filename as another uploaded asset, you'll receive an error and must delete the old file before you can re-upload the new asset.
82478247
*/
82488248
uploadReleaseAsset: {

0 commit comments

Comments
 (0)