Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
zachmayer committed Nov 30, 2024
1 parent d7ba3ab commit 0b38442
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/R-CMD-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,15 @@ jobs:
- id: check-files
run: |
if [ "${{ github.event_name }}" = "push" ]; then
echo "run-r-checks=true" >> "$GITHUB_OUTPUT"
echo "run-r-checks=true" >> "${GITHUB_OUTPUT}"
else
# Check if any R-related files changed
git fetch origin "${{ github.base_ref }}"
CHANGED_FILES="$(git diff --name-only "origin/${{ github.base_ref }}"..HEAD)"
if echo "$CHANGED_FILES" | grep -qE '^(R/|data/|tests/|vignettes/|DESCRIPTION|NAMESPACE)'; then
echo "run-r-checks=true" >> "$GITHUB_OUTPUT"
if echo "${CHANGED_FILES}" | grep -qE '^(R/|data/|tests/|vignettes/|DESCRIPTION|NAMESPACE)'; then
echo "run-r-checks=true" >> "${GITHUB_OUTPUT}"
else
echo "run-r-checks=false" >> "$GITHUB_OUTPUT"
echo "run-r-checks=false" >> "${GITHUB_OUTPUT}"
fi
fi
Expand Down Expand Up @@ -56,9 +56,9 @@ jobs:
id: should-run
run: |
if [ "${{ needs.check-if-r-changes.outputs.run-r-checks }}" = "true" ]; then
echo "should_run=true" >> $GITHUB_OUTPUT
echo "should_run=true" >> "${GITHUB_OUTPUT}"
else
echo "should_run=false" >> $GITHUB_OUTPUT
echo "should_run=false" >> "${GITHUB_OUTPUT}"
fi
- name: Skip Check
Expand Down

0 comments on commit 0b38442

Please sign in to comment.