cmd/nix-tool: improve message formatting
This commit is contained in:
parent
9a210d9a7c
commit
3deb8862ba
@ -79,12 +79,12 @@ func main() {
|
||||
return err
|
||||
}
|
||||
|
||||
log.Println("signing collected paths")
|
||||
log.Println("signing collected paths...")
|
||||
if err := nix.Sign(ctx, flagCacheKeyPath, slices.Values(collective)); err != nil {
|
||||
return commandHandlerError(fmt.Sprintf("cannot sign: %v", err))
|
||||
}
|
||||
|
||||
log.Println("copying to binary cache")
|
||||
log.Println("copying to binary cache...")
|
||||
if err := nix.Copy(ctx, flagCacheKeyPath, &nix.BinaryCache{
|
||||
Compression: flagCacheComp,
|
||||
ParallelCompression: flagCachePComp,
|
||||
@ -143,12 +143,12 @@ func main() {
|
||||
return err
|
||||
}
|
||||
|
||||
log.Println("initialising evaluator")
|
||||
log.Println("initialising evaluator...")
|
||||
var collective []string
|
||||
if eval, err := nix.NewInstantiatedEvaluator(ctx, installable); err != nil {
|
||||
return commandHandlerError(fmt.Sprintf("cannot initialise evaluator: %v", err))
|
||||
} else {
|
||||
log.Println("collecting paths")
|
||||
log.Println("collecting paths...")
|
||||
collective = slices.Collect(eval.Instantiated())
|
||||
if err := eval.Err(); err != nil {
|
||||
return commandHandlerError(fmt.Sprintf("cannot collect: %v", err))
|
||||
|
@ -13,7 +13,7 @@ func buildAndResolve(ctx nix.Context, name string, installable *string, collecti
|
||||
return err
|
||||
}
|
||||
|
||||
log.Printf("evaluating %s", *installable)
|
||||
log.Printf("evaluating %q...", *installable)
|
||||
var installables []string
|
||||
if v, err := nix.EvalInstantiated(ctx, *installable); err != nil {
|
||||
return commandHandlerError(fmt.Sprintf("cannot evaluate: %v", err))
|
||||
@ -21,12 +21,12 @@ func buildAndResolve(ctx nix.Context, name string, installable *string, collecti
|
||||
installables = v
|
||||
}
|
||||
|
||||
log.Println("building instantiated derivations")
|
||||
log.Println("building instantiated derivations...")
|
||||
if err := nix.Build(ctx, slices.Values(installables)); err != nil {
|
||||
return commandHandlerError(fmt.Sprintf("cannot build: %v", err))
|
||||
}
|
||||
|
||||
log.Println("collecting store paths")
|
||||
log.Println("collecting store paths...")
|
||||
if derivations, err := nix.DerivationShow(ctx, slices.Values(installables)); err != nil {
|
||||
return commandHandlerError(fmt.Sprintf("cannot get derivations: %v", err))
|
||||
} else {
|
||||
|
Loading…
x
Reference in New Issue
Block a user