Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Release] Stage to Main #194

Merged
merged 2 commits into from
Apr 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 24 additions & 3 deletions .github/workflows/graybox-sync-repos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,14 @@ name: Graybox Repo Sync

on:
workflow_dispatch:
inputs:
syncBranch:
description: 'Branch to sync'
required: true
default: 'stage'
type: choice
options:
- 'stage'

jobs:
build:
Expand All @@ -20,10 +28,20 @@ jobs:
uses: actions/checkout@v2
with:
persist-credentials: false
ref: ${{ inputs.syncBranch }}

- name: Clone Graybox Repository
- name: Clone Graybox Repository and Checkout Stage Branch
run: |
git clone https://github.com/adobecom/bacom-graybox.git ../bacom-graybox
cd ../bacom-graybox
git checkout $GB_SYNC_BRANCH
echo "bacom-graybox branch"
git branch
cd ../bacom
echo "bacom branch"
git branch
env:
GB_SYNC_BRANCH: ${{ inputs.syncBranch }}

- name: Overwrite graybox repo files with latest from source repo
run: |
Expand All @@ -32,14 +50,17 @@ jobs:
- name: Commit and Push Changes to Graybox Repository
run: |
cd ../bacom-graybox
echo "bacom-graybox branch"
git branch
git config user.email "$FG_SYNC_BOT_EMAIL"
git config user.name "graybox-repo-sync[bot]"
git config user.name "milo-repo-sync[bot]"
git status
git remote set-url origin https://oauth2:[email protected]/adobecom/bacom-graybox.git
git remote -v
git add .
git commit -m "Syncing bacom to bacom-graybox"
git push origin main --force
git push origin $GB_SYNC_BRANCH --force
env:
GITHUB_TOKEN: ${{ steps.generate_token.outputs.token }}
FG_SYNC_BOT_EMAIL: ${{ secrets.FG_SYNC_BOT_EMAIL }}
GB_SYNC_BRANCH: ${{ inputs.syncBranch }}
3 changes: 3 additions & 0 deletions .hlxignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
*.json
!*/**/*.json
.*
*.md
LICENSE
test/*
web-test-runner.config.mjs
Loading