title: How to debug "exit status 1" error when running exec.Command in Golang
body: <p>When I run the code below:</p>
  
  <pre><code>cmd := exec.Command("find", "/", "-maxdepth", "1", "-exec", "wc", "-c", "{}", "\\")
  var out bytes.Buffer
  cmd.Stdout = &amp;out
  err := cmd.Run()
  if err != nil {
      fmt.Println(err)
      return
  }
  fmt.Println("Result: " + out.String())
  </code></pre>
  
  <p>I am getting this error:</p>
  
  <blockquote>
    <p>exit status 1</p>
  </blockquote>
  
  <p>However this is not helpful to debug the exact cause of the error.</p>
  
  <p>How to get more detailed information?</p>