find misunderstanding

Hi,

I’m in directory where I found:
pilot_take-up-3_R_conf.xml
pilot_spindle2_R_conf.xml
pilot_ensim_R_conf.xml

when I type:
find . -type f -name ‘pilot*’
I get:
/pilot_take-up-3_R_conf.xml
/pilot_spindle2_R_conf.xml
/pilot_ensim_R_conf.xml

when I type:
find . -type f -name ‘pilot*’ -exec echo ‘{1}’
I get:
/pilot_take-up-3_R_conf.xm
/pilot_spindle2_R_conf.xm
/pilot_ensim_R_conf.xm

Why?

thanks,
Alain.

Alain Bonnefoy wrote:

when I type:
find . -type f -name ‘pilot*’ -exec echo ‘{1}’
I get:
/pilot_take-up-3_R_conf.xm
/pilot_spindle2_R_conf.xm
/pilot_ensim_R_conf.xm

Why?

Behaviour seems to match the online find docs …

There is a QNX Neutrino-only extension to the {} syntax for stripping
leading and trailing characters. You may also opt to insert the filename
stripped of a number of characters at the end (strip) or the filename
less a number of characters at the beginning (skip). The syntax for this
is
{[strip][,skip]}

Thanks for the explanation despite unintentional missing characters in my
post!!

Alain.
John Garvey wrote:

Alain Bonnefoy wrote:
when I type:
find . -type f -name ‘pilot*’ -exec echo ‘’
I get:
/pilot_take-up-3_R_conf.xm
/pilot_spindle2_R_conf.xm
/pilot_ensim_R_conf.xm

Why?

Behaviour seems to match the online find docs …

There is a QNX Neutrino-only extension to the {} syntax for stripping
leading and trailing characters. You may also opt to insert the filename
stripped of a number of characters at the end (strip) or the filename
less a number of characters at the beginning (skip). The syntax for this
is