borgo
borgo copied to clipboard
How to import external package
borgo's importer tool can import go std package and user's package, but how to impot other external package: in golang i can:
import "github.com/go-chi/chi/v5"
the corresponding usage in borgo:
use "github.com/go-chi/chi/v5"
or
use github.com/go-chi/chi/v5
neither works, how to import other package using borgo's importer tool, and how to use?
I am currently trying to add more definitions of std packages that are not included in the std
directory. I found out that for standard library, borgo uses std/modules.json
file to map the use some-package.sub-package
to (i assume) the internal directory structure that matches the package in go (e.g import "some-package/sub-package"
).
I feel like this is a hacky way to do the thing I want to do. Hope it helps