2

I seem to be unable to find an answer to the question, does the godoc server support live reload changes in for my own projects?

According to this article it should be supported however whenever I change my code (update documentation) no changes appear until restart of the web server

My documentation updates/appear every time I start the the sever:

godoc -http=:6060 &

I don't want to restart the server for every change, is this expected behavior, what can I do to update my changes with the least amount of effort?

My go version:

$ go version
go version go1.8 darwin/amd64

Using browser with incognito mode:

Chrome Version 57.0.2987.133 (64-bit)
Adrian Forsius
  • 1,437
  • 2
  • 19
  • 29
  • 1
    It auto-reloads docs for me perfectly, works as intended. I changed something in docs in go source, refreshed page in browser, and I saw the changes. Need more info. – icza Apr 21 '17 at 15:29
  • 1
    Maybe it's a browser caching issue? Which browser are you using? – Jonathan Hall Apr 21 '17 at 15:31

1 Answers1

2

Godoc for a directory ("Directory /src/github.com/someuser" at the top) does not automatically update.

Godoc for a package ("Package yourthing" at the top) will automatically update, but you must reload the page to see the change.

Gabe Johnson
  • 1,393
  • 4
  • 16
  • 28