formatting

pull/5/head
Jordan Orelli 10 years ago
parent f00a030039
commit 18893f6489

@ -38,10 +38,14 @@ var nearbyCommand = &Command{
log_error("unable to get neighbors: %v", err)
return
}
fmt.Fprintf(conn, "--------------------------------------------------------------------------------\n")
fmt.Fprintf(conn, "%-4s %-20s %s\n", "id", "name", "travel time")
fmt.Fprintf(conn, "--------------------------------------------------------------------------------\n")
for _, neighbor := range neighbors {
other := index[neighbor.id]
fmt.Fprintf(conn, "%-4d %-20s %v\n", other.id, other.name, system.TravelTimeTo(other))
}
fmt.Fprintf(conn, "--------------------------------------------------------------------------------\n")
},
}

Loading…
Cancel
Save