summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarkus Teich <markus.teich@stusta.mhn.de>2017-03-19 19:39:59 +0100
committerMarkus Teich <markus.teich@stusta.mhn.de>2017-03-19 19:39:59 +0100
commitbf49cdc7c197a529014f7ca744c0ef9b0674b9c1 (patch)
treef2ff5fe9f735333d825b4aa0d295bc40758f64f7
parent59e0142a998397fa2a69e45b3d950da5c1d1246b (diff)
fix some formating issues
-rw-r--r--backends/worldweatheronline.com.go4
-rw-r--r--iface/iface.go2
-rw-r--r--main.go4
3 files changed, 5 insertions, 5 deletions
diff --git a/backends/worldweatheronline.com.go b/backends/worldweatheronline.com.go
index 800ff83..9d84384 100644
--- a/backends/worldweatheronline.com.go
+++ b/backends/worldweatheronline.com.go
@@ -41,8 +41,8 @@ type wwoDay struct {
Sunrise string
Sunset string
}
- Date string
- Hourly []wwoCond
+ Date string
+ Hourly []wwoCond
}
type wwoResponse struct {
diff --git a/iface/iface.go b/iface/iface.go
index 6409118..0d4ea91 100644
--- a/iface/iface.go
+++ b/iface/iface.go
@@ -142,7 +142,7 @@ func (u UnitSystem) Speed(spdKmph float32) (res float32, unit string) {
}
func (u UnitSystem) Distance(distM float32) (res float32, unit string) {
- if u == UnitsMetric || u == UnitsSi || u == UnitsMetricMs{
+ if u == UnitsMetric || u == UnitsSi || u == UnitsMetricMs {
if distM < 1 {
return distM * 1000, "mm"
} else if distM < 1000 {
diff --git a/main.go b/main.go
index aa339da..0441114 100644
--- a/main.go
+++ b/main.go
@@ -46,8 +46,8 @@ func main() {
flag.StringVar(location, "l", "40.748,-73.985", "`LOCATION` to be queried (shorthand)")
numdays := flag.Int("days", 3, "`NUMBER` of days of weather forecast to be displayed")
flag.IntVar(numdays, "d", 3, "`NUMBER` of days of weather forecast to be displayed (shorthand)")
- unitSystem := flag.String("units", "metric", "`UNITSYSTEM` to use for output.\n \tChoices are: metric, imperial, si")
- flag.StringVar(unitSystem, "u", "metric", "`UNITSYSTEM` to use for output. (shorthand)\n \tChoices are: metric, imperial, si , metric-ms")
+ unitSystem := flag.String("units", "metric", "`UNITSYSTEM` to use for output.\n \tChoices are: metric, imperial, si, metric-ms")
+ flag.StringVar(unitSystem, "u", "metric", "`UNITSYSTEM` to use for output. (shorthand)\n \tChoices are: metric, imperial, si, metric-ms")
selectedBackend := flag.String("backend", "forecast.io", "`BACKEND` to be used")
flag.StringVar(selectedBackend, "b", "forecast.io", "`BACKEND` to be used (shorthand)")
selectedFrontend := flag.String("frontend", "ascii-art-table", "`FRONTEND` to be used")