diff --git a/.github/scripts/psycopg2-check.sh b/.github/scripts/psycopg2-check.sh index a3e99ada..faee902c 100755 --- a/.github/scripts/psycopg2-check.sh +++ b/.github/scripts/psycopg2-check.sh @@ -3,7 +3,7 @@ source venv/bin/activate python -m pip install . if [[ "$PSYCOPG2_WORKAROUND" == true ]]; then - if [[ pip show psycopg2-binary ]]; then + if [[ $(pip show psycopg2-binary) ]]; then PSYCOPG2_VERSION=$(pip show psycopg2-binary | grep Version | cut -d " " -f 2) pip uninstall -y psycopg2-binary pip install psycopg2==$PSYCOPG2_VERSION diff --git a/README.md b/README.md index 2e66dc64..285f5144 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,7 @@ more information on using dbt with Postgres, consult [the docs](https://docs.get By default, `dbt-postgres` installs `psycopg2-binary`. This is great for development, and even testing, as it does not require any OS dependencies; it's a pre-built wheel. However, building `psycopg2` from source will grant performance improvements that are desired in a production environment. In order to install `psycopg2`, use the following steps: ```bash -if [[ pip show psycopg2-binary ]]; then +if [[ $(pip show psycopg2-binary) ]]; then PSYCOPG2_VERSION=$(pip show psycopg2-binary | grep Version | cut -d " " -f 2) pip uninstall -y psycopg2-binary pip install psycopg2==$PSYCOPG2_VERSION