-
Notifications
You must be signed in to change notification settings - Fork 438
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
Provide built-in Godep support #309
Conversation
@meatballhat Could you take a look at this one when you get a chance? |
@@ -33,6 +33,7 @@ def setup | |||
# easier to find and our `git clone`'d libraries are found by the | |||
# `go` commands. | |||
set 'GOPATH', "#{HOME_DIR}/gopath:$GOPATH" | |||
set 'PATH', "$PATH:$GOPATH/bin" |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
I'm actually not convinced that this works. A failure occurs in a .travis.yml that looks like this: language: go
go: 1.3.1
install:
- go get github.com/tools/godep
- godep restore
script:
- go test
- test -z "$(go fmt ./...)" It has to be modified to include |
I think the go defaults should be modified to prepend ~/gopath/bin to
|
@meatballhat This PR adds $GOPATH/bin to $PATH as a default. Is that not he behavior that you'd like. If not, can you let me know how you'd like it to look, and I can modify it. |
I've adjusted the |
@@ -41,6 +42,10 @@ def setup | |||
|
|||
def install | |||
uses_make? then: 'true', else: "#{go_get} #{gobuild_args} ./...", fold: 'install', retry: true | |||
self.if '-f Godeps/Godeps.json' do |sub| | |||
sub.cmd "#{go_get} github.com/tools/godep", echo: true, retry: true, timing: true, assert: true | |||
sub.cmd "godep restore", retry: true, timing: true, assert: true, echo: true |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
w00t! Merging this now + deploying to staging. |
Provide built-in Godep support
Appears to work 👏 https://staging.travis-ci.org/meatballhat/yolo-octo-adventure/jobs/392466 @joshk @BanzaiMan any opinions on the UX? Any folds necessary? |
Looks like we need to disable this below go1.1: https://staging.travis-ci.org/meatballhat/yolo-octo-adventure/jobs/392469 |
@zackkitzmiller I need to get back to GiveCamp. Any chance you can submit a follow up PR to disable when the version is under 1.1? |
Will do. Need about an hour, I'm out at the moment. |
@zackkitzmiller 👍 thank you! |
Made a new PR. Thanks guys. |
Looks happy in staging now: https://staging.travis-ci.org/meatballhat/yolo-octo-adventure/builds/392468 |
Hey, I'm a little late here, but I think it would be better to edit |
@kr I'm a fan 👍 @zackkitzmiller willing to PR it up? 😺 |
Oh and regardless of my previous comment, thanks so much for doing this!!! So awesome. :) |
Hey all, so I think that's a great option, and we should add it, but there are a lot of people that have a
And while several project do vendor everything, not all do. Can we come up with a solution that satisfies everyone? |
Personally I would rather not encourage that sort of gitignore, so I suggest not adding code to accommodate it. But I understand if you want to. Does anyone have real numbers for projects that do this vs ones that commit all the vendored code? If both styles must be supported, perhaps check for the existence of |
I understand the hesitation to encourage that sort of .gitignore, but I've seen it in several projects. Enough to suggest we support the fallback solution. I can code that up a some point tomorrow. I think that's reasonable. |
Until today, those gitignore projects had to code up their own travis.yml support anyway, so it's not like they're losing much by having that state of affairs continue. The most important thing in good product management is knowing how to say "no". (Ok I think that's all I have to say on the subject. I also agree that the fallback is reasonable, and it's your call of course. 😄) |
@kr Then for now, I'll build in a fallback. ;) I do agree with the heart of your post, and believe we should encourage people who are vendoring to properly vendor. In the mean time, I think we should lower the friction to automated testing as to as close to zero as possible. |
Cool 👍. Thanks so much for doing the actual work while I sit here lobbing comments from the peanut gallery. ;) |
@kr ❤️ |
1 similar comment
@kr ❤️ |
fwiw, I'd like to suggest (if it's at all possible without appearing to be self-promoting) that we add support for deppy, which is the |
I love you all, so much love in this thread! |
@meatballhat Respectfully, I believe that should be a new issue/PR. |
@zackkitzmiller very much agreed 😃 |
As suggested by Josh Kalderimis here.