Closed kooksee closed 3 years ago
Use go mod vendor
? golang #26366.
Thank you very much for answering my question. I have learned about go mod before. My solution is to put an init.go file in a static folder and then call this in a package such as gse file. In a nutshell, just treat static files as a go package, thanks.
You can use seg.LoadDictEmbed()
.
You can use
seg.LoadDictEmbed()
.
When I compile to binary, I can’t find the default dictionary
RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 GOARM=6 go build -ldflags '-w -s' -o main
@jw-star But there is due to can't reproduce.
I pulled gse through go mod, but I found that the dictionary data in gse was not pulled down, so I found a "Could not load dictionaries" error. Then, I copied the dictionary data into the gse package to run it through. So, I think,