Closed javedjakali786 closed 1 year ago
You need to run main.go or built executable, after that config.json will be created. To run bot, you need golang: go run main.go
go run main.go main.go:4:2: cannot find package "github.com/NexonSU/telegram-go-chatbot/checkpoint" in any of: /usr/lib/go-1.10/src/github.com/NexonSU/telegram-go-chatbot/checkpoint (from $GOROOT) /root/go/src/github.com/NexonSU/telegram-go-chatbot/checkpoint (from $GOPATH) main.go:5:2: cannot find package "github.com/NexonSU/telegram-go-chatbot/commands" in any of: /usr/lib/go-1.10/src/github.com/NexonSU/telegram-go-chatbot/commands (from $GOROOT) /root/go/src/github.com/NexonSU/telegram-go-chatbot/commands (from $GOPATH) main.go:6:2: cannot find package "github.com/NexonSU/telegram-go-chatbot/duel" in any of: /usr/lib/go-1.10/src/github.com/NexonSU/telegram-go-chatbot/duel (from $GOROOT) /root/go/src/github.com/NexonSU/telegram-go-chatbot/duel (from $GOPATH) main.go:7:2: cannot find package "github.com/NexonSU/telegram-go-chatbot/pidor" in any of: /usr/lib/go-1.10/src/github.com/NexonSU/telegram-go-chatbot/pidor (from $GOROOT) /root/go/src/github.com/NexonSU/telegram-go-chatbot/pidor (from $GOPATH) main.go:8:2: cannot find package "github.com/NexonSU/telegram-go-chatbot/stats" in any of: /usr/lib/go-1.10/src/github.com/NexonSU/telegram-go-chatbot/stats (from $GOROOT) /root/go/src/github.com/NexonSU/telegram-go-chatbot/stats (from $GOPATH) main.go:9:2: cannot find package "github.com/NexonSU/telegram-go-chatbot/utils" in any of: /usr/lib/go-1.10/src/github.com/NexonSU/telegram-go-chatbot/utils (from $GOROOT) /root/go/src/github.com/NexonSU/telegram-go-chatbot/utils (from $GOPATH) main.go:10:2: cannot find package "gopkg.in/telebot.v3" in any of: /usr/lib/go-1.10/src/gopkg.in/telebot.v3 (from $GOROOT) /root/go/src/gopkg.in/telebot.v3 (from $GOPATH)
Did you downloaded everything from repo? If not, download everything and only then run main.go. If yes, then try to run "go get github.com/NexonSU/telegram-go-chatbot"
I have filled config.json file. Now to how to execute bot
Exactly the same way, "go run main.go".
~/telegram-go-chatbot $ go run main.go
In file included from z_libwebp_src_enc_picture_csp_enc.c:9: ../go/pkg/mod/github.com/chai2010/webp@v1.1.1/internal/libwebp-1.0.2/src/enc/picture_csp_enc.c:1002:40: warning: result of '2 ^ ALPHA_OFFSET' is 1; did you mean '1 << ALPHA_OFFSET' (8)? [-Wxor-used-as-pow] ../go/pkg/mod/github.com/chai2010/webp@v1.1.1/internal/libwebp-1.0.2/src/enc/picture_csp_enc.c:1002:40: note: replace expression with '0x2 ^ ALPHA_OFFSET' to silence this warning
2022/11/05 18:52:01 /data/data/com.termux/files/home/go/pkg/mod/gorm.io/gorm@v1.24.1/callbacks.go:134 record not found
[0.089ms] [rows:0] SELECT * FROM users
ORDER BY users
.id
DESC LIMIT 1
Seems like, it works.
where is config file and how to run in vps