Add on-init hook command (#1838)

This commit is contained in:
Joe Lim authored and GitHub committed 2024-11-06 12:12:12 +11:00
1 parent 0b51987044
commit 670343a23f
5 files changed
+27 -2

No files matched your search

+2 -1
View File
@@ -117,7 +117,7 @@ func readExpr() <-chan expr {
ch := make(chan expr)
go func() {
duration := 1 * time.Second
duration := 100 * time.Millisecond
c, err := net.Dial(gSocketProt, gSocketPath)
for err != nil {
@@ -130,6 +130,7 @@ func readExpr() <-chan expr {
fmt.Fprintf(c, "conn %d\n", gClientID)
ch <- &callExpr{"sync", nil, 1}
ch <- &callExpr{"on-init", nil, 1}
s := bufio.NewScanner(c)
for s.Scan() {