diff --git a/.github/workflows/golangci-lint.yml b/.github/workflows/golangci-lint.yml index 6a6ce9fd8c..d3e032e02b 100644 --- a/.github/workflows/golangci-lint.yml +++ b/.github/workflows/golangci-lint.yml @@ -33,6 +33,12 @@ jobs: go-version-file: .go-version #go-version: '1.21' cache: false + + - name: Get root path + id: getRootPath + run: | + echo "::set-output path=$(pwd)" + shell: bash - name: Get list of changed files id: getDiffFile @@ -58,6 +64,6 @@ jobs: uses: golangci/golangci-lint-action@v3 with: version: v1.63.4 - working-directory: . + working-directory: ${{ steps.getRootPath.outputs.path }} args: --new-from-rev=origin/master -v ${{ steps.getDiffFile.outputs.files }} #args: --enable-all --max-same-issues=0 --max-issues-per-linter=0 --new-from-rev=origin/master -v diff --git a/.golangci.yml b/.golangci.yml index 831b35d913..800979b11e 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -10,28 +10,25 @@ issues: linters: disable-all: true enable: - - deadcode - errcheck - gofmt - gosimple - ineffassign - misspell - staticcheck - - structcheck - unconvert - unused - - varcheck - vet linters-settings: errcheck: - ignore: github.com/hashicorp/terraform-plugin-sdk/helper/schema:ForceNew|Set,fmt:.*,io:Close + exclude-functions: github.com/hashicorp/terraform-plugin-sdk/helper/schema:ForceNew|Set,fmt:.*,io:Close run: modules-download-mode: vendor timeout: 60m # The default concurrency value is the number of available CPU. - concurrency: 12 + concurrency: 2 # Allow multiple parallel golangci-lint instances running. # If false (default) - golangci-lint acquires file lock on start. allow-parallel-runners: true diff --git a/tencentcloud/provider.go b/tencentcloud/provider.go index b669f8f273..3ac977c744 100644 --- a/tencentcloud/provider.go +++ b/tencentcloud/provider.go @@ -172,13 +172,13 @@ func Provider() *schema.Provider { Type: schema.TypeString, Optional: true, DefaultFunc: schema.EnvDefaultFunc(PROVIDER_SECRET_ID, nil), - Description: "This is the TencentCloud access key. It can also be sourced from the `TENCENTCLOUD_SECRET_ID` environment variable.", + Description: "111This is the TencentCloud access key. It can also be sourced from the `TENCENTCLOUD_SECRET_ID` environment variable.", }, "secret_key": { Type: schema.TypeString, Optional: true, DefaultFunc: schema.EnvDefaultFunc(PROVIDER_SECRET_KEY, nil), - Description: "This is the TencentCloud secret key. It can also be sourced from the `TENCENTCLOUD_SECRET_KEY` environment variable.", + Description: "111This is the TencentCloud secret key. It can also be sourced from the `TENCENTCLOUD_SECRET_KEY` environment variable.", Sensitive: true, }, "security_token": { diff --git a/tencentcloud/services/audit/data_source_tc_audit_cos_regions.go b/tencentcloud/services/audit/data_source_tc_audit_cos_regions.go index 411496b219..34e6e4708b 100644 --- a/tencentcloud/services/audit/data_source_tc_audit_cos_regions.go +++ b/tencentcloud/services/audit/data_source_tc_audit_cos_regions.go @@ -21,12 +21,12 @@ func DataSourceTencentCloudAuditCosRegions() *schema.Resource { "result_output_file": { Type: schema.TypeString, Optional: true, - Description: "Used to save results.", + Description: "123Used to save results.", }, "audit_cos_region_list": { Type: schema.TypeList, Computed: true, - Description: "List of available regions supported by audit cos.", + Description: "123List of available regions supported by audit cos.", Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "cos_region": { diff --git a/tencentcloud/services/bh/resource_tc_dasb_acl.go b/tencentcloud/services/bh/resource_tc_dasb_acl.go index 880d001c13..c2cb9dacfc 100644 --- a/tencentcloud/services/bh/resource_tc_dasb_acl.go +++ b/tencentcloud/services/bh/resource_tc_dasb_acl.go @@ -28,7 +28,7 @@ func ResourceTencentCloudDasbAcl() *schema.Resource { "name": { Required: true, Type: schema.TypeString, - Description: "Acl name.", + Description: "123Acl name.", }, "allow_disk_redirect": { Required: true,