Skip to content

Commit

Permalink
feat: prepare to implement different methods
Browse files Browse the repository at this point in the history
  • Loading branch information
williamdes committed Apr 5, 2020
1 parent e4fcd75 commit 6f1a937
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,5 @@ This action locks a pull-request
fork-url: "https://${{ secrets.BOT_TOKEN }}:[email protected]/myname/officialproject-fork.git"
dry-run: "true" # remove this line to make sync effective
clone-depth: "100" # optional, defaults to 100
sync-method: "fast-forward" # optional, defaults to "fast-forward". Can be "rebase", "merge" or "fast-forward".
```
7 changes: 6 additions & 1 deletion action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,16 +19,21 @@ inputs:
description: "Use dry-run mode"
required: false
default: "false"
sync-method:
description: "Update fork method"
required: false
default: "fast-forward"

branding:
icon: "git-branch"
color: blue
runs:
using: "docker"
image: "docker://botsudo/action-fork-sync:v1.0.4"
image: "docker://botsudo/action-fork-sync:v1.0.5"
args:
- ${{ inputs.clone-depth }}
- "${{ inputs.branches }}"
- "${{ inputs.source-url }}"
- "${{ inputs.fork-url }}"
- ${{ inputs.dry-run }}
- ${{ inputs.sync-method }}
1 change: 1 addition & 0 deletions entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ BRANCHES="$2"
SOURCE_URL="$3"
FORK_URL="$4"
DRY_RUN="$5"
METHOD="$6"

echo "::debug DEPTH: ${DEPTH}"
echo "::debug BRANCHES: ${BRANCHES}"
Expand Down

0 comments on commit 6f1a937

Please sign in to comment.