You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I propose that when running 'make install,' we should embed the standard libraries, examples folder, and other dynamic dependencies into the binary. This approach allows us to develop without worrying about the location of the cloned directory.
Using gno mod download for standard libraries, although this approach can be error-prone during development.
Embedding the source code with go:embed so that the file system is not required to retrieve configuration. This embedding should occur only when running 'make install,' while using 'go run ./...' would allow developers to skip embedding and work with the most up-to-date source.
Initially, I leaned towards option 1, but I recommend considering the third option. It encourages GNOROOT but doesn't make it mandatory.
So, I've given this some thought. While I still believe that long-term, we want to encourage also all "proper" installations to have the stdlibs they use as inspectable files, I do agree that embedding the stdlibs directory will lead to the gno command not needing any configuration to set up, even without other OS configuration.
The standard libraries are a few megabytes. So, my proposed plan is this:
go:embed stdlibs
gno does not require a GNOROOT / root-dir anymore; gnoland does (for the examples directory)
If any of the current methods for finding GNOROOT work (flag, env var, go list), then we use that as a GNOROOT.
I propose that when running 'make install,' we should embed the standard libraries, examples folder, and other dynamic dependencies into the binary. This approach allows us to develop without worrying about the location of the cloned directory.
We have a few options to consider:
$GNOROOT
environment variable (feat: add 'gno env' subcommand #1233).gno mod download
for standard libraries, although this approach can be error-prone during development.go:embed
so that the file system is not required to retrieve configuration. This embedding should occur only when running 'make install,' while using 'go run ./...' would allow developers to skip embedding and work with the most up-to-date source.Initially, I leaned towards option 1, but I recommend considering the third option. It encourages GNOROOT but doesn't make it mandatory.
cc @thehowl, as this relates to #814.
The text was updated successfully, but these errors were encountered: