On Tuesday, 8 August 2017 17.24.30 WEST Dr Eberhard Lisse wrote:
> José
> 
> thank you, but it lyx2lyx does not do what I need.
> 
>       lyx2lyx file.lyx -o file.lyx
> 
> clobbers file.lyx
> 
> Something like
> 
>       PID=$$
>       cp file.lyx file.$PID.lyx
>       lyx2lyx file.$PID.lyx file.lyx
> 
> doesn't fit on the command line so needs refinement as a bash script to
> take arguments and do further error checking...
> 
> not what would call 'one the command line'
> 
> 
> el

Using bash in one line we have (backup file.lyx -> file.old.lyx):

for lfile in $(find . -name '*lyx' -print); do ofile=${lfile%%.lyx}.old.lyx; 
lyx2lyx < $ofile -o $lfile; 
done

:-)
-- 
José Abílio

Reply via email to