Skip to content

Commit

Permalink
Update inputs
Browse files Browse the repository at this point in the history
  • Loading branch information
alstr committed Dec 6, 2020
1 parent bcb5692 commit 9b0d7c1
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 14 deletions.
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,14 +53,14 @@ Latest version is `v2.4`.

| Input | Default value | Description |
|----------|---------------|-------------|
| `REPO` | "${{ github.repository }}" | The path to the repository where the action will be used, e.g. 'alstr/my-repo' (automatically set) |
| `BEFORE` | "${{ github.event.before }}" | The SHA of the last pushed commit (automatically set) |
| `SHA` | "${{ github.sha }}" | The SHA of the latest commit (automatically set) |
| `TOKEN` | "${{ secrets.GITHUB_TOKEN }}" | The GitHub access token to allow us to retrieve, create and update issues (automatically set) |
| `LABEL` | "# TODO" | The label that will be used to identify TODO comments |
| `COMMENT_MARKER` | "#" | The marker used to signify a line comment in your code |
| `CLOSE_ISSUES` | "true" | Optional input that specifies whether to attempt to close an issue when a TODO is removed |
| `AUTO_P` | "true" | For multiline TODOs, format each line as a new paragraph when creating the issue |
| `REPO` | `"${{ github.repository }}"` | The path to the repository where the action will be used, e.g. 'alstr/my-repo' (automatically set) |
| `BEFORE` | `"${{ github.event.before }}"` | The SHA of the last pushed commit (automatically set) |
| `SHA` | `"${{ github.sha }}"` | The SHA of the latest commit (automatically set) |
| `TOKEN` | `"${{ secrets.GITHUB_TOKEN }}"` | The GitHub access token to allow us to retrieve, create and update issues (automatically set) |
| `LABEL` | `"# TODO"` | The label that will be used to identify TODO comments |
| `COMMENT_MARKER` | `"#"` | The marker used to signify a line comment in your code |
| `CLOSE_ISSUES` | `true` | Optional input that specifies whether to attempt to close an issue when a TODO is removed |
| `AUTO_P` | `true` | For multiline TODOs, format each line as a new paragraph when creating the issue |

## Examples

Expand Down Expand Up @@ -93,7 +93,7 @@ The extra line(s) will be posted in the body of the issue.

The `COMMENT_MARKER` input must be set to the correct syntax (e.g. `#` for Python).

Each line in the multiline TODO will be formatted as a paragraph in the issue body. To disable this, set `AUTO_P` to `"false"`.
Each line in the multiline TODO will be formatted as a paragraph in the issue body. To disable this, set `AUTO_P` to `false`.

### Specifying Identifier

Expand Down
8 changes: 4 additions & 4 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@ inputs:
default: "#"
CLOSE_ISSUES:
description: "Optional input that specifies whether to attempt to close an issue when a TODO is removed"
required: false
default: "true"
required: true
default: true
AUTO_P:
description: "For multiline TODOs, format each line as a new paragraph when creating the issue"
required: false
default: "true"
required: true
default: true
2 changes: 1 addition & 1 deletion main.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ def main():
label = os.getenv('INPUT_LABEL')
token = os.getenv('INPUT_TOKEN')
close_issues = os.getenv('INPUT_CLOSE_ISSUES') == 'true'
auto_p = os.getenv('AUTO_P') == 'true'
auto_p = os.getenv('INPUT_AUTO_P') == 'true'
line_break = '\n\n' if auto_p else '\n'

# Load a file so we can see what language each file is written in and apply highlighting later.
Expand Down

0 comments on commit 9b0d7c1

Please sign in to comment.