Skip to content

Commit

Permalink
Use -n test instead of -z to determine dbt environment in workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
jeancochrane committed Aug 8, 2023
1 parent bbc4887 commit 310645e
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions .github/actions/configure_dbt_environment/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,8 @@ runs:
- name: Configure dbt environment
run: |
# GITHUB_HEAD_REF is only set on pull_request events, so if it's
# present, we must be in a PR context. Use the +x param expansion
# to distinguish empty strings: https://stackoverflow.com/a/13864829
if [ ! -z ${GITHUB_HEAD_REF+x} ]; then
# present, we must be in a PR context
if [ -n "$GITHUB_HEAD_REF" ]; then
echo "On pull request branch, setting dbt env to CI"
{
echo "TARGET=ci";
Expand Down

0 comments on commit 310645e

Please sign in to comment.