Skip to content

Commit

Permalink
Pretty print lockfile
Browse files Browse the repository at this point in the history
  • Loading branch information
evanpurkhiser committed Jul 14, 2019
1 parent 3ded820 commit 7bf3f73
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,10 @@ func WriteLockfile(lockfile *SourceLockfile, config *SourceConfig) error {

defer file.Close()

if err := json.NewEncoder(file).Encode(lockfile); err != nil {
encoder := json.NewEncoder(file)
encoder.SetIndent("", " ")

if err := encoder.Encode(lockfile); err != nil {
return err
}

Expand Down

0 comments on commit 7bf3f73

Please sign in to comment.