One github theme for multiple stores

manuelpineda
Shopify Partner
6 0 2

I am trying to integrate a github theme for multiple stores. I am using a workflow to deploy changes to all the  themes each store is linked to a branh. I am ruinning into the issue that whenever I modify the template on my main branch it overwrites it on all the other branches affecting all other stores. 

 

name: Pushing to all live branches

on:
  push:
    branches:
      - main
    paths-ignore:
      - 'templates/**'
      - 'config/**'
env:
  STORES: "test-store"
  
jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout code
        uses: actions/checkout@v3
        
      - name: Push changes to live branches
        run: |
          for branch in ${STORES}
          do
            git checkout main
            git pull
            git checkout -b live/$branch
            git push -f --set-upstream origin live/$branch
          done
Replies 0 (0)