remove empty publish dir

This commit is contained in:
Ethan Buchman 2018-04-05 13:34:59 +03:00
parent 9fbbdbbe0f
commit c74c57a2f0
1 changed files with 0 additions and 62 deletions

View File

@ -1,62 +0,0 @@
// +build scripts
package main
/*
import (
"encoding/json"
"fmt"
"os"
"time"
"github.com/gorilla/websocket"
"github.com/tendermint/go-wire"
_ "github.com/tendermint/tendermint/rpc/core/types" // Register RPCResponse > Result types
"github.com/tendermint/tendermint/rpc/lib/client"
"github.com/tendermint/tendermint/rpc/lib/types"
cmn "github.com/tendermint/tmlibs/common"
)
func main() {
ws := rpcclient.NewWSClient(os.Args[1]+":46657", "/websocket")
_, err := ws.Start()
if err != nil {
cmn.Exit(err.Error())
}
// Read a bunch of responses
go func() {
for {
res, ok := <-ws.ResultsCh
if !ok {
break
}
//fmt.Println(counter, "res:", Blue(string(res)))
var result []interface{}
err := json.Unmarshal([]byte(string(res)), &result)
if err != nil {
Exit("Error unmarshalling block: " + err.Error())
}
height := result[1].(map[string]interface{})["block"].(map[string]interface{})["header"].(map[string]interface{})["height"]
txs := result[1].(map[string]interface{})["block"].(map[string]interface{})["data"].(map[string]interface{})["txs"]
if len(txs.([]interface{})) > 0 {
fmt.Println(">>", height, txs)
}
}
}()
for i := 0; i < 100000; i++ {
request := rpctypes.NewRPCRequest("fakeid", "block", Arr(i))
reqBytes := wire.JSONBytes(request)
err = ws.WriteMessage(websocket.TextMessage, reqBytes)
if err != nil {
cmn.Exit("writing websocket request: " + err.Error())
}
}
time.Sleep(time.Second * 1000)
ws.Stop()
}
*/