Monday, April 27, 2015

golang required import foo

I was working with a 3rd party library that insisted that I import a particular dependency. The problem was that the package was NEVER referenced.  It turned out that there is a bit of FOO in the package declaration:
package osext // import "github.com/kardianos/osext"
That comment at the end of the line tell the compiler to do something. Here is an odd place to put this doc but I think it reflects the intent as it may be the official proposal. At least it seems to work this way.

No comments:

Post a Comment

another bad day for open source

One of the hallmarks of a good open source project is just how complicated it is to install, configure and maintain. Happily gitlab and the ...