try to remove the global flag to git config #10
Workflow file for this run
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
name: Sync with foundries repo | |
on: | |
push: | |
branches: | |
- main | |
- development | |
- feature/add-workflow | |
jobs: | |
sync: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout source repository | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
path: src-repo | |
- name: Checkout destination repository | |
run: | | |
git config user.name arduino-github | |
git config user.email github@arduino.cc | |
git config http.https://source.foundries.io/factories/arduino.extraheader "${FOUNDRIES_ACCESS_TOKEN}" | |
git clone -b ${BRANCH_NAME} ${DESTINATION_REPOSITORY} dest-repo | |
env: | |
DESTINATION_REPOSITORY: https://source.foundries.io/factories/arduino/lmp-manifest.git | |
BRANCH_NAME: ${{ github.base_ref || github.ref_name }} | |
FOUNDRIES_ACCESS_TOKEN: ${{ secrets.FOUNDRIES_ACCESS_TOKEN }} | |
- name: Push changes | |
run: | | |
cd dest-repo | |
echo "DEbug: branch $(git branch) selected" | |
echo "Branch variable is: ${BRANCH_NAME}" | |
env: | |
BRANCH_NAME: ${{ github.base_ref || github.ref_name }} |