-
Notifications
You must be signed in to change notification settings - Fork 128
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
Allowed customize SysProcAttr #53
Comments
It's a good idea to me. I do want to setup the
|
currently using this fork #54 |
Re #54: do you just wanted to set |
I prefer the general-purpose callback, like use this if you know what you are doing. |
Thanks @daniel-nichter for looking into this. For my user case, both will work fine. I would vote for the general-purpose callback although(as in #54 ) as it will give people a lot more flexibility on using this cool tool. |
@wenerme @Callisto13 et al. I merged PR #54 but reworked in PR #75. Here's why...
p := cmd.NewCmdOptions(
cmd.Options{
SetCmd: []func(cmd *exec.Cmd){
func(cmd *exec.Cmd) { handled = true },
},
},
"/bin/ls",
) If that doesn't work, then I could add |
lgtm, but SetCmd feels strange, more like BeforeExec or something, like hook |
Yeah, the same occurred to me and I wrote it as |
Renamed to |
e.g. windows need to set HideWindow
maybe cmd can accept option like this
The text was updated successfully, but these errors were encountered: