Migrate dagger.#Secret and dagger.#Stream to new format
- Refactored to keep every transformation of built-in types (e.g. FS, Secret, etc) to/from CUE in the same place (plancontext) - dagger.#Service and dagger.#Secret are now following the new FS-like format (e.g. `_service: id: string`) - Backward compatibility - dagger.#Stream is now an alias for dagger.#Service Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
This commit is contained in:
@@ -24,10 +24,6 @@ func NewValue() *Value {
|
||||
return DefaultCompiler.NewValue()
|
||||
}
|
||||
|
||||
func NewValueWithContent(x interface{}, selectors ...cue.Selector) (*Value, error) {
|
||||
return DefaultCompiler.NewValueWithContent(x, selectors...)
|
||||
}
|
||||
|
||||
// FIXME can be refactored away now?
|
||||
func Wrap(v cue.Value) *Value {
|
||||
return DefaultCompiler.Wrap(v)
|
||||
@@ -84,14 +80,6 @@ func (c *Compiler) NewValue() *Value {
|
||||
return empty
|
||||
}
|
||||
|
||||
func (c *Compiler) NewValueWithContent(x interface{}, selectors ...cue.Selector) (*Value, error) {
|
||||
v := c.NewValue()
|
||||
if err := v.FillPath(cue.MakePath(selectors...), x); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return v, nil
|
||||
}
|
||||
|
||||
func (c *Compiler) Compile(name string, src string) (*Value, error) {
|
||||
c.lock()
|
||||
defer c.unlock()
|
||||
|
Reference in New Issue
Block a user