WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: aterm-xterm wrapper script ignores quotes  (Read 2538 times)

Offline Misalf

  • Hero Member
  • *****
  • Posts: 1702
aterm-xterm wrapper script ignores quotes
« on: April 21, 2014, 09:26:40 AM »
/usr/local/bin/aterm-xterm  wrapper script, included in aterm.tcz and issued by the symlink  /usr/local/bin/xterm , doesn't pass quotes to aterm.

Trying to lauch Terminal Server from Control Panel results in aterm not understanding parameters, which include the TITLE option with quotes (-T ""):
Code: [Select]
xterm -bg black +tr +sb -T "Terminal Server Setup" -e sudo /usr/bin/tc-terminal-server &

Code: [Select]
aterm: bad option "Server"
aterm: bad option "Setup"

Usage v1.00.01 ...
Download a copy and keep it handy: Core book ;)

Offline Misalf

  • Hero Member
  • *****
  • Posts: 1702
Re: aterm-xterm wrapper script ignores quotes
« Reply #1 on: May 09, 2014, 01:50:28 PM »
The workaround for me currently is to have a symlink pointing to  /usr/local/bin/aterm  saved as  ~/.local/bin/xterm .

I tryed to modify the wrapper script so that quotes included in parameters would be shipped over to aterm but I failed.
Does anyone have a solution in terms of scripting rather than ignoring the wrapper script by an additional symlink?
Download a copy and keep it handy: Core book ;)

Offline gerald_clark

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 4254
Re: aterm-xterm wrapper script ignores quotes
« Reply #2 on: May 09, 2014, 02:27:22 PM »
Replace "Terminal Server Setup" with Terminal_Server_Setup.

Offline Misalf

  • Hero Member
  • *****
  • Posts: 1702
Re: aterm-xterm wrapper script ignores quotes
« Reply #3 on: May 09, 2014, 02:41:37 PM »
It's hard-coded in  /usr/local/bin/cpanel  which is part of  Xprogs.tcz .

--

I probably should have posted this in TCE Bugs since anything that starts xterm with quoted parameters will lead to aterm to fail launching.
Download a copy and keep it handy: Core book ;)

Offline gerald_clark

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 4254
Re: aterm-xterm wrapper script ignores quotes
« Reply #4 on: May 09, 2014, 03:46:37 PM »
The "xterm" wrapper in aterm.tcz  should be changed to:
--------------------------------------------------------------------------
#!/bin/busybox sh

###########################################
# aterm xterm wrapper for Tiny Core Liux 5.x
# By bmarkus
# v1.0 - October 17, 2013
###########################################

aterm +tr "$@"

Offline bmarkus

  • Administrator
  • Hero Member
  • *****
  • Posts: 7183
    • My Community Forum
Re: aterm-xterm wrapper script ignores quotes
« Reply #5 on: May 09, 2014, 03:58:25 PM »
Thanks, will take a look.
Béla
Ham Radio callsign: HA5DI

"Amateur Radio: The First Technology-Based Social Network."