cmd/up: disable output list when not a tty + better error handling

Signed-off-by: Sam Alba <sam.alba@gmail.com>
This commit is contained in:
Sam Alba
2021-05-31 18:09:14 +02:00
parent 571b5c8618
commit efb4ee209e
3 changed files with 11 additions and 2 deletions

View File

@@ -326,7 +326,7 @@ func (e *Environment) ScanInputs(ctx context.Context, mergeUserInputs bool) ([]*
func (e *Environment) ScanOutputs(ctx context.Context) ([]*compiler.Value, error) {
if e.state.Computed == "" {
return nil, errors.New("cannot query environment outputs: please run `dagger up` first")
return nil, errors.New("environment has been computed yet")
}
src, err := e.prepare(ctx)