Skip to content

Commit

Permalink
chore: update sync upstream script (#236)
Browse files Browse the repository at this point in the history
Signed-off-by: tomoya.kimura <[email protected]>
  • Loading branch information
tkimura4 authored Sep 12, 2023
1 parent 6d4af73 commit 360ef0f
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions .github/workflows/sync-awf-upstream.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
name: sync-awf-upstream

on:
schedule:
- cron: 0 1 * * 1-5
workflow_dispatch:
inputs:
target_branch:
description: Target branch
required: true
type: string

jobs:
sync-awf-upstream:
Expand All @@ -29,12 +32,17 @@ jobs:
const holiday_jp = require(`${process.env.GITHUB_WORKSPACE}/node_modules/@holiday-jp/holiday_jp`)
core.setOutput('holiday', holiday_jp.isHoliday(new Date()));
- name: Print warning for invalid branch name
if: ${{ inputs.target_branch == 'tier4/main' }}
run: |
echo This action cannot be performed on 'tier4/main' branch
- name: Run sync-branches
uses: autowarefoundation/autoware-github-actions/sync-branches@v1
if: ${{ steps.is-holiday.outputs.holiday != 'true' || github.event_name == 'workflow_dispatch' }}
if: ${{ inputs.target_branch != 'tier4/main' }}
with:
token: ${{ steps.generate-token.outputs.token }}
base-branch: tier4/main
base-branch: ${{ inputs.target_branch }}
sync-pr-branch: sync-awf-upstream
sync-target-repository: https://github.com/autowarefoundation/autoware_launch.git
sync-target-branch: main
Expand Down

0 comments on commit 360ef0f

Please sign in to comment.