Bootstrap Core

SolidGroundUX DocumentationSolidGroundUX
NL

Initialize the SolidGroundUX framework and load core modules

Source: target-root/usr/local/lib/solidgroundux/common/sgnd-bootstrap.sh

Initialize the SolidGroundUX framework and load core modules

Public functions

Internal functions
FunctionPurposeArgumentsOutput
_parse_bootstrap_argsExtract bootstrap-only options before the full argument parser is available.$@ Raw script arguments passed to sgnd_bootstrap.—
_init_bootstrapPrepare the minimum framework environment required before core libraries load.——
_source_corelibsLoad the fixed set of framework core libraries in bootstrap order.——
_source_usinglibsLoad script-declared framework libraries listed in SGND_USING.——
_sgnd_on_exit_runDispatch registered framework cleanup handlers when the shell exits.——
_sgnd_save_state_dispatchConditionally persist framework state from the exit-handler stack.——
_boot_failReport a bootstrap-stage failure without depending on later UI initialization.——

Description

Provides the central bootstrap mechanism for all SolidGroundUX scripts.

The library:

  • Orchestrates framework initialization sequence
  • Loads core and declared libraries (SGND_USING)
  • Parses and separates framework and script arguments
  • Initializes environment, configuration, and runtime state
  • Applies standard execution flow for all scripts
  • Ensures consistent startup behavior across all tools

Design principles

  • Single entry point for framework initialization
  • Deterministic and repeatable startup sequence
  • Explicit dependency loading via SGND_USING
  • Minimal assumptions about script context

Role in framework

  • Central orchestrator of the SolidGroundUX runtime
  • Bridges bootstrap environment, argument parsing, and module loading
  • Ensures every script runs within a fully initialized framework context

Non-goals

  • Business logic execution
  • UI rendering or interaction handling
  • Application-specific behavior