Skip to content

Commit

Permalink
alter name style (#2)
Browse files Browse the repository at this point in the history
  • Loading branch information
shiyuhang0 authored May 18, 2023
1 parent 9b5d893 commit 6ac3e77
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 17 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/example.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
token: ${{ secrets.GITHUB_TOKEN }}
public-key: ${{ secrets.TIDB_CLOUD_PUBLIC_KEY }}
private-key: ${{ secrets.TIDB_CLOUD_PRIVATE_KEY }}
addMask: false
add-mask: false
env: dev
- name: Use the output
run: |
Expand Down
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@ with:

The action supports the following inputs:
- token - (required) The GitHub token to use for making API requests. Typically, this would be set to ${{ secrets.GITHUB_TOKEN }}.
- publicKey - (required) The public key of TiDB Cloud api. Generate it from [TiDB Cloud](https://tidbcloud.com/).
- privateKey - (required) The private key of TiDB Cloud api. Generate it from [TiDB Cloud](https://tidbcloud.com/).
- intervalSeconds - (optional) The interval seconds to check the status of TiDB Cloud Branch check. Default is 10.
- timeoutSeconds - (optional) The timeout seconds to wait for TiDB Cloud Branch check. Default is 300.
- addMask - (optional) Whether to add mask for the password output. Default is true.
- public-key - (required) The public key of TiDB Cloud api. Generate it from [TiDB Cloud](https://tidbcloud.com/).
- private-key - (required) The private key of TiDB Cloud api. Generate it from [TiDB Cloud](https://tidbcloud.com/).
- interval-seconds - (optional) The interval seconds to check the status of TiDB Cloud Branch check. Default is 10.
- timeout-seconds - (optional) The timeout seconds to wait for TiDB Cloud Branch check. Default is 300.
- add-mask - (optional) Whether to add mask for the password output. Default is true.

## Outputs

Expand Down Expand Up @@ -75,7 +75,7 @@ jobs:
token: ${{ secrets.GITHUB_TOKEN }}
public-key: ${{ secrets.TIDB_CLOUD_API_PUBLIC_KEY }}
private-key: ${{ secrets.TIDB_CLOUD_API_PRIVATE_KEY }}
addMask: false
add-mask: false
outputs:
username: ${{ steps.wait-for-branch.outputs.username }}
port : ${{ steps.wait-for-branch.outputs.port }}
Expand Down
6 changes: 3 additions & 3 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ inputs:
token:
description: 'The GitHub token to use for making API requests.'
required: true
timeoutSeconds:
timeout-seconds:
description: 'The number of seconds to wait for the branch ready.'
default: '300'
intervalSeconds:
interval-seconds:
description: 'The number of seconds to wait before each check.'
default: '10'
public-key:
Expand All @@ -20,7 +20,7 @@ inputs:
private-key:
description: 'The private key of TiDB Cloud API.'
required: true
addMask:
add-mask:
description: 'Whether to add mask for the output.'
default: 'true'
env:
Expand Down
6 changes: 3 additions & 3 deletions dist/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/index.js.map

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ async function run(): Promise<void> {
repo: context.repo.repo,
ref: context.payload.pull_request.head.sha,

timeoutSeconds: parseInt(core.getInput('timeoutSeconds')),
intervalSeconds: parseInt(core.getInput('intervalSeconds'))
timeoutSeconds: parseInt(core.getInput('timeout-seconds')),
intervalSeconds: parseInt(core.getInput('interval-seconds'))
})

// check result
Expand All @@ -52,7 +52,7 @@ async function run(): Promise<void> {
privateKey,
core.getInput('env')
)
if (core.getInput('addMask') === 'true') {
if (core.getInput('add-mask') === 'true') {
core.info('addMask is true, set secret for sql user password')
core.setSecret(sqlUser.password)
}
Expand Down

0 comments on commit 6ac3e77

Please sign in to comment.