

# Name your project! Project names should contain only lowercase characters
# and underscores. A good package name should reflect your organization's
# name or the intended use of these models
name: 'shopify_global_schema'
version: '1.0.0'

# This setting configures which "profile" dbt uses for this project.
profile: 'shopify_global_schema'

# These configurations specify where dbt should look for different types of files.
# The `model-paths` config, for example, states that models in this project can be
# found in the "models/" directory. You probably won't need to change these!
model-paths: ["models"]
analysis-paths: ["analyses"]
test-paths: ["tests"]
seed-paths: ["seeds"]
macro-paths: ["macros"]
snapshot-paths: ["snapshots"]

clean-targets:         # directories to be removed by `dbt clean`
  - "target"
  - "dbt_packages"

# Centralized exclusion list for dbt output schemas (SHOPIFY_STORES_GLOBAL database)
# Used by macros to avoid reading own output back as source data
vars:
  d2c_output_schema_exclusions:
    - 'SHOPIFY_GLOBAL_SCHEMA'
    - 'SHOPIFY_GLOBAL_SCHEMA_VIEWS'
    - 'QA_SHOPIFY_STORE_SCHEMA'
    - 'QA_SHOPIFY_STORE_SCHEMA_VIEWS'
    - 'INFORMATION_SCHEMA'

on-run-end:
  - "{{ apply_masking_policies() }}"

# Configuring models
# Full documentation: https://docs.getdbt.com/docs/configuring-models

# In this example config, we tell dbt to build all models in the example/
# directory as views. These settings can be overridden in the individual model
# files using the `{{ config(...) }}` macro.
seeds:
  shopify_global_schema:
    +quote_columns: false

models:
  +persist_docs:
    relation: true
    columns: true
  shopify_global_schema:
    core:
      +materialized: table
      +transient: false
      +tags: ["staging"]
    mart:
      +materialized: table
      +transient: false
      +tags: ["mart"]
    mart_views:
      +materialized: view
      +schema: views
      +tags: ["mart_views"]
