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

Either fail or support multiple targets #42

Closed
bep opened this issue Oct 5, 2017 · 3 comments · Fixed by #45
Closed

Either fail or support multiple targets #42

bep opened this issue Oct 5, 2017 · 3 comments · Fixed by #45

Comments

@bep
Copy link

bep commented Oct 5, 2017

See gohugoio/hugo#3939

Good thing I tested.

So I just replaced make with mage and got:

mage hugoRace check

Wich does not fail. If you do not support multiple targets you really should exit with error + some error message.

@natefinch
Copy link
Member

So, the idea is that a target may want to process arguments itself. Right now you can have a target get os.Args and read off the second argument you give it.

There's a couple issues on this - #24 #34

See the discussion on #34 especially.

I agree that it is suboptimal as-is. Maybe an interim solution is to default to disallowing extra args, but have an opt-in variable you can set to say you want to process extra args yourself.

like

var ArgPassthrough = true

@bep
Copy link
Author

bep commented Oct 5, 2017

I agree that it is suboptimal as-is.

That isn't the word I would use. Having people moving from make to mage and think that their build is "green" when it's not, is everything a build system should not be about.

I think you should move extra args to a --args flag or something.

@natefinch
Copy link
Member

I'll make a PR to have mage fail with multiple args until we can flesh out how to run multiple targets in a sane way.

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

Successfully merging a pull request may close this issue.

2 participants