Skip to content

Instantly share code, notes, and snippets.

@dataders
Last active February 24, 2022 05:47
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dataders/5cf876d88c7c8d268d8c1e1e5d05bffd to your computer and use it in GitHub Desktop.
Save dataders/5cf876d88c7c8d268d8c1e1e5d05bffd to your computer and use it in GitHub Desktop.
.vscode folder for getting started with dbt in VSCode
{
"recommendations": [
"ms-python.python",
"mechatroner.rainbow-csv",
"samuelcolvin.jinjahtml",
"bastienboutonnet.vscode-dbt",
"amodio.find-related"
]
}
{
// change this for your desired path!
"python.pythonPath": "./.dbtenv/bin/python",
// this is to render Jinja in your .sql files
// it will also not-render any sql files in the target folder.
// this is to make things easier
"files.associations": {
"*.sql": "jinja-sql",
"**/target/**": ""
},
// this is so you can easily jump to your compiled SQL files
"findrelated.workspaceRulesets": [
{
"name": "sql",
"rules": [
{
"pattern": "^(.*/)?models/(.*/)?(.+\\.sql)$",
"locators": [
"**/compiled/**/$3"
]
},
{
"pattern": "^(.*/)?compiled/(.*/)?(.+\\.sql)$",
"locators": [
"**/run/**/$3"
]
},
{
"pattern": "^(.*/)?run/(.*/)?(.+\\.sql)$",
"locators": [
"**/models/**/$3"
]
}
]
}
],
"findrelated.applyRulesets": [
"sql"
],
// I personally like these settings
// easier to see if there are unsaved changed
"workbench.editor.highlightModifiedTabs": true,
// make Command Prompt the default shell for Windows
"terminal.integrated.shell.windows": "C:\\Windows\\System32\\cmd.exe",
"editor.rulers": [80],
"editor.renderWhitespace": "all",
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment