Hi Mikkel,
mikkel meinike wrote on Sun, Nov 02, 2014 at 08:31:08PM +0100:
> Ulrich Lauther wrote:
>> rose=${1%.pnm}
> Thank you ulrich. That is a good tip. Yes bash can do a lot of things
> by it self. I tend to always use the external commands.
Note that in portable software (and for build
> rose=${1%.pnm}
Thank you ulrich. That is a good tip. Yes bash can do a lot of things by
it self. I tend to always use the external commands.
Mikkel
On Sun, Nov 02, 2014 at 11:45:48AM +0100, mikkel meinike wrote:
>
> #Removes the file extension so I only have the base name
>
> rose=`echo "$1" |sed 's/.pnm//'`
>
A simpler way:
rose=${1%.pnm}
Cheers,
ulrich