diff --git a/README.md b/README.md index 183f31e..d79f867 100644 --- a/README.md +++ b/README.md @@ -46,6 +46,7 @@ php-parser [flags] ... | flag | type | description | |-------|------|----------------------------------------------| +| -p | bool | print filepath | | -d |string| dump format: [custom, go, json, pretty-json] | | -r | bool | resolve names | | -ff | bool | parse and show free floating strings | @@ -71,7 +72,7 @@ import ( func main() { src := []byte(` [%d] %s\n", counter, res.path) + if *printPath { + fmt.Fprintf(os.Stdout, "==> [%d] %s\n", counter, res.path) + } for _, e := range res.parser.GetErrors() { - // if !strings.Contains(e.Msg, "WARNING") { - // fmt.Print("\n\n\n" + parserWorker.GetPath() + "\n ") - // panic(e.Msg) - // } - fmt.Fprintln(w, e) + fmt.Fprintf(os.Stdout, "==> %s\n", e) } if *printBack {