Skip to content
This repository has been archived by the owner on Jun 4, 2022. It is now read-only.

Commit

Permalink
Fix GITHUB_REPOSITORY access
Browse files Browse the repository at this point in the history
  • Loading branch information
core23 committed Feb 14, 2021
1 parent 90ef879 commit a900fda
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Expand Up @@ -19,4 +19,4 @@ ADD . /app/

RUN COMPOSER_CACHE_DIR=/dev/null composer install --no-dev --no-scripts

ENTRYPOINT ["/app/auto-merge"]
ENTRYPOINT ["/app/entrypoint.sh"]
11 changes: 8 additions & 3 deletions action.yml
Expand Up @@ -9,11 +9,18 @@ branding:
color: 'green'

inputs:
github_token:
description: 'Token for the repo. Can be passed in using $\{{ secrets.GITHUB_TOKEN }}'
required: true
repository:
description: 'Repository name to check. Default or empty value represents current github repository (${GITHUB_REPOSITORY})'
default: ''
required: false
label:
description: 'Label that indicates a pull request for merge.'
required: false
default: 'automerge'
ignore-label:
ignore_label:
description: 'Label that forbids a merge.'
required: false
default: 'wip'
Expand All @@ -24,5 +31,3 @@ inputs:
runs:
using: 'docker'
image: 'Dockerfile'
args:
- "-l ${{ inputs.label }} -i ${{ inputs.ignore-label }} ${{ inputs.options }} ${{ inputs.GITHUB_REPOSITORY }}"
5 changes: 5 additions & 0 deletions entrypoint.sh
@@ -0,0 +1,5 @@
#!/bin/sh

REPOSITORY=${INPUT_REPOSITORY:-$GITHUB_REPOSITORY}

GITHUB_TOKEN=${INPUT_GITHUB_TOKEN} /app/auto-merge -l ${INPUT_LABEL} -i ${INPUT_IGNORE_LABEL} ${INPUT_OPTIONS} ${REPOSITORY}

0 comments on commit a900fda

Please sign in to comment.