refactor(10 files): selective imports batch 4 (ADR-025 L2)
10 utils/* + workspace/migrate_to_kcl + mode/* files. Selective imports: utils/imports.nu accessor/functions [get-providers-path get-prov-lib-path get-core-nulib-path] utils/logging.nu accessor/core [config-get] utils/generate.nu accessor/functions [2 symbols] utils/files.nu accessor/core [config-get] + secrets/lib [decode_secret_file] utils/qr.nu accessor/functions [get-provisioning-url] utils/undefined.nu interface + init (kept); accessor DEAD utils/interface.nu accessor/core [config-get] + accessor/functions [get-provisioning-url] + logging [is-debug-enabled] Dead imports dropped: workspace/migrate_to_kcl.nu config/accessor mode/commands.nu utils/logging mode/validator.nu utils/logging Validation: all 10 match pre-existing baselines (25/50/42/2 for noisy files, 0 for the others). No new errors. Refs: ADR-025
This commit is contained in:
parent
1ac3401315
commit
48c82ac79a
10 changed files with 25 additions and 14 deletions
|
|
@ -7,7 +7,7 @@
|
||||||
# - cicd: CI/CD pipeline execution
|
# - cicd: CI/CD pipeline execution
|
||||||
# - enterprise: Production enterprise deployment
|
# - enterprise: Production enterprise deployment
|
||||||
|
|
||||||
use ../utils/logging.nu *
|
# utils/logging star-import was dead — dropped (ADR-025 Phase 3 Layer 2).
|
||||||
|
|
||||||
# Get current active mode
|
# Get current active mode
|
||||||
export def "mode current" [] -> record {
|
export def "mode current" [] -> record {
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
# Mode Configuration Validator
|
# Mode Configuration Validator
|
||||||
# Validates mode configurations against Nickel schemas and runtime requirements
|
# Validates mode configurations against Nickel schemas and runtime requirements
|
||||||
|
|
||||||
use ../utils/logging.nu *
|
# utils/logging star-import was dead — dropped (ADR-025 Phase 3 Layer 2).
|
||||||
|
|
||||||
# Validate complete mode configuration
|
# Validate complete mode configuration
|
||||||
export def validate-mode-config [
|
export def validate-mode-config [
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
use std
|
use std
|
||||||
use ../config/accessor.nu *
|
# Selective imports (ADR-025 Phase 3 Layer 2).
|
||||||
use ../secrets/lib.nu decode_secret_file
|
use lib_provisioning/config/accessor/core.nu [config-get]
|
||||||
|
use lib_provisioning/secrets/lib.nu [decode_secret_file]
|
||||||
use ../secrets/lib.nu get_secret_provider
|
use ../secrets/lib.nu get_secret_provider
|
||||||
|
|
||||||
export def find_file [
|
export def find_file [
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,10 @@
|
||||||
# Release: 1.0.4
|
# Release: 1.0.4
|
||||||
# Date: 6-2-2024
|
# Date: 6-2-2024
|
||||||
|
|
||||||
use ../config/accessor.nu *
|
# Selective imports (ADR-025 Phase 3 Layer 2).
|
||||||
|
use lib_provisioning/config/accessor/functions.nu [
|
||||||
|
get-provisioning-generate-dirpath get-provisioning-generate-defsfile
|
||||||
|
]
|
||||||
|
|
||||||
#use ../lib_provisioning/utils/templates.nu on_template_path
|
#use ../lib_provisioning/utils/templates.nu on_template_path
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,10 @@
|
||||||
# Import Helper Functions
|
# Import Helper Functions
|
||||||
# Provides clean, environment-based imports to avoid relative paths
|
# Provides clean, environment-based imports to avoid relative paths
|
||||||
|
|
||||||
use ../config/accessor.nu *
|
# Selective imports (ADR-025 Phase 3 Layer 2).
|
||||||
|
use lib_provisioning/config/accessor/functions.nu [
|
||||||
|
get-providers-path get-prov-lib-path get-core-nulib-path
|
||||||
|
]
|
||||||
|
|
||||||
# Provider middleware imports
|
# Provider middleware imports
|
||||||
export def prov-middleware [] {
|
export def prov-middleware [] {
|
||||||
|
|
|
||||||
|
|
@ -2,8 +2,10 @@
|
||||||
# Purpose: Provides terminal UI utilities: output formatting, prompts, spinners, and status displays.
|
# Purpose: Provides terminal UI utilities: output formatting, prompts, spinners, and status displays.
|
||||||
# Dependencies: error for error handling, logging for debug utilities
|
# Dependencies: error for error handling, logging for debug utilities
|
||||||
|
|
||||||
use ../config/accessor.nu *
|
# Selective imports (ADR-025 Phase 3 Layer 2).
|
||||||
use logging.nu [is-debug-enabled]
|
use lib_provisioning/config/accessor/core.nu [config-get]
|
||||||
|
use lib_provisioning/config/accessor/functions.nu [get-provisioning-url]
|
||||||
|
use lib_provisioning/utils/logging.nu [is-debug-enabled]
|
||||||
|
|
||||||
# Check if no-terminal mode is enabled
|
# Check if no-terminal mode is enabled
|
||||||
export def get-provisioning-no-terminal [] {
|
export def get-provisioning-no-terminal [] {
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
# Enhanced logging system for provisioning tool
|
# Enhanced logging system for provisioning tool
|
||||||
|
|
||||||
use ../config/accessor.nu *
|
# Selective imports (ADR-025 Phase 3 Layer 2).
|
||||||
|
use lib_provisioning/config/accessor/core.nu [config-get]
|
||||||
|
|
||||||
# Check if debug mode is enabled
|
# Check if debug mode is enabled
|
||||||
export def is-debug-enabled [] {
|
export def is-debug-enabled [] {
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
use ../config/accessor.nu *
|
# Selective imports (ADR-025 Phase 3 Layer 2).
|
||||||
|
use lib_provisioning/config/accessor/functions.nu [get-provisioning-url]
|
||||||
|
|
||||||
# Display QR code for URL using qr_maker plugin or fallback
|
# Display QR code for URL using qr_maker plugin or fallback
|
||||||
def show_qr [url: string]: nothing -> nothing {
|
def show_qr [url: string]: nothing -> nothing {
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
use ../config/accessor.nu *
|
# config/accessor star-import was dead — dropped (ADR-025 Phase 3 Layer 2).
|
||||||
use interface.nu [_ansi _print end_run]
|
use lib_provisioning/utils/interface.nu [_ansi _print end_run]
|
||||||
use init.nu [get-provisioning-name]
|
use lib_provisioning/utils/init.nu [get-provisioning-name]
|
||||||
|
|
||||||
export def option_undefined [
|
export def option_undefined [
|
||||||
root: string
|
root: string
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
# Converts existing provisioning.yaml workspace configs to Nickel format
|
# Converts existing provisioning.yaml workspace configs to Nickel format
|
||||||
# Error handling: do/complete pattern with exit_code checks (no try-catch)
|
# Error handling: do/complete pattern with exit_code checks (no try-catch)
|
||||||
|
|
||||||
use ../config/accessor.nu *
|
# config/accessor star-import was dead — dropped (ADR-025 Phase 3 Layer 2).
|
||||||
use ../utils/nickel_processor.nu [ncl-eval]
|
use ../utils/nickel_processor.nu [ncl-eval]
|
||||||
|
|
||||||
# ============================================================================
|
# ============================================================================
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue