Setup

SolidGroundUX DocumentationSolidGroundUX
NL

Standalone SolidGroundUX product setup, installation, update, rollback, and removal.

Source: target-root/var/lib/solidgroundux/sgnd-setup.sh

Standalone SolidGroundUX product setup, installation, update, rollback, and removal.

Public functions

Internal functions
FunctionPurposeArgumentsOutput
_release_framework_root_for_targetResolve the framework root for the selected target.——
_release_try_framework_uiOpportunistically load the normal framework UI after the target root is known.——
_release_printPrint a line through the active UI implementation.——
_release_section_headerRender a section header through the active UI.——
_release_askAsk for a scalar value using framework ask() or the fallback UI.——
_release_ask_yesnoAsk a yes/no question with a default.——
_release_terminal_widthReturn the usable terminal width.——
_release_clearClear the active terminal reliably.——
_release_linePrint a repeated border character.——
_release_metadata_fieldRead one value from the canonical script Metadata block without depending on$1 Metadata field name, for example Version or Build.—
_release_titleDisplay the sgnd-setup identity and current hostname without using framework UI libraries.——
_release_labeled_valuePrint one aligned label/value pair.——
_release_infoWrite verbose informational output.——
_release_okWrite a successful-operation message.——
_release_warnWrite a warning message.——
_release_failWrite a failure message.——
_release_runExecute a command or report it in dry-run mode.——
_ensure_rootRe-execute sgnd-setup with elevated privileges when required.——
_set_actionSet and validate the requested setup action.——
_normalize_rootNormalize an absolute filesystem root.——
_release_locate_framework_rootResolve the filesystem root containing the currently executing sgnd-setup copy——
_nuke_root_pathResolve one absolute path beneath the located framework root.——
_nuke_remove_pathRemove one SolidGroundUX-owned path when present——
_nuke_remove_codeRemove installed SolidGroundUX code beneath the located root——
_nuke_remove_state_and_logsRemove generated SolidGroundUX state and logs——
_nuke_remove_configRemove SolidGroundUX system and per-user configuration——
_nuke_confirmRequire deliberate confirmation for a nuclear removal yield——
_action_nukeExecute a scoped destructive SolidGroundUX cleanup——
_release_default_target_rootDerive target root only from canonical manager location.——
_release_load_stateLoad standalone parameter defaults.——
_release_save_statePersist accepted parameter values.——
_release_definition_valueRead product release metadata without sourcing project-controlled shell code.——
_release_normalize_github_urlNormalize a GitHub repository/release URL.——
_release_project_repo_state_fileResolve per-project repository state file.——
_release_load_project_repoLoad a saved repository URL for one project.——
_release_save_project_repoPersist repository URL for the selected project.——
_release_repo_from_urlConvert a GitHub release URL to OWNER/REPO.——
_setup_catalog_sourceResolve an operator-provided catalog, a persisted setup catalog, or the——
_ensure_setup_catalogSeed the editable sgnd-setup.cfg once; never overwrite user changes.——
_release_package_catalogRead project\product\release-url\
_setup_catalog_framework_defaultsKeep legacy standalone release settings without embedding a GitHub owner/repo——
_release_select_package_interactiveMake package selection the normal entry point. Project, product, channel, version,——
_release_prompt_manual_settingsCollect explicit product/repository/channel overrides.——
_release_prompt_settingsResolve only the installation target. Product/package selection belongs to each action.——
_package_info_valueParse a simple KEY=value field without sourcing package-controlled shell code.——
_project_slug_safeValidate a project slug used beneath the manager state root.——
_load_project_infoLoad persisted display identity for one project.——
_set_project_contextMake all existing installation-engine functions operate on the selected project.——
_persist_project_infoPersist display identity for an admitted project package.——
_list_known_projectsList locally known project slugs.——
_select_project_interactiveSelect a locally known project.——
_require_commandVerify that a required system command is available.——
_load_release_manager_configLoad release-source settings from the compatibility config file without——
_ensure_release_manager_configSeed release-manager.cfg with the current release source and release line.——
_ensure_manager_directoriesCreate the state, pending-release, and archive directories required by the——
_install_setup_wrappersInstall sgnd-setup and retain sgnd-release-manager as a compatibility alias.——
_install_setup_selfCopy a bootstrap/setup copy to the canonical recovery path and install wrappers.——
_install_release_managerCopy the currently running setup tool to the machine-local state root so——
_cleanup_bootstrap_filesClean only known first-install files when sgnd-setup was run——
_release_choose_post_install_actionLet an interactive first-install session continue into Setup, open the——
_release_product_artifact_nameConvert a display product name to its canonical release-file identity.——
_release_base_from_archiveDerive a release base name from a tar.gz archive path.——
_release_variant_matchesCheck whether an archive matches the product individual-release naming scheme.$1 Release archive base name.—
_release_matchesMatch an archive base to the optional requested release.$1 Archive base name.—
_release_sortSort release identifiers by version.——
_current_releaseReturn the highest archived release as the current version.——
_previous_releaseReturn the archived release immediately preceding current.——
_list_archived_releasesList archived releases in ascending version order.——
_find_pending_archivesList pending release tarballs under the releases directory.——
_newest_pending_archiveFind the newest pending archive matching an optional release selector.——
_find_archived_archiveFind the tarball belonging to an archived release.——
_release_locationResolve a release tarball from pending or archived storage.——
_pending_release_base_existsTest whether a release is available in releases/.——
_archived_release_base_existsTest whether a release is present in archive/.——
_verify_sha256_sidecarVerify one release artifact against its SHA256 sidecar.——
_safe_relative_pathValidate and normalize a release-relative path.——
_validate_tar_pathsReject unsafe paths contained in a release tarball.——
_validate_manifest_pathsReject unsafe paths contained in a release manifest.——
_verify_release_setVerify checksums and path safety for a complete release set.——
_manifest_pathsEmit normalized paths from a release manifest.——
_target_pathMap a release-relative path beneath the configured target root.——
_remove_paths_from_streamRemove streamed release paths conservatively from the target.——
_apply_removed_manifestApply the incoming release removal manifest.——
_remove_release_differenceRemove paths present in one release manifest but absent from another.——
_archive_release_setMove an installed pending release set into versioned archive history.——
_move_archive_dir_to_releasesReturn one archived release directory to releases/.——
_move_newer_archives_to_releasesReturn archived versions newer than a rollback target to releases/.——
_move_all_archives_to_releasesReturn all archived releases to releases/.——
_remember_release_channelPersist the channel of the successfully installed release.——
_extract_releaseExtract a complete SolidGroundUX release beneath the target root.——
_install_pending_archiveInstall, update, or roll back to a pending release archive.——
_rollback_to_archived_releaseMake the installed framework match a selected archived release.——
_remove_by_manifestRemove exactly the files/symlinks owned by a selected release manifest.——
_file_belongs_to_productRecognize the canonical title header '# <Product> - ...' and an explicit——
_scan_product_owned_pathsRecover product ownership without a release manifest by inspecting file headers.——
_remove_by_product_scanProvide a recovery cleanup independent of release manifests by scanning canonical——
_remove_bundle_products_by_scanApply ownership cleanup to each product recorded in RELEASE-PRODUCTS.——
_download_toDownload or copy a release source to a destination file.——
_github_release_jsonRead the configured GitHub Release metadata. The endpoint is persistent while——
_github_latest_assetInspect Release assets and select the highest——
_latest_online_releaseResolve the highest build asset attached to the configured GitHub Release.——
_github_release_asset_urlReturn the browser download URL selected by _github_latest_asset.——
_release_is_local_or_installedTest whether a release is already downloaded or archived.——
_admit_extracted_releaseValidate an extracted release ZIP and admit its artifacts to releases/.——
_acquire_releaseAcquire, stage, validate, and admit a release ZIP.——
_package_zip_info_valueRead one package metadata value directly from a ZIP.——
_package_zip_recordDescribe one valid product package ZIP.——
_package_store_dirReturn the canonical pending product-package directory.——
_package_archive_dirReturn the canonical installed package archive directory.——
_scan_product_packagesScan one directory for valid product release ZIPs.——
_local_package_catalogList locally discoverable product packages——
_newest_local_package_for_projectResolve newest local product ZIP for one project.——
_admit_product_package_zipCopy one valid product ZIP into canonical releases.——
_archive_product_package_zipArchive the original ZIP after successful installation.——
_install_product_package_zipInstall one product ZIP through the canonical tar engine——
_select_package_recordsSelect one, several, or all package records.——
_product_catalogList known products without requiring package preselection.——
_select_product_recordsSelect one, several, or all known products.——
_install_explicit_package_sourceInstall a directly supplied product ZIP source.——
_action_install_latest_local_packagesSelect/install newest local package per product.——
_action_install_other_packagesSelect/install product ZIPs from another directory.——
_action_install_latest_github_productsSelect products, download/install newest GitHub ZIPs.——
_release_display_identityReduce a release basename to Version.Build for display.——
_dashboard_product_rowsRender product-centric installed/local/GitHub status.——
_bootstrap_first_install_packagesFirst install from adjacent product ZIPs——
_confirmRequest a standalone yes/no confirmation.——
_bundle_products_fileLocate RELEASE-PRODUCTS metadata retained beside the installed or pending bundle.——
_bundle_product_namesRead the first field of RELEASE-PRODUCTS records without hard-coding products.——
_select_bundle_removal_scopePresent products from RELEASE-PRODUCTS dynamically so future bundle members require——
_select_archived_releaseSelect an archived release from the available release history.——
_print_statusDisplay the product setup dashboard——
_interactive_menuRun the standalone product setup menu.——
_pauseWait for Enter after an interactive operation.——
_action_checkReport the latest GitHub release and its local state.——
_action_downloadAcquire the latest or explicitly sourced release without installing it.——
_action_updateIn interactive mode, select the configured GitHub source or a package ZIP/URL,——
_action_installInstall the newest matching pending local release.——
_action_rollbackInstall the previous or explicitly selected archived release.——
_action_removeRemove the active SolidGroundUX installation after confirmation.——

Description

Provides self-sufficient first-install and lifecycle setup for SolidGroundUX products.

The script:

  • Keeps SolidGroundUX release state in the legacy releases/archive locations
  • Keeps other project release state under /var/lib/solidgroundux/projects/<project>/
  • Reads release-package.info from incoming ZIPs to select the owning project
  • Installs a first release by verifying and extracting its complete tar archive
  • Updates an existing installation and applies the incoming .removed manifest
  • Rolls back by making the installed filesystem match a selected archived release
  • Removes selected products using active release manifests, with ownership-scan recovery
  • Provides root-scoped nuclear cleanup yields for state/log cleanup, code removal, or complete SolidGroundUX eradication without requiring a working framework
  • Queries GitHub for the latest published release and downloads it only when needed
  • Bootstraps a clean machine from sgnd-setup.sh plus adjacent product release ZIPs
  • Installs a canonical setup copy under /var/lib/solidgroundux for future recovery
  • Uses a small self-contained UI before SolidGroundUX is available
  • Reuses the normal SolidGroundUX UI primitives/theme when a healthy framework is available
  • Persists setup parameter values as standalone state
  • Offers Setup, Management Console, or shell exit after first install

Design principles

  • Standalone operation even when SolidGroundUX is absent or damaged
  • Product ZIPs are the release unit; acquisition varies, installation does not
  • Complete release archives; no incremental binary patching
  • Conservative removal: files/symlinks are removed, directories only when empty
  • Product ZIP acquisition is transactional; successful installs archive the original ZIP
  • Bootstrap cleanup is limited to known setup/package files under /tmp
  • Nuclear cleanup derives its deletion root from the canonical framework-locator algorithm

Standalone UI

Default-theme-compatible standalone palette. Kept local so the setup tool remains self-sufficient. Bootstrap palette: design-time snapshot of the SolidGroundUX default theme. It deliberately mirrors the normal default palette/style closely, but has no runtime dependency on SolidGroundUX.