Go applications are designed to run from a single binary file. This means they can be easily distributed and do not rely on installation scripts. Unfortunately, this benefit results in a cost for developers—we cannot rely on resources being found next to our applications in the way that web or mobile app developers can (as we have been doing during development). To ensure that our applications conform to this design, we must embed any required assets into the application binary. This includes fonts, images, and any other static content that's needed for the application to operate correctly.
GUI-based applications are not alone in needing to solve this challenge so there are many solutions already available. The most commonly utilized tool is called go-bindata
and is available from github.com/jteeuwen/go-bindata. It is a simple utility that converts static files in to Go source code so they can be compiled into an application. This approach is the easiest to work...