help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: script for manual translation


From: Quentin Spencer
Subject: Re: script for manual translation
Date: Fri, 15 Jul 2005 15:12:45 -0500
User-agent: Mozilla Thunderbird 1.0.2-6 (X11/20050513)

Jorge Barros de Abreu wrote:

Hi for All.

I make a script called traducao.sh that in shell work fine with:

traducao.sh __bodquist__.pt

Making some changes in ajuda.m:

## Portuguese help function
function ajuda(varargin)
for s = varargin
   nomearquivo = file_in_loadpath([s{1},'.pt']);
   if isempty(nomearquivo), help(s{1});
else system(translation.sh nomearquivo, 1) endif
 endfor

end

The sistem raw do not work. ajuda.m receive a parameter in nomearquivo. How to send this parameter to script shel via system command???

Which the system line correct????

system(translation.sh nomearquivo) system(translation.sh $nomearquivo, 1) system(translation.sh 'nomearquivo')
The system command needs to receive the complete string that is to be passed to the system, so you probably want something like

system(["translation.sh ",nomearqivo]);
or
system(sprintf("translation.sh %s",nomearqivo));

Does that help?

-Quentin



-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:  http://www.octave.org
How to fund new projects:  http://www.octave.org/funding.html
Subscription information:  http://www.octave.org/archive.html
-------------------------------------------------------------



reply via email to

[Prev in Thread] Current Thread [Next in Thread]