diff --git a/.github/workflows/machete.yml b/.github/workflows/machete.yml index 9e3f555..7bb9c97 100644 --- a/.github/workflows/machete.yml +++ b/.github/workflows/machete.yml @@ -2,7 +2,7 @@ name: machete on: schedule: - - cron: '0 8 * * *' + - cron: "0 8 * * *" workflow_dispatch: permissions: @@ -63,14 +63,14 @@ jobs: git push https://x-access-token:${{ secrets.DELTA_BOT_GH_TOKEN }}@github.com/${{ github.repository }} $BRANCH_NAME echo "Changes committed and pushed to $BRANCH_NAME" echo "Attempting to create a pull request..." - + # Create a pull request PR_URL=$(gh pr create --base master --head $BRANCH_NAME --title "Fix unused dependencies" --body "This PR fixes unused dependencies found by cargo machete." --draft=false --label "dependencies") echo "Pull request created: $PR_URL" - + # Automatically merge the pull request after it meets the requirements - gh pr merge "$PR_URL" --merge --delete-branch + gh pr merge "$PR_URL" --squash --delete-branch echo "Pull request merged and branch deleted." else echo "No changes detected. No commit or push." - fi \ No newline at end of file + fi