Skip to content

Commit

Permalink
lgtm
Browse files Browse the repository at this point in the history
  • Loading branch information
Doarakko committed Dec 29, 2021
0 parents commit c5e6bb7
Show file tree
Hide file tree
Showing 16 changed files with 12,124 additions and 0 deletions.
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
dist/
20 changes: 20 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@

{
"env": {
"commonjs": true,
"es6": true,
"jest": true,
"node": true
},
"extends": "eslint:recommended",
"globals": {
"Atomics": "readonly",
"SharedArrayBuffer": "readonly"
},
"parserOptions": {
"ecmaVersion": 2018,
"sourceType": "module"
},
"rules": {
}
}
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
dist/** -diff linguist-generated=true
20 changes: 20 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: LGTM
on:
issue_comment:
types: [created]
pull_request_review:
types: [submitted]
pull_request_review_comment:
types: [created]

jobs:
lgtm:
runs-on: ubuntu-latest
steps:
- name: LGTM
uses: Doarakko/test@main
if: >-
contains(github.event.comment.body, 'lgtm')
|| contains(github.event.review.body, 'lgtm')
with:
github-token: ${{secrets.GITHUB_TOKEN}}
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
node_modules
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2021 Peperoncino

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
44 changes: 44 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# action-lgtmoon

Post LGTM image on GitHub Issue and Pull request using [LGTMoon](https://github.com/yoshikyoto/lgtmoon).

![example](./example.gif)

## Inputs

### `github-token`

**Required** The GitHub token used to create an authenticated client.

## Example usage

```yaml
name: LGTM
on:
issue_comment:
types: [created]
pull_request_review:
types: [submitted]
pull_request_review_comment:
types: [created]

jobs:
lgtm:
runs-on: ubuntu-latest
steps:
- name: LGTM
uses: Doarakko/test@main
if: >-
contains(github.event.comment.body, 'lgtm')
|| contains(github.event.review.body, 'lgtm')
with:
github-token: ${{secrets.GITHUB_TOKEN}}
```
## Demo
Please comment or review "lgtm" to [this issue](https://github.com/Doarakko/action-lgtmoon/issues/1) and [this pull request](https://github.com/Doarakko/action-lgtmoon/pull/1)!
# Credit
- [LGTMoon](https://lgtmoon.dev/)
13 changes: 13 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: "LGTMoon on GitHub Issue and Pull request"
description: "Post LGTM image on GitHub Issue and Pull request using LGTMoon."
branding:
icon: moon
color: gray-dark
inputs:
github-token:
description: The GitHub token used to create an authenticated client
default: ${{ github.token }}
required: true
runs:
using: "node12"
main: "dist/index.js"
Loading

0 comments on commit c5e6bb7

Please sign in to comment.