0

Is it possible to list just links/names to go dependencies? For example in Gopkg.lock I have:

[[projects]]
  digest = "x:xxxxxxx"
  name = "cloud.google.com/go"
  packages = [
    "xxxxx",
    "xxxxx/xxxxx",
  ]

I want just name: cloud.google.com/go be listed

Sergii Getman
  • 3,845
  • 5
  • 34
  • 50
  • `go list` just list the name of the current project. but actually i need a list of external dependencies – Sergii Getman Jan 28 '19 at 12:34
  • 1
    ```dep``` can't do it out of box. The easiest way is creating your own tool to parse Gopkg.lock. It shouldn't take more than half an hour. – bayrinat Jan 28 '19 at 12:45
  • 1
    Sorry, missed the `dep` part (though `go list` can list imports, or all dependencies, test imports, files etc). Since `cloud.google.com/go` is a package just like any other, I would also just parse your lock file for the information you want. – JimB Jan 28 '19 at 14:28
  • @bayrinat thanks, went that way – Sergii Getman Jan 29 '19 at 09:43

0 Answers0