6 Commits

Author SHA1 Message Date
Jeff McCune
012de360ac component: pass write to directory as function args
Makes it easier to test and know for certain where the value is being
set from.  Previously it wasn't clear how the write to directory was
being modified or read in the global config object.
2025-05-21 14:27:02 -07:00
Jeff McCune
c5600f2310 render: fix write-to flag handling
Fixed regression in holos render platform command where output manifests were
not being written to the deploy/ directory by default. Issues:

1. Ensured write-to flag is passed from render platform to render component
2. Fixed NewConfig to set the default WriteTo value properly
3. Fixed compile.go to ensure WriteTo is passed to components
4. Properly pass tempDir in renderAlpha5 method

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-05-21 12:19:39 -07:00
Jeff McCune
18be14c2ea compile: take a BuildPlanRequest as input
This package clarifies and simplifies the input protocol of the holos
compile command.  A BuildPlanRequest represents the complete context
necessary to compile a BuildPlan.

This patch also upgrades cue to v0.13.0-alpha4
2025-05-21 11:18:53 -07:00
Jeff McCune
b78e862d09 maint: cleanup unused functions and code
ExtractYAML is no longer used, also cleans up connectrpc packages, error
handling, tracing, and memory profiling.
2025-04-03 15:33:42 -07:00
Jeff McCune
95d53062da cli: refactor how build plans are loaded
Previously the show buildplans, render platform, and render component
commands used duplicate code paths to obtain build plans and render
components.  This patch consolidates the behaviors into the component
and platform packages.  The platform Build method is used to call a
different PerComponentFunc depending on the use case of showing build
plans or rendering each component in the platform.

The behavior of loading a build plan from cue is consolidated into the
Component.BuildPlan method.

Result:

1. Platform.Build is reused for both show buildplans and render platform
2. Component.BuildPlan is reused for both show buildplans and render
   component.
2025-04-01 20:59:39 -07:00
Jeff McCune
779f04b85a builder: refactor to component and platform packages
There are only two version specific cue builders, a Platform and a
component BuildPlan. The platform is anemic while the component holds
most of the behavior of the Holos rendering pipeline.  Without this
patch the two types of builders were mixed together in the same package.

This patch refactors the version specific builders into the platform and
component packages respectively.  The version specific BuildPlan builder
is where most of the behavior lies and what we expect to evolve most
over time.  With the typemeta.yaml approach, we can easily switch code
paths, isolated to the process boundary since holos render platform
invokes sub processes for each holos render component command.

This patch helps focus on good test coverage by establishing a clear
area to add version specific test cases, both for the platform layer and
the individual component layer.
2025-04-01 08:51:36 -07:00