diff --git a/.github/workflows/copy-content.yml b/.github/workflows/copy-content.yml index fcaaa81d..6dfd9f81 100644 --- a/.github/workflows/copy-content.yml +++ b/.github/workflows/copy-content.yml @@ -54,6 +54,7 @@ jobs: repository: ${{ inputs.repo }} token: ${{ secrets.PAT }} ref: ${{ inputs.branch }} + fetch-depth: 0 - name: Checkout destination repo (Branch doesn't exist) uses: actions/checkout@v4 @@ -62,6 +63,7 @@ jobs: path: "destination" repository: ${{ inputs.repo }} token: ${{ secrets.PAT }} + fetch-depth: 0 - name: Create branch in destination repo if: ${{ steps.check_branch.outputs.branch_exists == 0 }} @@ -89,15 +91,16 @@ jobs: git config --global user.email "zeta-icons-bot@github.com" git add -A - - name: Check if there are changes - id: changed - run: | - cd destination - git diff --quiet . || echo "changed=true" >> $GITHUB_OUTPUT + - name: Get changed files + id: changes + uses: tj-actions/changed-files@v45 + with: + path: destination - name: Commit and push changes - if: steps.changed.outputs.changed == 'true' + if: steps.changes.outputs.any_changed == 'true' run: | + cd destination git commit -m "deps(automated): ${{inputs.commit_msg}} ${{ steps.date.outputs.date }}" git push --set-upstream origin ${{inputs.branch}} -f diff --git a/.github/workflows/update_zds_android.yml b/.github/workflows/update_zds_android.yml index ba55f54d..9ce94674 100644 --- a/.github/workflows/update_zds_android.yml +++ b/.github/workflows/update_zds_android.yml @@ -14,7 +14,7 @@ jobs: with: repo: ZebraDevs/zds-android branch: "update-zeta-icons" - source_dir: "./outputs/android/." + source_dir: "outputs/android" destination_dir: "components/src/main/res/drawable" commit_msg: "Update icons" prerun: rm -f components/src/main/res/drawable/ic_*.xml