On Sun, Nov 6, 2022 at 8:48 PM 'Christian Stewart' via golang-nuts < golang-nuts@googlegroups.com> wrote:
> There have been several discussions about shellquote in go-nuts in the > past: > > https://github.com/kballard/go-shellquote > https://github.com/gonuts/go-shellquote > > I've found it necessary to use both Split and Join in some cases when > working with exec.Command. > > This seems like the type of thing that ought to be part of the stdlib, has > there been any consideration towards including it or a similar > implementation? > > This is useful for processing os.Args especially in CLI or emulated shell > environments. > No, IMHO, because such quoting is OS specific. For example, the quoting for UNIX and Windows in this context are different. Furthermore, given the vagaries of the POSIX shell standard I am skeptical that either of the projects you linked to correctly manipulates such strings in every case. It would help if you provided a concrete example of the problem you need help with. -- Kurtis Rader Caretaker of the exceptional canines Junior and Hank -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/golang-nuts/CABx2%3DD_h3OM3AB9jM3%2BwZf5rvRUJOO%3DbHrw-W1-%2B5dEei%2B%2BaJw%40mail.gmail.com.