Then either compile the manifest using the rsrc tool, like this:
go get github.com/akavel/rsrc
rsrc -manifest test.manifest -o rsrc.syso
or rename the test.manifest file to test.exe.manifest and distribute it with the application instead.
Build app
In the directory containing test.go run
go build
To get rid of the cmd window, instead run
go build -ldflags="-H windowsgui"
Run app
test.exe
Sample Output (Windows 7)
More Examples
There are some examples that should get you started.
Application Manifest Files
Walk requires Common Controls 6. This means that you must put an appropriate application manifest file either next to your executable or embedded as a resource.
You can copy one of the application manifest files that come with the examples.
To embed a manifest file as a resource, you can use the rsrc tool.
IMPORTANT: If you don't embed a manifest as a resource, then you should not launch your executable before the manifest file is in place. If you do anyway, the program will not run properly. And worse, Windows will not recognize a manifest file, you later drop next to the executable. To fix this, rebuild your executable and only launch it with a manifest file in place.
Program Crashes
By default Go uses os threads with small stack sizes of 128KB. If your walk app crashes, it may be due to a stack overflow. Until a better solution is found, you can work around this by adding
import _ "runtime/cgo"
somewhere in your program. If you don't have gcc installed and on your PATH, you can alternatively add -linkmode internal to the -ldflags of your go build command like so:
go build -ldflags="-H windowsgui -linkmode internal"