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

Go run shell commands properly #42

Merged
merged 2 commits into from
Jul 8, 2016
Merged

Go run shell commands properly #42

merged 2 commits into from
Jul 8, 2016

Conversation

at15
Copy link
Member

@at15 at15 commented Jul 8, 2016

Fixes #41

  • use go-shellquote to split string like shell, the the proper Command is constructed
  • use sh -c for commands that reuqires subshell

Thanks to https://github.com/github/hub/blob/master/cmd/cmd.go

at15 added 2 commits July 9, 2016 00:26
By passing the test command using native exec.Command, the test can run.
Though there is a compile error for two main package in same folder

Issues #41 #7
- use shell quote to split
- use sh -c to execute
@at15 at15 self-assigned this Jul 8, 2016
@at15 at15 added the type/bug label Jul 8, 2016
@at15 at15 merged commit ae4da24 into master Jul 8, 2016
@at15 at15 deleted the todo/exec branch July 8, 2016 16:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant