fix go mod

This commit is contained in:
kayos 2021-07-11 18:51:19 -07:00
parent b9ab36ebe2
commit a962cc8abe
24 changed files with 42 additions and 42 deletions

View File

@ -8,15 +8,15 @@ next release.
### What's new?
* Add `prompt.FuzzyFilter` for fuzzy matching at [#92](https://github.com/c-bata/go-prompt/pull/92).
* Add `OptionShowCompletionAtStart` to show completion at start at [#100](https://github.com/c-bata/go-prompt/pull/100).
* Add `prompt.NewStderrWriter` at [#102](https://github.com/c-bata/go-prompt/pull/102).
* Add `prompt.FuzzyFilter` for fuzzy matching at [#92](https://git.tcp.direct/tcp.direct/go-prompt/pull/92).
* Add `OptionShowCompletionAtStart` to show completion at start at [#100](https://git.tcp.direct/tcp.direct/go-prompt/pull/100).
* Add `prompt.NewStderrWriter` at [#102](https://git.tcp.direct/tcp.direct/go-prompt/pull/102).
### Fixed
* Fix resetting display attributes (please see [pull #104](https://github.com/c-bata/go-prompt/pull/104) for more details).
* Fix error handling of Flush function in ConsoleWriter (please see [pull #97](https://github.com/c-bata/go-prompt/pull/97) for more details).
* Fix panic problem when reading from stdin before starting the prompt (please see [issue #88](https://github.com/c-bata/go-prompt/issues/88) for more details).
* Fix resetting display attributes (please see [pull #104](https://git.tcp.direct/tcp.direct/go-prompt/pull/104) for more details).
* Fix error handling of Flush function in ConsoleWriter (please see [pull #97](https://git.tcp.direct/tcp.direct/go-prompt/pull/97) for more details).
* Fix panic problem when reading from stdin before starting the prompt (please see [issue #88](https://git.tcp.direct/tcp.direct/go-prompt/issues/88) for more details).
### Removed or Deprecated
@ -28,7 +28,7 @@ next release.
* Support CJK(Chinese, Japanese and Korean) and Cyrillic characters.
* Add OptionCompletionWordSeparator(x string) to customize insertion points for completions.
* To support this, text query functions by arbitrary word separator are added in Document (please see [here](https://github.com/c-bata/go-prompt/pull/79) for more details).
* To support this, text query functions by arbitrary word separator are added in Document (please see [here](https://git.tcp.direct/tcp.direct/go-prompt/pull/79) for more details).
* Add FilePathCompleter to complete file path on your system.
* Add option to customize ascii code key bindings.
* Add GetWordAfterCursor method in Document.
@ -61,8 +61,8 @@ next release.
### Fixed
* Fix the behavior of `Ctrl+W` keybind.
* Fix the panic because when running on a docker container (please see [here](https://github.com/c-bata/go-prompt/pull/32) for details).
* Fix panic when making terminal window small size after input 2 lines of texts. See [here](https://github.com/c-bata/go-prompt/issues/37) for details).
* Fix the panic because when running on a docker container (please see [here](https://git.tcp.direct/tcp.direct/go-prompt/pull/32) for details).
* Fix panic when making terminal window small size after input 2 lines of texts. See [here](https://git.tcp.direct/tcp.direct/go-prompt/issues/37) for details).
* And also fixed many bugs that layout is broken when using Terminal.app, GNU Terminal and a Goland(IntelliJ).
### News

View File

@ -1,9 +1,9 @@
# go-prompt
[![Go Report Card](https://goreportcard.com/badge/github.com/c-bata/go-prompt)](https://goreportcard.com/report/github.com/c-bata/go-prompt)
[![Go Report Card](https://goreportcard.com/badge/git.tcp.direct/tcp.direct/go-prompt)](https://goreportcard.com/report/git.tcp.direct/tcp.direct/go-prompt)
![Software License](https://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat-square)
[![GoDoc](https://godoc.org/github.com/c-bata/go-prompt?status.svg)](https://godoc.org/github.com/c-bata/go-prompt)
![tests](https://github.com/c-bata/go-prompt/workflows/tests/badge.svg)
[![GoDoc](https://godoc.org/git.tcp.direct/tcp.direct/go-prompt?status.svg)](https://godoc.org/git.tcp.direct/tcp.direct/go-prompt)
![tests](https://git.tcp.direct/tcp.direct/go-prompt/workflows/tests/badge.svg)
A library for building powerful interactive prompts inspired by [python-prompt-toolkit](https://github.com/jonathanslenders/python-prompt-toolkit),
making it easier to build cross-platform command line tools using Go.
@ -13,7 +13,7 @@ package main
import (
"fmt"
"github.com/c-bata/go-prompt"
"git.tcp.direct/tcp.direct/go-prompt"
)
func completer(d prompt.Document) []prompt.Suggest {
@ -65,7 +65,7 @@ func main() {
### Flexible options
go-prompt provides many options. Please check [option section of GoDoc](https://godoc.org/github.com/c-bata/go-prompt#Option) for more details.
go-prompt provides many options. Please check [option section of GoDoc](https://godoc.org/git.tcp.direct/tcp.direct/go-prompt#Option) for more details.
[![options](https://github.com/c-bata/assets/raw/master/go-prompt/prompt-options.png)](#flexible-options)
@ -109,8 +109,8 @@ We have confirmed go-prompt works fine in the following terminals:
## Links
* [Change Log](./CHANGELOG.md)
* [GoDoc](http://godoc.org/github.com/c-bata/go-prompt)
* [gocover.io](https://gocover.io/github.com/c-bata/go-prompt)
* [GoDoc](http://godoc.org/git.tcp.direct/tcp.direct/go-prompt)
* [gocover.io](https://gocover.io/git.tcp.direct/tcp.direct/go-prompt)
## Author

View File

@ -4,7 +4,7 @@ import (
"os"
"os/exec"
prompt "github.com/c-bata/go-prompt"
prompt "git.tcp.direct/tcp.direct/go-prompt"
)
func executor(t string) {

View File

@ -10,7 +10,7 @@ import (
"path"
"strings"
prompt "github.com/c-bata/go-prompt"
prompt "git.tcp.direct/tcp.direct/go-prompt"
)
type RequestContext struct {

View File

@ -3,7 +3,7 @@ package main
import (
"fmt"
prompt "github.com/c-bata/go-prompt"
prompt "git.tcp.direct/tcp.direct/go-prompt"
)
var LivePrefixState struct {

View File

@ -3,7 +3,7 @@ package main
import (
"fmt"
prompt "github.com/c-bata/go-prompt"
prompt "git.tcp.direct/tcp.direct/go-prompt"
)
func executor(in string) {

View File

@ -3,7 +3,7 @@ package main
import (
"fmt"
prompt "github.com/c-bata/go-prompt"
prompt "git.tcp.direct/tcp.direct/go-prompt"
)
func completer(in prompt.Document) []prompt.Suggest {

View File

@ -5,8 +5,8 @@ import (
"os"
"strings"
prompt "github.com/c-bata/go-prompt"
"github.com/c-bata/go-prompt/completer"
prompt "git.tcp.direct/tcp.direct/go-prompt"
"git.tcp.direct/tcp.direct/go-prompt/completer"
)
var filePathCompleter = completer.FilePathCompleter{

View File

@ -6,8 +6,8 @@ import (
"fmt"
"syscall"
prompt "github.com/c-bata/go-prompt"
"github.com/c-bata/go-prompt/internal/term"
prompt "git.tcp.direct/tcp.direct/go-prompt"
"git.tcp.direct/tcp.direct/go-prompt/internal/term"
)
func main() {

View File

@ -3,7 +3,7 @@ package prompt
import (
"strings"
"github.com/c-bata/go-prompt/internal/debug"
"git.tcp.direct/tcp.direct/go-prompt/internal/debug"
)
// Buffer emulates the console buffer.

View File

@ -7,8 +7,8 @@ import (
"path/filepath"
"runtime"
prompt "github.com/c-bata/go-prompt"
"github.com/c-bata/go-prompt/internal/debug"
prompt "git.tcp.direct/tcp.direct/go-prompt"
"git.tcp.direct/tcp.direct/go-prompt/internal/debug"
)
var (

View File

@ -3,7 +3,7 @@ package prompt
import (
"strings"
"github.com/c-bata/go-prompt/internal/debug"
"git.tcp.direct/tcp.direct/go-prompt/internal/debug"
runewidth "github.com/mattn/go-runewidth"
)

View File

@ -4,8 +4,8 @@ import (
"strings"
"unicode/utf8"
"github.com/c-bata/go-prompt/internal/bisect"
istrings "github.com/c-bata/go-prompt/internal/strings"
"git.tcp.direct/tcp.direct/go-prompt/internal/bisect"
istrings "git.tcp.direct/tcp.direct/go-prompt/internal/strings"
runewidth "github.com/mattn/go-runewidth"
)

View File

@ -242,7 +242,7 @@ func TestDocument_DisplayCursorPosition(t *testing.T) {
// If you're facing test failure on this test case and your terminal is iTerm2,
// please check 'Profile -> Text' configuration. 'Use Unicode version 9 widths'
// must be checked.
// https://github.com/c-bata/go-prompt/pull/99
// https://git.tcp.direct/tcp.direct/go-prompt/pull/99
document: &Document{
Text: "Добрый день",
cursorPosition: 3,

View File

@ -1,6 +1,6 @@
package prompt
import "github.com/c-bata/go-prompt/internal/debug"
import "git.tcp.direct/tcp.direct/go-prompt/internal/debug"
/*

2
go.mod
View File

@ -1,4 +1,4 @@
module github.com/c-bata/go-prompt
module git.tcp.direct/tcp.direct/go-prompt
go 1.14

View File

@ -5,7 +5,7 @@ package prompt
import (
"syscall"
"github.com/c-bata/go-prompt/internal/term"
"git.tcp.direct/tcp.direct/go-prompt/internal/term"
"golang.org/x/sys/unix"
)

View File

@ -5,7 +5,7 @@ import (
"math/rand"
"testing"
"github.com/c-bata/go-prompt/internal/bisect"
"git.tcp.direct/tcp.direct/go-prompt/internal/bisect"
)
func Example() {

View File

@ -3,7 +3,7 @@ package strings_test
import (
"fmt"
"github.com/c-bata/go-prompt/internal/strings"
"git.tcp.direct/tcp.direct/go-prompt/internal/strings"
)
func ExampleIndexNotByte() {

View File

@ -214,7 +214,7 @@ func (w *VT100Writer) SetColor(fg, bg Color, bold bool) {
w.SetDisplayAttributes(fg, bg, DisplayBold)
} else {
// If using `DisplayDefualt`, it will be broken in some environment.
// Details are https://github.com/c-bata/go-prompt/pull/85
// Details are https://git.tcp.direct/tcp.direct/go-prompt/pull/85
w.SetDisplayAttributes(fg, bg, DisplayReset)
}
}

View File

@ -5,7 +5,7 @@ import (
"os"
"time"
"github.com/c-bata/go-prompt/internal/debug"
"git.tcp.direct/tcp.direct/go-prompt/internal/debug"
)
// Executor is called when user input something text.

View File

@ -3,7 +3,7 @@ package prompt
import (
"runtime"
"github.com/c-bata/go-prompt/internal/debug"
"git.tcp.direct/tcp.direct/go-prompt/internal/debug"
runewidth "github.com/mattn/go-runewidth"
)

View File

@ -7,7 +7,7 @@ import (
"os/signal"
"syscall"
"github.com/c-bata/go-prompt/internal/debug"
"git.tcp.direct/tcp.direct/go-prompt/internal/debug"
)
func (p *Prompt) handleSignals(exitCh chan int, winSizeCh chan *WinSize, stop chan struct{}) {

View File

@ -7,7 +7,7 @@ import (
"os/signal"
"syscall"
"github.com/c-bata/go-prompt/internal/debug"
"git.tcp.direct/tcp.direct/go-prompt/internal/debug"
)
func (p *Prompt) handleSignals(exitCh chan int, winSizeCh chan *WinSize, stop chan struct{}) {