From a66541e40892add096c84804d410b78be6faea1d Mon Sep 17 00:00:00 2001 From: Alfredo Date: Tue, 17 Dec 2024 14:45:34 +0100 Subject: [PATCH] run format on push to main --- .github/workflows/tests.yml | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index b4e95c7..71ef693 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -5,7 +5,7 @@ on: types: - opened - edited - branches: + branches: - main push: branches: @@ -28,11 +28,11 @@ jobs: - name: Switch branch run: | - HEAD_REF="${{ github.head_ref }}" - if [ "$HEAD_REF" != "" && "$HEAD_REF" != "main" ]; then - git fetch origin $HEAD_REF - git switch $HEAD_REF - fi + HEAD_REF="${{ github.head_ref }}" + if [ "$HEAD_REF" != "" && "$HEAD_REF" != "main" ]; then + git fetch origin $HEAD_REF + git switch $HEAD_REF + fi - name: Run linter run: deno task lint @@ -42,10 +42,10 @@ jobs: - name: Upload changes to base branch run: | - HEAD_REF="${{ github.head_ref }}" - if [ "$HEAD_REF" != "" && "$HEAD_REF" != "main" ]; then - git config user.name "github-actions" - git config user.email "github-actions@github.com" - git commit -am "deno formatting" - git push - fi + HEAD_REF="${{ github.head_ref }}" + if [ "$HEAD_REF" != "main" ]; then + git config user.name "github-actions" + git config user.email "github-actions@github.com" + git commit -am "deno formatting" + git push + fi