[MacPorts] #28434: watch fails with spaces in file name or directory path
MacPorts
noreply at macports.org
Wed Feb 16 11:10:24 PST 2011
#28434: watch fails with spaces in file name or directory path
------------------------------+---------------------------------------------
Reporter: ac1115@… | Owner: mjhsieh@…
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version: 1.9.2
Keywords: | Port: watch
------------------------------+---------------------------------------------
Comment(by mjhsieh@…):
As far as I know, this behavior is consistent with watch(1) in Linux. The
rationale behind this was that you only escape the space once, so the
command line (now unescaped) managed to be stored in the string of 'watch'
buffer, but what 'watch' then did was to run the command with the
unescaped filename. That unfortunately fails.
Nonetheless, it can be escaped by adding extra double quotation:
{{{
watch "tail ~/Library/Logs/iPad\ Updater\ Logs/iPadUpdater\ 1.log"
}}}
If you guys don't mind, I'll ask the admin to close the ticket.
Replying to [ticket:28434 ac1115@…]:
> the "watch" command fails if there is a space anywhere in the file name
or directory path. Putting the file name in quotation marks still fails.
> for example, this line will fail.
> {{{
> watch tail ~/Library/Logs/iPhone\ Updater\ Logs\iPhoneUpdater\ 1.log
> }}}
>
> error is
> {{{
> /Users/username/Library/Logs/iPhone: No such file or directory.
> }}}
--
Ticket URL: <https://trac.macports.org/ticket/28434#comment:3>
MacPorts <http://www.macports.org/>
Ports system for Mac OS
More information about the macports-tickets
mailing list