tiup icon indicating copy to clipboard operation
tiup copied to clipboard

tiup client does not accept input on STDIN

Open morgo opened this issue 4 years ago • 0 comments

Bug Report

Please answer these questions before submitting your issue. Thanks!

  1. What did you do?

tiup client does not accept input on STDIN. This makes it hard to use as a replacement for mysql with any scripting.

  1. What did you expect to see?
$ echo "show databases" | mysql
Database
INFORMATION_SCHEMA
METRICS_SCHEMA
PERFORMANCE_SCHEMA
mysql
test
  1. What did you see instead?
$ echo "show databases" | tiup client
Starting component `client`: 
Connected with driver mysql (5.7.25-TiDB-v4.0.12)
  1. What version of TiUP are you using (tiup --version)?
$ tiup --version
1.4.0 tiup
Go Version: go1.16.2
Git Ref: v1.4.0
GitHash: eb335e6ad9d0dc19d1c43db422cd409d62bc3cea

morgo avatar Apr 06 '21 23:04 morgo