Re: Trim space chars from start of line
Re: Trim space chars from start of line
- Subject: Re: Trim space chars from start of line
- From: Doug McNutt <email@hidden>
- Date: Thu, 28 Jul 2011 11:43:44 -0600
At 10:35 -0700 7/28/11, Zavatone, Alex wrote:
>
>You sir, are a benefit to humanity.
>
>Now, how can I find out why that does what that does?
>
>On Jul 25, 2011, at 2:20 PM, Christopher Stone wrote:
>
>>on trimLeadingWhiteSpace(str)
>> set cmd to "sed -nE 's/^[ ]*//p'<<<" & quoted form of str
>> do shell script cmd
>> return result
>>end trimLeadingWhiteSpace
>>
In Terminal.app use
man sed
Or on the WWW search for +sed +manual
sed stands for stream edit. It has been around for longer than any Macintosh.
--
1801 - Joseph Marie Jacquard uses punch cards to instruct a loom to weave "hello, world" into a tapestry.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden