This commit is contained in:
7
main.go
7
main.go
@@ -199,9 +199,6 @@ func main() {
|
|||||||
end := flag.Duration("e", 0, "End time")
|
end := flag.Duration("e", 0, "End time")
|
||||||
flag.Parse()
|
flag.Parse()
|
||||||
|
|
||||||
// So we can convert vCenter UTC to our local timezone
|
|
||||||
location, _ = time.LoadLocation(*vTZ)
|
|
||||||
|
|
||||||
// Print logs to file
|
// Print logs to file
|
||||||
f, err := os.OpenFile("log.txt", os.O_RDWR|os.O_CREATE|os.O_APPEND, 0666)
|
f, err := os.OpenFile("log.txt", os.O_RDWR|os.O_CREATE|os.O_APPEND, 0666)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
@@ -212,6 +209,10 @@ func main() {
|
|||||||
|
|
||||||
log.Printf("Starting execution. Built on %s from sha1 %s\n", buildTime, sha1ver)
|
log.Printf("Starting execution. Built on %s from sha1 %s\n", buildTime, sha1ver)
|
||||||
|
|
||||||
|
// So we can convert vCenter UTC to our local timezone
|
||||||
|
log.Printf("Setting timezone to '%s'\n", *vTZ)
|
||||||
|
location, _ = time.LoadLocation(*vTZ)
|
||||||
|
|
||||||
u, err := url.Parse(*vURL)
|
u, err := url.Parse(*vURL)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
fmt.Fprintf(os.Stderr, "Error parsing url %s : %s\n", *vURL, err)
|
fmt.Fprintf(os.Stderr, "Error parsing url %s : %s\n", *vURL, err)
|
||||||
|
Reference in New Issue
Block a user