Skip to content

Commit

Permalink
update gpt-translate.yml
Browse files Browse the repository at this point in the history
Check all conditions before starting job
  • Loading branch information
thias15 authored Jun 2, 2024
1 parent 6eb23a9 commit 8a395e4
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/gpt-translate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,16 @@ on:

jobs:
gpt_translate:
if: github.actor == 'thias15'
if: |
github.actor == 'thias15' &&
contains(github.event.comment.body, '/gpt-translate') ||
contains(github.event.comment.body, '/gt')
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- name: Run GPT Translate
if: |
contains(github.event.comment.body, '/gpt-translate') ||
contains(github.event.comment.body, '/gt')
uses: 3ru/gpt-translate@master
with:
apikey: ${{ secrets.OPENAI_API_KEY }}
Expand Down

0 comments on commit 8a395e4

Please sign in to comment.