refactor(15 single-star batch 3): selective imports + dead drop (ADR-025 L2)
15 files. Most are dead `use ../config/accessor.nu *` imports dropped. Selective imports: setup/utils.nu config/accessor/functions [get-providers-path] setup/detection.nu setup/mod [8 symbols] plugins/secretumvault.nu config/accessor/core [config-get] plugins/orchestrator.nu config/accessor/core [config-get] kms/client.nu utils/error + utils/interface + plugins/kms deploy.nu result.nu [7 symbols] dependencies/resolver.nu config/loader [get-config] Dead imports dropped: setup/config.nu config/accessor extensions/profiles.nu config/accessor extensions/loader.nu config/accessor workspace/init.nu config/accessor utils/help.nu config/accessor utils/error_fixed.nu config/accessor utils/error_clean.nu config/accessor utils/error_final.nu config/accessor dependencies/resolver.nu oci/client Validation: all 15 match or IMPROVE baseline: - 11 files: 0 errors - utils/error_fixed 4 -> 1 (IMPROVED) - utils/error_clean 4 -> 1 (IMPROVED) - dependencies/resolver 50 = 50 (unchanged pre-existing noise) - deploy.nu 19 = 19 (unchanged; file is orphaned — zero importers) Refs: ADR-025
This commit is contained in:
parent
e5ffc55104
commit
1ac3401315
15 changed files with 29 additions and 21 deletions
|
|
@ -2,8 +2,8 @@
|
||||||
# Handles dependency resolution across multiple repositories with OCI support
|
# Handles dependency resolution across multiple repositories with OCI support
|
||||||
# Version: 1.0.0
|
# Version: 1.0.0
|
||||||
|
|
||||||
use ../config/loader.nu get-config
|
# oci/client star-import was dead — dropped (ADR-025 Phase 3 Layer 2).
|
||||||
use ../oci/client.nu *
|
use lib_provisioning/config/loader.nu [get-config]
|
||||||
use std log
|
use std log
|
||||||
|
|
||||||
# Dependency resolution cache
|
# Dependency resolution cache
|
||||||
|
|
|
||||||
|
|
@ -5,8 +5,9 @@
|
||||||
# Features: Regional health checks, VPN tunnels, global DNS, failover configuration
|
# Features: Regional health checks, VPN tunnels, global DNS, failover configuration
|
||||||
# Error handling: Result pattern (hybrid, no inline try-catch)
|
# Error handling: Result pattern (hybrid, no inline try-catch)
|
||||||
|
|
||||||
use lib_provisioning/result.nu *
|
# Selective imports (ADR-025 Phase 3 Layer 2).
|
||||||
use ./utils/nickel_processor.nu [ncl-eval-soft]
|
use lib_provisioning/result.nu [bash-wrap err is-err is-ok match-result ok try-wrap]
|
||||||
|
use lib_provisioning/utils/nickel_processor.nu [ncl-eval-soft]
|
||||||
|
|
||||||
def main [--debug: bool = false, --region: string = "all"] {
|
def main [--debug: bool = false, --region: string = "all"] {
|
||||||
print "🌍 Multi-Region High Availability Deployment"
|
print "🌍 Multi-Region High Availability Deployment"
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
|
|
||||||
# Extension Loader
|
# Extension Loader
|
||||||
# Discovers and loads extensions from multiple sources
|
# Discovers and loads extensions from multiple sources
|
||||||
use ../config/accessor.nu *
|
# config/accessor star-import was dead — dropped (ADR-025 Phase 3 Layer 2).
|
||||||
|
|
||||||
# Extension discovery paths in priority order
|
# Extension discovery paths in priority order
|
||||||
export def get-extension-paths [] {
|
export def get-extension-paths [] {
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
# Profile-based Access Control
|
# Profile-based Access Control
|
||||||
# Implements permission system for restricted environments like CI/CD
|
# Implements permission system for restricted environments like CI/CD
|
||||||
use ../config/accessor.nu *
|
# config/accessor star-import was dead — dropped (ADR-025 Phase 3 Layer 2).
|
||||||
|
|
||||||
# Load profile configuration
|
# Load profile configuration
|
||||||
export def load-profile [profile_name?: string] {
|
export def load-profile [profile_name?: string] {
|
||||||
|
|
|
||||||
|
|
@ -3,10 +3,10 @@
|
||||||
# Prioritizes plugin-based implementations for 10x performance improvement
|
# Prioritizes plugin-based implementations for 10x performance improvement
|
||||||
|
|
||||||
use std log
|
use std log
|
||||||
use ../config/accessor.nu *
|
# config/accessor star-import was dead — dropped (ADR-025 Phase 3 Layer 2).
|
||||||
use ../utils/error.nu throw-error
|
use lib_provisioning/utils/error.nu [throw-error]
|
||||||
use ../utils/interface.nu _print
|
use lib_provisioning/utils/interface.nu [_print]
|
||||||
use ../plugins/kms.nu [plugin-kms-encrypt plugin-kms-decrypt plugin-kms-status plugin-kms-info]
|
use lib_provisioning/plugins/kms.nu [plugin-kms-encrypt plugin-kms-decrypt plugin-kms-status plugin-kms-info]
|
||||||
|
|
||||||
# KMS Client for encryption/decryption operations
|
# KMS Client for encryption/decryption operations
|
||||||
export def kms-encrypt [
|
export def kms-encrypt [
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,8 @@
|
||||||
# Orchestrator Plugin Wrapper with HTTP Fallback
|
# Orchestrator Plugin Wrapper with HTTP Fallback
|
||||||
# Provides graceful degradation to HTTP/file-based access when nu_plugin_orchestrator is unavailable
|
# Provides graceful degradation to HTTP/file-based access when nu_plugin_orchestrator is unavailable
|
||||||
|
|
||||||
use ../config/accessor.nu *
|
# Selective imports (ADR-025 Phase 3 Layer 2).
|
||||||
|
use lib_provisioning/config/accessor/core.nu [config-get]
|
||||||
|
|
||||||
# Check if orchestrator plugin is available (registered with Nushell)
|
# Check if orchestrator plugin is available (registered with Nushell)
|
||||||
def is-plugin-available [] {
|
def is-plugin-available [] {
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,8 @@
|
||||||
# SecretumVault Plugin Wrapper with HTTP Fallback
|
# SecretumVault Plugin Wrapper with HTTP Fallback
|
||||||
# Provides high-level functions for SecretumVault operations with graceful HTTP fallback
|
# Provides high-level functions for SecretumVault operations with graceful HTTP fallback
|
||||||
|
|
||||||
use ../config/accessor.nu *
|
# Selective imports (ADR-025 Phase 3 Layer 2).
|
||||||
|
use lib_provisioning/config/accessor/core.nu [config-get]
|
||||||
|
|
||||||
# Check if SecretumVault plugin is available (registered with Nushell)
|
# Check if SecretumVault plugin is available (registered with Nushell)
|
||||||
def is-plugin-available [] {
|
def is-plugin-available [] {
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
|
|
||||||
use ../config/accessor.nu *
|
# config/accessor star-import was dead — dropped (ADR-025 Phase 3 Layer 2).
|
||||||
|
|
||||||
export def env_file_providers [
|
export def env_file_providers [
|
||||||
filepath: string
|
filepath: string
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,11 @@
|
||||||
# Detects system capabilities, available tools, network configuration, and existing setup
|
# Detects system capabilities, available tools, network configuration, and existing setup
|
||||||
# Follows Nushell guidelines: explicit types, single purpose, no try-catch
|
# Follows Nushell guidelines: explicit types, single purpose, no try-catch
|
||||||
|
|
||||||
use ./mod.nu *
|
# Selective imports (ADR-025 Phase 3 Layer 2).
|
||||||
|
use lib_provisioning/setup/mod.nu [
|
||||||
|
detect-architecture detect-os get-config-base-path get-cpu-count
|
||||||
|
get-current-user get-system-disk-gb get-system-hostname get-system-memory-gb
|
||||||
|
]
|
||||||
|
|
||||||
# ============================================================================
|
# ============================================================================
|
||||||
# SYSTEM CAPABILITY DETECTION
|
# SYSTEM CAPABILITY DETECTION
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
#use ../lib_provisioning/defs/lists.nu providers_list
|
#use ../lib_provisioning/defs/lists.nu providers_list
|
||||||
use ../config/accessor.nu *
|
# Selective imports (ADR-025 Phase 3 Layer 2).
|
||||||
use ../utils/nickel_processor.nu [ncl-eval-soft]
|
use lib_provisioning/config/accessor/functions.nu [get-providers-path]
|
||||||
|
use lib_provisioning/utils/nickel_processor.nu [ncl-eval-soft]
|
||||||
|
|
||||||
export def setup_config_path [
|
export def setup_config_path [
|
||||||
provisioning_cfg_name: string = "provisioning"
|
provisioning_cfg_name: string = "provisioning"
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
use ../config/accessor.nu *
|
# config/accessor star-import was dead — dropped (ADR-025 Phase 3 Layer 2).
|
||||||
|
|
||||||
export def throw-error [
|
export def throw-error [
|
||||||
error: string
|
error: string
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
use ../config/accessor.nu *
|
# config/accessor star-import was dead — dropped (ADR-025 Phase 3 Layer 2).
|
||||||
|
|
||||||
export def throw-error [
|
export def throw-error [
|
||||||
error: string
|
error: string
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
use ../config/accessor.nu *
|
# config/accessor star-import was dead — dropped (ADR-025 Phase 3 Layer 2).
|
||||||
|
|
||||||
export def throw-error [
|
export def throw-error [
|
||||||
error: string
|
error: string
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
use ../config/accessor.nu *
|
# config/accessor star-import was dead — dropped (ADR-025 Phase 3 Layer 2).
|
||||||
|
|
||||||
export def parse_help_command [
|
export def parse_help_command [
|
||||||
source: string
|
source: string
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
|
|
||||||
use ../config/accessor.nu *
|
# config/accessor star-import was dead — dropped (ADR-025 Phase 3 Layer 2).
|
||||||
|
|
||||||
export def show_titles [] {
|
export def show_titles [] {
|
||||||
if (detect_claude_code) { return false }
|
if (detect_claude_code) { return false }
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue