{"action":"created","issue":{"url":"https://api.github.com/repos/golang/gddo/issues/185","repository_url":"https://api.github.com/repos/golang/gddo","labels_url":"https://api.github.com/repos/golang/gddo/issues/185/labels{/name}","comments_url":"https://api.github.com/repos/golang/gddo/issues/185/comments","events_url":"https://api.github.com/repos/golang/gddo/issues/185/events","html_url":"https://github.com/golang/gddo/issues/185","id":38656018,"number":185,"title":"Symlinks on Github not handled","user":{"login":"garyburd","id":33411,"avatar_url":"https://avatars.githubusercontent.com/u/33411?v=3","gravatar_id":"","url":"https://api.github.com/users/garyburd","html_url":"https://github.com/garyburd","followers_url":"https://api.github.com/users/garyburd/followers","following_url":"https://api.github.com/users/garyburd/following{/other_user}","gists_url":"https://api.github.com/users/garyburd/gists{/gist_id}","starred_url":"https://api.github.com/users/garyburd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/garyburd/subscriptions","organizations_url":"https://api.github.com/users/garyburd/orgs","repos_url":"https://api.github.com/users/garyburd/repos","events_url":"https://api.github.com/users/garyburd/events{/privacy}","received_events_url":"https://api.github.com/users/garyburd/received_events","type":"User","site_admin":false},"labels":[{"id":64893716,"url":"https://api.github.com/repos/golang/gddo/labels/bug","name":"bug","color":"e11d21","default":true},{"id":64896864,"url":"https://api.github.com/repos/golang/gddo/labels/help-wanted","name":"help-wanted","color":"5319e7","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2014-07-24T17:43:01Z","updated_at":"2016-12-08T22:21:25Z","closed_at":null,"body":"Gddo does not fetch the target of symlinks on GitHub. If a directory contains a symlinked .go file, go/build gives up with a parsing error on the link value and Gddo displays a not found error to the user.\n\nGddo uses the `git_url` to fetch the blob for a file ([source](https://github.com/golang/gddo/blob/0cc83381c232c327b233adc93131daab85f36264/gosrc/github.go#L106)). In the case of a symlink, the blob is the link value and not the target.\n\nGddo should switch to using the  [content API](https://developer.github.com/v3/repos/contents/#get-contents) to fetch the blobs. This API returns the target of the link.\n\nTo ensure a consistent view of a directory and its contents, gddo should fetch directories and files using the sha1 for the commit instead of the ref. \n\nThe source code links will not be correct because they will point to the link and not the target. I don't see an easy to fix this.\n"},"comment":{"url":"https://api.github.com/repos/golang/gddo/issues/comments/265873435","html_url":"https://github.com/golang/gddo/issues/185#issuecomment-265873435","issue_url":"https://api.github.com/repos/golang/gddo/issues/185","id":265873435,"user":{"login":"shurcooL","id":1924134,"avatar_url":"https://avatars.githubusercontent.com/u/1924134?v=3","gravatar_id":"","url":"https://api.github.com/users/shurcooL","html_url":"https://github.com/shurcooL","followers_url":"https://api.github.com/users/shurcooL/followers","following_url":"https://api.github.com/users/shurcooL/following{/other_user}","gists_url":"https://api.github.com/users/shurcooL/gists{/gist_id}","starred_url":"https://api.github.com/users/shurcooL/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shurcooL/subscriptions","organizations_url":"https://api.github.com/users/shurcooL/orgs","repos_url":"https://api.github.com/users/shurcooL/repos","events_url":"https://api.github.com/users/shurcooL/events{/privacy}","received_events_url":"https://api.github.com/users/shurcooL/received_events","type":"User","site_admin":false},"created_at":"2016-12-08T22:21:25Z","updated_at":"2016-12-08T22:21:25Z","body":"> hmm, I figure this is why https://github.com/berlincount/jsonstruct isn't being indexed?\r\n\r\nHow's that? https://godoc.org/github.com/berlincount/jsonstruct seems okay to me."}}
{"actor":{"display_login":"shurcooL"}}