You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm checking out some different Atom shells. I notice that the shell parsing is fairly primitive in this project, e.g., echo "$PATH" doesn't expand $PATH.
I happen to have written a shell parser a while back, and maybe it would be useful. Coincidentally also written in CoffeeScript.
The code is a little old and not commented, but it might be helpful. window.parse(string) returns a Node object, and node.toArgs(onDone, homedirResolver, varResolver, interpolateResolver, wildcardResolver) resolves the command into strings. E.g., you'd do:
Thank you! I will definately look into it. Parsing has been one of the great challenges of this project and I'm definately open to out-sourcing that particular aspect.
I'm checking out some different Atom shells. I notice that the shell parsing is fairly primitive in this project, e.g.,
echo "$PATH"
doesn't expand $PATH.I happen to have written a shell parser a while back, and maybe it would be useful. Coincidentally also written in CoffeeScript.
The code is a little old and not commented, but it might be helpful.
window.parse(string)
returns a Node object, andnode.toArgs(onDone, homedirResolver, varResolver, interpolateResolver, wildcardResolver)
resolves the command into strings. E.g., you'd do:(Note it doesn't consistently use Node-style callbacks)
Anyway, this code might be useful in your project.
The text was updated successfully, but these errors were encountered: