-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Exposed modules-download-mode as a command line option #781
Conversation
Hi, why do you need to control it from Makefile? |
Hi, we use go modules, but also keep vendor up to date for now. Our Makefile uses vendoring by default, but when I'm developing locally, I need to point some modules to my local forks, and that's easier done without vendoring (by using replace). I have modified our Makefile so that I can turn vendoring off simply by running `VENDOR=false make`, but it doesn't apply to the linting step, which uses golangcli-lint. Hence the extra flag.
Thanks.
… On 4 Oct 2019, at 10.25, Isaev Denis ***@***.***> wrote:
Hi, why do you need to control it from Makefile?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub <#781?email_source=notifications&email_token=AAG2XLYS3VQBPOVYDMMHG3TQM34XZA5CNFSM4I5MBM52YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEAK46JA#issuecomment-538300196>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AAG2XL4ZKO5U4GDSTRZO2K3QM34XZANCNFSM4I5MBM5Q>.
|
@pstibrany, @jirfag Does it make sense to just have golangci-lint use the same flags and resolution strategy as the Go tool chain |
It seems to me that all golang-cli does is to pass the configured value to -mod parameter when running go tools. I'm fine with renaming the parameter to -mod. I have tried to use GOFLAGS, but that didn't work, and exposing the parameter seemed like smaller change than making GOFLAGS work :) |
|
What about |
I like your ‘modules-download-mode’ |
I don't mind using either, it's just a name. More important to me is whether I can quickly find out what it does. "-mod" would be more familiar to people since it's the same as used by Go, "-modules-download-mode" is consistent with .golangci.yml. But grepping I was wondering more about passing GOFLAGS env when calling go tools. Do you want to do that as part of this PR? |
This tiny change exposes modules-download-mode as a command line option, allowing us to easily control it from Makefile.