Skip to content
This repository has been archived by the owner on Sep 9, 2020. It is now read-only.

remove getGOPATHS; cleanup #785

Merged
merged 2 commits into from
Jun 25, 2017
Merged

remove getGOPATHS; cleanup #785

merged 2 commits into from
Jun 25, 2017

Conversation

jmank88
Copy link
Collaborator

@jmank88 jmank88 commented Jun 22, 2017

What does this do / why do we need it?

This change:

  1. Removes the getGOPATHs function
  2. Embeds a slimmer version (w/o unused parameter) in place of it's only usage in SetPaths
  3. Updates out of date docs for SetPaths

Which issue(s) does this PR fix?

Related #672

Copy link
Collaborator

@darkowlzz darkowlzz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! 👍

Copy link
Collaborator

@ibrasho ibrasho left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just one nit. Otherwise, LGTM.

context.go Outdated
// }
//
// SetPaths sets the WorkingDir and GOPATHs fields. If GOPATHs are omitted, then
// the $GOPATH environment variable, and the default GOPATH are checked - in that order.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"are checked" doesn't really explain what's happening.
How about something along these lines?

// SetPaths sets the WorkingDir and GOPATHs fields. If GOPATHs is empty, then
// the GOPATH environment variable (or the default GOPATH) is used instead.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated.

@darkowlzz
Copy link
Collaborator

Thanks for simplifying it 👍

@darkowlzz darkowlzz merged commit f16f7a8 into golang:master Jun 25, 2017
@jmank88 jmank88 deleted the getGOPATHs branch February 2, 2018 21:07
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants