[go-nuts] Golang 1.11 Windows Support

2019-01-14 Thread Subramanian Sridharan
on them? Or is it unreliable to cross compile for such machines? TIA, Subramanian Sridharan. -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nut

[go-nuts] Re: help- i cant run program

2019-01-17 Thread Subramanian Sridharan
I think your GOROOT and GOPATH is causing the issue. "fmt" package is present inside {go_installation_dir}\src and not {go_installation_dir}\bin\src. Unset the GOROOT and GOPATH environment variables using the following commands to unset the GOROOT and GOPATH environment variables temporarily:

[go-nuts] How to retain environment in SSH

2019-03-11 Thread Subramanian Sridharan
Hi guys! I would like to know how to keep the environment variables over SSH using Go. I find that several environment variables are missing when I SSH using Go. For instance, the proxy environment variables are not present when I SSH using Go, but they're present when I SSH using an actual

[go-nuts] Re: Go playground to support none-standard modules

2019-03-11 Thread Subramanian Sridharan
Try repl.it . I think you can upload the non-standard modules as folders and them import them in your code. On Sunday, March 10, 2019 at 8:20:15 AM UTC+5:30, Tong Sun wrote: > > I know Go playground does not support none-standard modules. > Is there any online site

[go-nuts] Gorilla Websocket - Proxy with URL, Username and Password

2019-03-07 Thread Subramanian Sridharan
Hello Gophers, I've been using Gorilla Websocket for a persistent connection and it has been working as expected. Now there is a need to achieve the same functionality over a Proxy. After researching a bit, I came across http.ProxyFromEnvironment But I need to connect to the Proxy using an

[go-nuts] Re: Gorilla Websocket - Proxy with URL, Username and Password

2019-03-08 Thread Subramanian Sridharan
conn, _, _ := dialer.Dial(WEBSOCKET_URL, nil) On Thursday, March 7, 2019 at 4:51:47 PM UTC+5:30, Subramanian Sridharan wrote: > > Hello Gophers, > > I've been using Gorilla Websocket for a persistent connection and it has > been working as expected. > Now there is a need to achieve t

[go-nuts] Need help with VSCode, GOPATH and intellisense

2019-05-28 Thread Subramanian Sridharan
I cannot use intellisense and have my own source packages be recognized at the same time. Golang Server - ON Infer GOPATH from root - False GOPATH - Empty Result - I get details on hover. But my own source package imports fail. Golang Server - ON Infer GOPATH from root - True GOPATH - Empty

[go-nuts] Go GTK vs QT for Linux

2019-06-17 Thread Subramanian Sridharan
Hi guys I've been fiddling around this package which uses GTK bindings in Go to achieve systray functionality. But it depends on *libgtk-3-dev *and* libappindicator3-dev *which amount to around 300 MB. Have you guys come across any other package that

[go-nuts] io.Copy and Writer

2019-05-21 Thread Subramanian Sridharan
I had an issue where io.Copy did not copy the entire file contents. My code was something like: fReader := bufio.NewReader(sourcef) fWriter := bufio.NewWriter(destf) n, err := io.Copy(fWriter, fReader) if err != nil { fmt.Println("Error while copying:", err) return } fmt.Println("Copied", n,

Re: [go-nuts] Re: io.Copy and Writer

2019-05-21 Thread Subramanian Sridharan
I don't think so. Closing file without flushing: package main import ( "bufio" "fmt" "io" "os" ) func main() { sourceFilename := "MozillaFirefox-66.0.5-741.4.x86_64.rpm" sourcef, err := os.Open(sourceFilename) if err != nil { fmt.Println("Error while opening source

Re: [go-nuts] Re: io.Copy and Writer

2019-05-21 Thread Subramanian Sridharan
I don't think so. When I close the file and don't explicitly flush: package main import ( "bufio" "fmt" "io" "os" ) func main() { sourceFilename := "MozillaFirefox-66.0.5-741.4.x86_64.rpm" sourcef, err := os.Open(sourceFilename) if err != nil { fmt.Println("Error while opening source file:",

[go-nuts] Go runs multiple threads for a serial process

2019-06-26 Thread Subramanian Sridharan
Hi guys Today while analyzing CPU usage of one of our processes written in go, I noticed that there were multiple threads associated with the process which is actually serial. (Doesn't make use of goroutines) I wanted to know if it was the expected behaviour or some issue in our service. So I

[go-nuts] Re: ticker not firing often enough in minimal mac app with run loop

2019-09-05 Thread Subramanian Sridharan
I came across a similar issue when I was working with a heartbeat feature for Macs. The same code ran as expected on Linux machines. In the end, the issue was with Sleep Mode in the Mac machine. When a Mac goes to sleep, time based functions seem to pause. They resume when the machine is woken

[go-nuts] Re: VsCode syntax highlighting for tmpl files

2019-09-23 Thread Subramanian Sridharan
Nunjucks seems to do the trick. Nunjucks - Visual Studio Marketplace ext install extension nunjucks > When you save a file with some file extension, VSCode automatically prompts you to install a related VSCode extension.

[go-nuts] Anomaly in RunCommand and the exit status of the child process

2020-01-29 Thread Subramanian Sridharan
Hi guys, I'm in need of using the "script" command (more info about script in the end) in Linux to run a couple of commands and get the exit status of the second command. *Here is my code snippet:* package main import ( "fmt" "os/exec" ) func main() { op, err := exec.Command("script",