Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Notes for install with godep #39

Open
gecko655 opened this issue Apr 8, 2019 · 2 comments
Open

Notes for install with godep #39

gecko655 opened this issue Apr 8, 2019 · 2 comments
Labels

Comments

@gecko655
Copy link
Contributor

gecko655 commented Apr 8, 2019

Issue

I'm using godep for installing dependency, including gotron.
At the beginning, I configured Gopkg.toml like:

[prune]
  go-tests = true
  unused-packages = true

[[constraint]]
  name = "github.com/Equanox/gotron"
  branch = "master"

This config file causes the error: my/project/vendor/github.com/Equanox/gotron/templates/app: no such file or directory because templates/ folder in this project does not contain any *.go files and godep prunes such subfolders.

$ ls -la vendor/github.com/Equanox/gotron/
total 232
drwxr-xr-x  17 user group 544  4  8 11:52 .
drwxr-xr-x   3 user group 96  4  8 12:28 ..
-rw-r--r--   1 user group 225  4  8 11:52 .gitignore
-rw-r--r--   1 user group 519  4  8 11:52 .travis.yml
-rw-r--r--   1 user group 4975  4  8 11:52 BrowserWindow.md
-rw-r--r--   1 user group 1073  4  8 11:52 LICENSE
-rw-r--r--   1 user group 1475  4  8 11:52 Makefile
-rw-r--r--   1 user group 4932  4  8 11:52 README.md
-rw-r--r--   1 user group 41003  4  8 11:52 browser_window_instance_methods.go
-rw-r--r--   1 user group 6674  4  8 11:52 browser_window_options.go
-rw-r--r--   1 user group 708  4  8 11:52 go.mod
-rw-r--r--   1 user group 3432  4  8 11:52 go.sum
-rw-r--r--   1 user group 6909  4  8 11:52 gotron.go
-rw-r--r--   1 user group 5823  4  8 11:52 gotron_methods.go
-rw-r--r--   1 user group 2453  4  8 11:52 gotron_methods_pack.go
drwxr-xr-x   4 user group 128  4  8 11:52 internal
-rw-r--r--   1 user group 216  4  8 11:52 logging.go

Solution

I had to add these lines to Gopkg.toml, to download the template/app folder and other non-go folders.

[prune]
  go-tests = true
  unused-packages = true

+  [[prune.project]]
+    name = "github.com/Equanox/gotron"
+    unused-packages = false
+

[[constraint]]
  name = "github.com/Equanox/gotron"
  branch = "master"

golang/dep#1890 (comment)

I think this is a godep specific issue, but creating issue within gotron repository may help someone who also encountered this problem.

@gecko655
Copy link
Contributor Author

gecko655 commented Apr 8, 2019

So, document about it if the mentainer(s) want to do, or just close the issue if not.

@Equanox Equanox added the godep label Apr 10, 2019
@Equanox
Copy link
Owner

Equanox commented Apr 10, 2019

Good point. Definitely worth mentioning. Will be a candidate for FAQ.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants