feat: use DBT_PROFILES_DIR env var as dbt profiles dir (if defined)#256
Conversation
…ir (if not defined, defaults to ~/.dbt)
for more information, see https://pre-commit.ci
|
Thanks a lot for the PR @smomni As you say I think it's ok not to have a unit test on this as it's trivial and that line is kind of covered. I might write a test case for it at a later point though. It looks like the CI is failing for a weird reason so I'm gonna take a quick looksie. In the meantime would you mind writing a news fragment for our changelog? you can follow the instructions here to do that: https://github.com/bitpicky/dbt-sugar/blob/main/CONTRIBUTING.md#shout-out-your-hardwork-in-the-changelog It's going to be a feature so the name of that news fragment file should be |
…-sugar into dbt-profiles-dir-from-env-var
for more information, see https://pre-commit.ci
Sourcery Code Quality Report❌ Merging this PR will decrease code quality in the affected files by 1.30%.
Here are some functions in these files that still need a tune-up:
Legend and ExplanationThe emojis denote the absolute quality of the code:
The 👍 and 👎 indicate whether the quality has improved or gotten worse with this pull request. Please see our documentation here for details on how these metrics are calculated. We are actively working on this report - lots more documentation and extra metrics to come! Let us know what you think of it by mentioning @sourcery-ai in a comment. |
|
@bastienboutonnet There's now a changelog entry :) |
|
Awesome @smomni ! Thanks a lot for this. Strangely enough the CI passes locally so that's a bit strange. I'm gonna to ahead and merge your branch. I'm planning to make a new alpha release soon, but we (long story) merged what looks like a regression on master so we'll want to fix that before we release. I'll ping you in the issue when that is done if you want? |
|
Thanks, this was probably the smallest contribution I've ever made 😄 Sure thing, ping me if there's anything! |
|
@smomni the new alpha build contains your changes: https://github.com/bitpicky/dbt-sugar/releases/tag/v0.1.0-a.3 Thanks a lot for the hard work and happy testing! |

Description
Implemented support for the
DBT_PROFILES_DIRenv var. If the variable is not defined, the profiles dir defaults to~/.dbt.How was the change tested
I manually checked that the profiles directory was resolved as
DBT_PROFILES_DIRenv var. Unfortunately, I didn't write any unit tests as the change seems trivial.Issue Information
Closes #255
Checklist
(Ideally, all boxes are checked by the time we merged the PR, if you don't know how to do any of these don't hesitate to say so in the PR and we'll help you out.)