-
Notifications
You must be signed in to change notification settings - Fork 9
add --login for shell to support directly run from xcode #54
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
Conversation
@@ -26,7 +26,7 @@ enum Shell { | |||
// print("*** running script: \(script)") | |||
let task = Process() | |||
task.standardError = FileHandle.standardError | |||
task.arguments = ["-c", script] | |||
task.arguments = ["--login", "-c", script] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we really need shell here just to run npm scripts.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If without this, the Xcode report can't find swiftformat
. Same with the npm start.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The right way to do it is telling PATH env var to Xcode scheme
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not familiar with environment variables, could you provide the values that need to be set?
And what is the down side of adding --login
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's not yours fault but I think using shell here at all is not the right way. For example, what happens when your shell is not zsh but bash.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you provide some key class or method names that can provide a better solution? I may try to make a PR to improve it.
Closing in favor of beec492 |
now WebIDLToSwift can directly run and debug from xcode