#!/usr/bin/env bash

_APP_CORE_DIR="$(dirname "${BASH_SOURCE[0]}")"

# ============================================
# Core Bootstrap
# ============================================

source "${_APP_CORE_DIR}/context.sh"
source "${_APP_CORE_DIR}/json.sh"

export PYTHONPATH="$(ctx::core):${PYTHONPATH:-}"

function app::_load_mixins() {
  local mixin_file
  for mixin_file in "${WGCTL_DIR}/commands/mixins/"*.mixin.sh; do
    [[ -f "$mixin_file" ]] && source "$mixin_file"
  done
}
app::_load_mixins