https://github.com/jiajunhuang/pasty
公司的项目用了 thrift,所以自己整 gRPC 来玩玩。以后就可以愉快的到处复制粘贴了。
感受:
看看 pasty 的使用:
jiajun@idea ~: type p
p is /home/jiajun/golang/bin/p
jiajun@idea ~: echo "hello" > test.txt
jiajun@idea ~: p < test.txt
jiajun@idea ~: p -limit 1
file id 3 created at 2018-04-10 23:19:03 +0800 CST ==================
hello
file id 3 created at 2018-04-10 23:19:03 +0800 CST over ==================
jiajun@idea ~: p -limit 1 -hint=false
hello
jiajun@idea ~: echo "hello world" | p
jiajun@idea ~: p -limit 1 -hint=false
hello world
jiajun@idea ~: p -limit 2 -hint=false
hello world
hello
jiajun@idea ~: p -limit 2
file id 4 created at 2018-04-10 23:19:35 +0800 CST ==================
hello world
file id 4 created at 2018-04-10 23:19:35 +0800 CST over ==================
file id 3 created at 2018-04-10 23:19:03 +0800 CST ==================
hello
file id 3 created at 2018-04-10 23:19:03 +0800 CST over ==================
1
wwwker 2018-04-11 15:26:38 +08:00
最近项目里面也整合了 grpc,确实还不错
|