This repository has been archived by the owner on Jul 25, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
26 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,33 @@ | ||
name: Sync to Upstream | ||
|
||
on: | ||
schedule: | ||
- cron: "0 2 * * *" | ||
schedule: | ||
- cron: '0 7 * * 1,4' | ||
# scheduled at 07:00 every Monday and Thursday | ||
workflow_dispatch: | ||
|
||
jobs: | ||
forkbacon: | ||
name: forkbacon | ||
sync_with_upstream: | ||
runs-on: ubuntu-latest | ||
name: Sync HEAD with upstream latest | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: shitiomatic/[email protected] # Prefer using tagged version | ||
if: github.repository_owner != 'open-sauced' | ||
# Step 1: run a standard checkout action, provided by github | ||
- name: Checkout HEAD | ||
uses: actions/checkout@v2 | ||
with: | ||
ref: main | ||
|
||
# Step 2: run this sync action - specify the upstream repo, upstream branch to sync with, and target sync branch | ||
- name: Pull upstream changes | ||
id: sync | ||
uses: bdougie/Fork-Sync-With-Upstream-action@fork | ||
with: | ||
upstream_url: "https://github.com/open-sauced/goals-template/" # Required! Upstream https clone URL | ||
upstream_branch: "master" # Upstream Branch to use | ||
branch: "master" # Local Branch | ||
method: "rebase" # Method to use. Can be `merge`, `merge-ff-only` or `rebase`. | ||
args: "--no-push" # Additional Arguments to pass to the container | ||
upstream_repository: open-sauced/open-sauced | ||
upstream_branch: main | ||
target_branch: main # optional | ||
github_token: ${{ secrets.GITHUB_TOKEN }} # optional, for accessing repos that requir authentication | ||
|
||
# Step 3: Print a helpful timestamp for your records (optional) | ||
- name: Timestamp | ||
run: date |