WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: cliorx: wrong quoting  (Read 1859 times)

Offline yiyus

  • Newbie
  • *
  • Posts: 17
cliorx: wrong quoting
« on: October 25, 2015, 11:03:13 AM »
Arguments are not passed correctly in cliorx. For example, this fails:
Code: [Select]
cliorx sh -c 'cmd1; cmd2 && cmd3'
In this case, "cmd1;", "cmd2", "&" and "cmd3" are passed as different arguments to sh.

The solution is easy. Just use quotes in cliorx:
Code: [Select]
[ "$DISPLAY" ] && /usr/local/bin/xterm -e "$@" || "$@"
Thank you!

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 10957
Re: cliorx: wrong quoting
« Reply #1 on: October 25, 2015, 01:55:09 PM »
Added, thanks!
The only barriers that can stop you are the ones you create yourself.

Offline jls

  • Hero Member
  • *****
  • Posts: 2135
Re: cliorx: wrong quoting
« Reply #2 on: October 25, 2015, 02:32:52 PM »
Hi. There isn't a terminal variable? I think it was discussed in the past without solution.
dCore user

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 10957
Re: cliorx: wrong quoting
« Reply #3 on: October 26, 2015, 01:36:08 AM »
IIRC the xterm is a symlink to your chosen terminal, not actual xterm.
The only barriers that can stop you are the ones you create yourself.