Open rsheasby opened 3 years ago
20 kb or 0.07% smaller isn't really a good reason to keep using pkger. Fact is pkger doesn't really seem to be maintained anymore, and IIRC @markbates has encouraged using go:embed on the Go Time podcast. I suspect he just hasn't got around to marking the repo archived or updating the readme.
True, it isn't much. So far I didn't see a reason to use that, if it makes the file slightly larger.
But if @markbates also encourages using go:embed
, I'll probably do the switch. :D
I may be mistaken, don't quote me on that. But I seem to remember he said something about it on Go Time.
Regardless, that shouldn't be the primary reason for switching. The primary reason for switching is because go:embed is actively maintained and reduces dependencies. pkger is no longer maintained, and if you have one less thing to download and one less potential supply chain attack, it's a no brainer. Plus no more go generate pre-build step required.
I just tried go:embed on two files I included via pkger before. It worked, but I noticed my binary is larger than before.
With
pkger
: 27,18 MB Withgo:embed
: 27,20 MB