-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
filemapping: add support for io/fs (including e.g. go:embed filesystems) #16
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, this looks good. I wonder if you could add some unit test (also to see how this will be used in practice ). I wonder for example if "LocalFS" should be exported or part of some New*
helper and seeing how you use it or envision to use it would be helpful here :)
I think LocaleFS & LocalePath belong really closely together, I don't see why one would be exported and the other not, so no need to change the API IMO. I've added the FS usage to the example with go:embed to the README. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the test and the README.md addition. This looks very nice. Fwiw, I think it's fine if we bump from go-1.13 to go-1.18 in go.mod if you want to do a test that tests the go:embed
behavior
All done 👍 Edit: now finally all tests should pass, I obviously have a linux machine :D |
Thank you! |
This allows to e.g. use
//go:embed locales
to build the locales into the binary.