Skip to content

Commit

Permalink
oops
Browse files Browse the repository at this point in the history
  • Loading branch information
ProducerMatt committed Jun 22, 2024
1 parent a6b957d commit 4f88d2d
Showing 1 changed file with 14 additions and 14 deletions.
28 changes: 14 additions & 14 deletions .github/workflows/elixir.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,17 +91,17 @@ jobs:
run: |
nix develop -c pre-commit run --show-diff-on-failure --color=always --all-files
# # NOTE: the above runs on all files regardless of if they changed. What would be better would be checking only the files in a P.R. that changed.
# # However, my attempt below to do so raises an error saying "unknown revision or path 'main..dev'" and I don't know how to fix it.
# - name: Run pre-commit checks
# env:
# HEAD_REF: ${{ github.head_ref }}
# BASE_REF: ${{ github.base_ref }}
# run: |
# if [[ -n "$HEAD_REF" && -n "$BASE_REF" ]]; then
# git fetch --depth=1 origin "$BASE_REF"
# git fetch --depth=1 origin "$HEAD_REF"
# nix develop -c pre-commit run --show-diff-on-failure --color=always --to-ref "$BASE_REF" --from-ref "$HEAD_REF"
# else
# nix develop -c pre-commit run --show-diff-on-failure --color=always --all-files
# fi
# # NOTE: the above runs on all files regardless of if they changed. What would be better would be checking only the files in a P.R. that changed.
# # However, my attempt below to do so raises an error saying "unknown revision or path 'main..dev'" and I don't know how to fix it.
# - name: Run pre-commit checks
# env:
# HEAD_REF: ${{ github.head_ref }}
# BASE_REF: ${{ github.base_ref }}
# run: |
# if [[ -n "$HEAD_REF" && -n "$BASE_REF" ]]; then
# git fetch --depth=1 origin "$BASE_REF"
# git fetch --depth=1 origin "$HEAD_REF"
# nix develop -c pre-commit run --show-diff-on-failure --color=always --to-ref "$BASE_REF" --from-ref "$HEAD_REF"
# else
# nix develop -c pre-commit run --show-diff-on-failure --color=always --all-files
# fi

0 comments on commit 4f88d2d

Please sign in to comment.