Commit Graph

11 Commits

Author SHA1 Message Date
Chris Nobody e203f94963 gocomplete: suppress error output by default
Prevent the Go command completion from jumbling up the shell prompt on
errors by setting the Writer of the standard lib default log.Logger to
ioutil.Discard unless the system environment variable `GOCOMP_VERBOSE`
has been explicitly set to "1" (e.g. for debugging purposes).

Fixes #139
2021-04-06 14:23:51 +03:00
Chris Nobody bf9b51caf4 gocomplete: do not suppress test failures
Ensure that the components of the `testing` package that rely on calling
`os.Exit` remain functional and any test failures are actually reported
back after the `monkey.Patch` in the `gocomplete.Example` test.

Fix #135
2021-04-01 10:46:54 +03:00
Eyal Posener 5d9f7f10f0 Fix failing go1.16 test
Fixes #132
2021-01-30 11:13:29 +02:00
Eyal Posener 7c7ab2f59a update module import path 2019-11-18 01:25:16 +02:00
Eyal Posener 8724aaf183 V2 2019-11-18 01:05:47 +02:00
Eyal Posener 7ee9623f2b Filter matches as a final stage
This simplifies the prediction logic writing, the predictor
doesn't need to filter our according to line matching, instead
it returns everything and the filtering is done at the end.

This does not break current behavior.
2017-11-04 10:51:40 +02:00
Eyal Posener a67bb12457 gocomplete: Add support for system GOPATH packages
fixes #41
2017-07-28 15:01:07 +03:00
Eyal Posener b3f5ec22d3 gocomplete: go run should also predict non-main functions 2017-05-18 23:40:02 +03:00
Eyal Posener 61d9904ba1 Fix './' prefix for file completion 2017-05-18 23:29:55 +03:00
Eyal Posener 3dd16239ee Add example test to increase coverate 2017-05-15 23:01:05 +03:00
Eyal Posener ff8cd4ed39 gocomplete: run only runnable go files
when typing 'go run', the completion will complete only go files
which are in main package and have a main function.
2017-05-15 22:50:05 +03:00