File size: 588 Bytes
d15f07c
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/usr/bin/env bash
# Run dbt using the repo-root dbt_project.yml (for Cursor / IDE) while still loading
# profiles.yml from dbt_project/. Without DBT_PROFILES_DIR, dbt falls back to ~/.dbt
# and seeds/runs often hit a different database than Neon.
#
# Usage (from repo root):
#   ./scripts/dbt-root.sh seed --select jurisdiction_website_url_overrides
#   ./scripts/dbt-root.sh run --select int_jurisdiction_websites
set -euo pipefail
ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
export DBT_PROFILES_DIR="${ROOT}/dbt_project"
cd "${ROOT}"
exec "${ROOT}/.venv-dbt/bin/dbt" "$@"