Skip to content
This repository has been archived by the owner on Sep 9, 2020. It is now read-only.

fix(status): print verbose messages #1009

Merged
merged 1 commit into from
Aug 16, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions cmd/dep/status.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ import (
"flag"
"fmt"
"io"
"io/ioutil"
"log"
"sort"
"text/tabwriter"

Expand Down Expand Up @@ -316,8 +318,12 @@ func runStatusAll(ctx *dep.Ctx, out outputter, p *dep.Project, sm gps.SourceMana
Manifest: p.Manifest,
// Locks aren't a part of the input hash check, so we can omit it.
}

logger := ctx.Err
if ctx.Verbose {
params.TraceLogger = ctx.Err
} else {
logger = log.New(ioutil.Discard, "", 0)
}

if err := ctx.ValidateParams(sm, params); err != nil {
Expand All @@ -344,7 +350,11 @@ func runStatusAll(ctx *dep.Ctx, out outputter, p *dep.Project, sm gps.SourceMana

out.BasicHeader()

logger.Println("Checking upstream projects:")

for _, proj := range slp {
logger.Println(proj.Ident().ProjectRoot)

bs := BasicStatus{
ProjectRoot: string(proj.Ident().ProjectRoot),
PackageCount: len(proj.Packages()),
Expand Down