Skip to content

Commit

Permalink
Lint all files in pre-commit (#1287)
Browse files Browse the repository at this point in the history
* Lint docs

* Add files config

* Regenerate client from commit 43a312f of spec repo

Co-authored-by: Thomas Hervé <[email protected]>
Co-authored-by: ci.datadog-api-spec <[email protected]>
Co-authored-by: api-clients-generation-pipeline[bot] <54105614+api-clients-generation-pipeline[bot]@users.noreply.github.com>
  • Loading branch information
3 people authored Jan 11, 2022
1 parent 681cca6 commit a715f4c
Show file tree
Hide file tree
Showing 1,041 changed files with 9,057 additions and 13,994 deletions.
8 changes: 4 additions & 4 deletions .apigentools-info
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
"spec_versions": {
"v1": {
"apigentools_version": "1.5.1.dev2",
"regenerated": "2022-01-10 18:18:43.274163",
"spec_repo_commit": "16aa0e9"
"regenerated": "2022-01-11 10:22:28.152764",
"spec_repo_commit": "43a312f"
},
"v2": {
"apigentools_version": "1.5.1.dev2",
"regenerated": "2022-01-10 18:18:43.297021",
"spec_repo_commit": "16aa0e9"
"regenerated": "2022-01-11 10:22:28.172409",
"spec_repo_commit": "43a312f"
}
}
}
16 changes: 15 additions & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,18 @@ repos:
language: docker_image
entry: cytopia/goimports@sha256:35c66e33c9c8bc986d0b3fdf49ee343ee0f277a76fa05f966590ea1edf191f28 -w .
stages: [manual]
pass_filenames: false
files: '^api/'
pass_filenames: false
- id: docs
name: Format documentation
stages: [manual]
language: node
language_version: 14.12.0
entry: prettier --write --list-different --ignore-unknown api
"types": [text]
files: '^api/'
pass_filenames: false
additional_dependencies:
# When updating the version of prettier, make sure to check the pre-commit file
# And keep the `entry` here up to date https://github.com/pre-commit/mirrors-prettier/blob/master/.pre-commit-hooks.yaml
- [email protected]
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
.PHONY: all
all: .generator .env
@docker-compose -f docker-compose.generator.yaml up
@pre-commit run --all-files --hook-stage=manual docs || echo "modified files"
@pre-commit run --all-files --hook-stage=manual lint || echo "modified files"

.PHONY: .env
Expand Down
1,802 changes: 896 additions & 906 deletions api/v1/datadog/README.md

Large diffs are not rendered by default.

10 changes: 3 additions & 7 deletions api/v1/datadog/docs/APIErrorResponse.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@

## Properties

Name | Type | Description | Notes
---- | ---- | ----------- | ------
**Errors** | **[]string** | Array of errors returned by the API. |
| Name | Type | Description | Notes |
| ---------- | ------------ | ------------------------------------ | ----- |
| **Errors** | **[]string** | Array of errors returned by the API. |

## Methods

Expand Down Expand Up @@ -44,8 +44,4 @@ and a boolean to check if the value has been set.

SetErrors sets Errors field to given value.



[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


29 changes: 13 additions & 16 deletions api/v1/datadog/docs/AWSAccount.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,19 @@

## Properties

Name | Type | Description | Notes
---- | ---- | ----------- | ------
**AccessKeyId** | Pointer to **string** | Your AWS access key ID. Only required if your AWS account is a GovCloud or China account. | [optional]
**AccountId** | Pointer to **string** | Your AWS Account ID without dashes. | [optional]
**AccountSpecificNamespaceRules** | Pointer to **map[string]bool** | An object, (in the form &#x60;{\&quot;namespace1\&quot;:true/false, \&quot;namespace2\&quot;:true/false}&#x60;), that enables or disables metric collection for specific AWS namespaces for this AWS account only. | [optional]
**CspmResourceCollectionEnabled** | Pointer to **bool** | Whether Datadog collects cloud security posture management resources from your AWS account. This includes additional resources not covered under the general &#x60;resource_collection&#x60;. | [optional] [default to false]
**ExcludedRegions** | Pointer to **[]string** | An array of AWS regions to exclude from metrics collection. | [optional]
**FilterTags** | Pointer to **[]string** | The array of EC2 tags (in the form &#x60;key:value&#x60;) defines a filter that Datadog uses when collecting metrics from EC2. Wildcards, such as &#x60;?&#x60; (for single characters) and &#x60;*&#x60; (for multiple characters) can also be used. Only hosts that match one of the defined tags will be imported into Datadog. The rest will be ignored. Host matching a given tag can also be excluded by adding &#x60;!&#x60; before the tag. For example, &#x60;env:production,instance-type:c1.*,!region:us-east-1&#x60; | [optional]
**HostTags** | Pointer to **[]string** | Array of tags (in the form &#x60;key:value&#x60;) to add to all hosts and metrics reporting through this integration. | [optional]
**MetricsCollectionEnabled** | Pointer to **bool** | Whether Datadog collects metrics for this AWS account. | [optional] [default to true]
**ResourceCollectionEnabled** | Pointer to **bool** | Whether Datadog collects a standard set of resources from your AWS account. | [optional] [default to false]
**RoleName** | Pointer to **string** | Your Datadog role delegation name. | [optional]
**SecretAccessKey** | Pointer to **string** | Your AWS secret access key. Only required if your AWS account is a GovCloud or China account. | [optional]
| Name | Type | Description | Notes |
| --------------------------------- | ------------------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------- |
| **AccessKeyId** | Pointer to **string** | Your AWS access key ID. Only required if your AWS account is a GovCloud or China account. | [optional] |
| **AccountId** | Pointer to **string** | Your AWS Account ID without dashes. | [optional] |
| **AccountSpecificNamespaceRules** | Pointer to **map[string]bool** | An object, (in the form &#x60;{\&quot;namespace1\&quot;:true/false, \&quot;namespace2\&quot;:true/false}&#x60;), that enables or disables metric collection for specific AWS namespaces for this AWS account only. | [optional] |
| **CspmResourceCollectionEnabled** | Pointer to **bool** | Whether Datadog collects cloud security posture management resources from your AWS account. This includes additional resources not covered under the general &#x60;resource_collection&#x60;. | [optional] [default to false] |
| **ExcludedRegions** | Pointer to **[]string** | An array of AWS regions to exclude from metrics collection. | [optional] |
| **FilterTags** | Pointer to **[]string** | The array of EC2 tags (in the form &#x60;key:value&#x60;) defines a filter that Datadog uses when collecting metrics from EC2. Wildcards, such as &#x60;?&#x60; (for single characters) and &#x60;_&#x60; (for multiple characters) can also be used. Only hosts that match one of the defined tags will be imported into Datadog. The rest will be ignored. Host matching a given tag can also be excluded by adding &#x60;!&#x60; before the tag. For example, &#x60;env:production,instance-type:c1._,!region:us-east-1&#x60; | [optional] |
| **HostTags** | Pointer to **[]string** | Array of tags (in the form &#x60;key:value&#x60;) to add to all hosts and metrics reporting through this integration. | [optional] |
| **MetricsCollectionEnabled** | Pointer to **bool** | Whether Datadog collects metrics for this AWS account. | [optional] [default to true] |
| **ResourceCollectionEnabled** | Pointer to **bool** | Whether Datadog collects a standard set of resources from your AWS account. | [optional] [default to false] |
| **RoleName** | Pointer to **string** | Your Datadog role delegation name. | [optional] |
| **SecretAccessKey** | Pointer to **string** | Your AWS secret access key. Only required if your AWS account is a GovCloud or China account. | [optional] |

## Methods

Expand Down Expand Up @@ -310,7 +310,4 @@ SetSecretAccessKey sets SecretAccessKey field to given value.

HasSecretAccessKey returns a boolean if a field has been set.


[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


13 changes: 4 additions & 9 deletions api/v1/datadog/docs/AWSAccountAndLambdaRequest.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

## Properties

Name | Type | Description | Notes
---- | ---- | ----------- | ------
**AccountId** | **string** | Your AWS Account ID without dashes. |
**LambdaArn** | **string** | ARN of the Datadog Lambda created during the Datadog-Amazon Web services Log collection setup. |
| Name | Type | Description | Notes |
| ------------- | ---------- | ---------------------------------------------------------------------------------------------- | ----- |
| **AccountId** | **string** | Your AWS Account ID without dashes. |
| **LambdaArn** | **string** | ARN of the Datadog Lambda created during the Datadog-Amazon Web services Log collection setup. |

## Methods

Expand Down Expand Up @@ -45,7 +45,6 @@ and a boolean to check if the value has been set.

SetAccountId sets AccountId field to given value.


### GetLambdaArn

`func (o *AWSAccountAndLambdaRequest) GetLambdaArn() string`
Expand All @@ -65,8 +64,4 @@ and a boolean to check if the value has been set.

SetLambdaArn sets LambdaArn field to given value.



[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


9 changes: 3 additions & 6 deletions api/v1/datadog/docs/AWSAccountCreateResponse.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@

## Properties

Name | Type | Description | Notes
---- | ---- | ----------- | ------
**ExternalId** | Pointer to **string** | AWS external_id. | [optional]
| Name | Type | Description | Notes |
| -------------- | --------------------- | ---------------- | ---------- |
| **ExternalId** | Pointer to **string** | AWS external_id. | [optional] |

## Methods

Expand Down Expand Up @@ -50,7 +50,4 @@ SetExternalId sets ExternalId field to given value.

HasExternalId returns a boolean if a field has been set.


[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


13 changes: 5 additions & 8 deletions api/v1/datadog/docs/AWSAccountDeleteRequest.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@

## Properties

Name | Type | Description | Notes
---- | ---- | ----------- | ------
**AccessKeyId** | Pointer to **string** | Your AWS access key ID. Only required if your AWS account is a GovCloud or China account. | [optional]
**AccountId** | Pointer to **string** | Your AWS Account ID without dashes. | [optional]
**RoleName** | Pointer to **string** | Your Datadog role delegation name. | [optional]
| Name | Type | Description | Notes |
| --------------- | --------------------- | ----------------------------------------------------------------------------------------- | ---------- |
| **AccessKeyId** | Pointer to **string** | Your AWS access key ID. Only required if your AWS account is a GovCloud or China account. | [optional] |
| **AccountId** | Pointer to **string** | Your AWS Account ID without dashes. | [optional] |
| **RoleName** | Pointer to **string** | Your Datadog role delegation name. | [optional] |

## Methods

Expand Down Expand Up @@ -102,7 +102,4 @@ SetRoleName sets RoleName field to given value.

HasRoleName returns a boolean if a field has been set.


[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


9 changes: 3 additions & 6 deletions api/v1/datadog/docs/AWSAccountListResponse.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@

## Properties

Name | Type | Description | Notes
---- | ---- | ----------- | ------
**Accounts** | Pointer to [**[]AWSAccount**](AWSAccount.md) | List of enabled AWS accounts. | [optional]
| Name | Type | Description | Notes |
| ------------ | -------------------------------------------- | ----------------------------- | ---------- |
| **Accounts** | Pointer to [**[]AWSAccount**](AWSAccount.md) | List of enabled AWS accounts. | [optional] |

## Methods

Expand Down Expand Up @@ -50,7 +50,4 @@ SetAccounts sets Accounts field to given value.

HasAccounts returns a boolean if a field has been set.


[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


Loading

0 comments on commit a715f4c

Please sign in to comment.