Merge pull request #6 from zackzhangkai/main

fix var init
main v0.4.4
Tony Worm 12 months ago committed by GitHub
commit 51618adc78
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -169,7 +169,7 @@ func main() {
// no args, or interactive... read from stdin
// this is mainly for replacing text in vim
fi, _ := os.Stdin.Stat()
inputIsFromPipe = (fi.Mode() & os.ModeCharDevice) == 0
inputIsFromPipe := (fi.Mode() & os.ModeCharDevice) == 0
if len(args) == 0 && !PromptMode && inputIsFromPipe {
reader := bufio.NewReader(os.Stdin)
var buf bytes.Buffer

Loading…
Cancel
Save