Re: Command line make results

2011-03-16 Thread Peter Zion

On 2011-03-16, at 10:37 AM, Rich Siegel wrote:

 On Wednesday, March 16, 2011, Peter Zion peter.z...@gmail.com wrote:
 
 Hmm, that seems like an awful lot of work just to run a build and jump to 
 errors.  Thanks anyway!
 
 Have you tried it? It's no more work than doing it in a Terminal, and 
 actually less to navigate errors.

Yes, I tried it.  I guess I'm used to tools such as Xcode which just allow you 
to hit command-B to build then left-click on a line to jump to an error.  This 
is one of the most common things I do in my workflow and it has to be as fast 
as possible.

pz

-- 
You received this message because you are subscribed to the 
BBEdit Talk discussion group on Google Groups.
To post to this group, send email to bbedit@googlegroups.com
To unsubscribe from this group, send email to
bbedit+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/bbedit?hl=en
If you have a feature request or would like to report a problem, 
please email supp...@barebones.com rather than posting to the group.
Follow @bbedit on Twitter: http://www.twitter.com/bbedit


Re: How To Append Text String To EOF Using Global FR

2011-03-16 Thread Rich Siegel
On Thursday, March 17, 2011, Webmaster 
webmas...@endtimeprophecy.net wrote:



Is there some symbol or code that BBEdit recognizes as EOF
that I can use in a global find and replace pattern?


Yes. When using Grep, \z matches at the end of the document. 
\Z matches at the end of the document, *or* if the document 
ends with a blank line, it will match before the last line break.


(Or so says the manual, at any rate - page 169 in the PDF 
available on the Help menu. I haven't tried it.)


Enjoy,

R.
--
Rich Siegel Bare Bones Software, Inc.
sie...@barebones.com  http://www.barebones.com/

Someday I'll look back on all this and laugh... until they 
sedate me.


--
You received this message because you are subscribed to the 
BBEdit Talk discussion group on Google Groups.

To post to this group, send email to bbedit@googlegroups.com
To unsubscribe from this group, send email to
bbedit+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/bbedit?hl=en
If you have a feature request or would like to report a problem, 
please email supp...@barebones.com rather than posting to the group.

Follow @bbedit on Twitter: http://www.twitter.com/bbedit


Re: How To Append Text String To EOF Using Global FR

2011-03-16 Thread Webmaster

Thanks Rich. That was just what I needed.

I'm glad you know your manual, because I would have never
thought to look for a topic called Other Positional
Assertions. I actually looked for end of file and only
found one occurrence, which wasn't related to what I was
looking for.

WW

At 11:14 AM -0400 on 3/16/11, Rich Siegel wrote:


 Yes. When using Grep, \z matches at the end of the
 document. \Z matches at the end of the document, *or* if the
 document ends with a blank line, it will match before the last
 line break.



 (Or so says the manual, at any rate - page 169 in the PDF
 available on the Help menu. I haven't tried it.)



 Enjoy,



 R.


--

EPN Website : http://www.endtimeprophecy.net
EPN Blog: http://www.endtimeprophecy.net/Blog/
EPN RSS Feed: http://www.endtimeprophecy.net/EPN-RSS-Feed.xml
Top Christian Sites : http://www.topchristiansites.org
Armageddon BBS  : http://www.endtimeprophecy.net/ArmageddonBBS/
Facebook: http://www.facebook.com/profile.php?id=11989026091
Tumblr  : http://endtime-prophecy-net.tumblr.com
Twitter : http://twitter.com/WordWeaver777


--
You received this message because you are subscribed to the 
BBEdit Talk discussion group on Google Groups.

To post to this group, send email to bbedit@googlegroups.com
To unsubscribe from this group, send email to
bbedit+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/bbedit?hl=en
If you have a feature request or would like to report a problem, 
please email supp...@barebones.com rather than posting to the group.

Follow @bbedit on Twitter: http://www.twitter.com/bbedit


Re: How To Append Text String To EOF Using Global FR

2011-03-16 Thread Rich Siegel

On Thursday, March 17, 2011, Webmaster webmas...@endtimeprophecy.net
wrote:


I'm glad you know your manual, because I would have never thought to
look for a topic called Other Positional Assertions.


For what it's worth :-) all I did was figure out that Grep would 
be necessary, and that took me straight to Chapter 8.


Glad to hear you're off and running.

R.
--
Rich Siegel Bare Bones Software, Inc.
sie...@barebones.com  http://www.barebones.com/

Someday I'll look back on all this and laugh... until they 
sedate me.


--
You received this message because you are subscribed to the 
BBEdit Talk discussion group on Google Groups.

To post to this group, send email to bbedit@googlegroups.com
To unsubscribe from this group, send email to
bbedit+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/bbedit?hl=en
If you have a feature request or would like to report a problem, 
please email supp...@barebones.com rather than posting to the group.

Follow @bbedit on Twitter: http://www.twitter.com/bbedit


Re: Range operations?

2011-03-16 Thread Simdude
Looks great! Thank you again. I forgot BBedit was recordable.
Definitely one of the nicer, real Mac apps out there. I find I've been
using it for even non-programming work thanks to Hog Bays Quckcursor.
Sort of a Edit in BBedit program that works with any text field.

Mark

On Mar 15, 1:04 pm, Steve Samuels sjsamu...@gmail.com wrote:
 To automate the process somewhat, here's an AppleScript that will
 prompt for the search string. I've provided two versions of the
 search, one that excludes, one that includes the line; just comment
 out the one you want.   You will probably have to remove line breaks
 in the find statement  that are inserted by Google Mail. If you put
 this in BBEdit's Scripts folder, you can assign it a keyboard in the
 Window /Palette/Scripts menu. (By the way, I started writing this
 script by recording a simple search.)

 Steve
 ___
 (* Search up to Line Containing Specified Text
 *)
 tell application BBEdit
         set _searchto to the text returned of (display dialog Enter search
 string default answer )
         set _sstring to (?s).+?(?=((?-s)^.*  _searchto  .*$)) --exclude
 line with search text
         -- set _sstring to (?s).+?((?-s)^.*  _searchto  .*$)  --
 include  the line
         open find window
         find _sstring searching in text 1 of front document options {search
 mode:grep, starting at top:false, wrap around:true, backwards:false,
 case sensitive:false, match words:false, extend selection:false} with
 selecting match
 end tell
 _

 On Mar 14, 2:40 pm, Simdude markmille...@gmail.com wrote:



  Thanks again Steve. Actually, I wanted to perform an operation within
  a selection to mimic what vi can do by specifying a range. i.e. do a
  search and replace but only in a certain range. While it appears you
  can't directly do this in BBedit, your tip will allow me to first
  create a selection region, and then I can operation on that region.

  thanks!

  On Mar 13, 10:39 am, Steve Samuels sjsamu...@gmail.com wrote:

   Mark, your original question was how to select  all text from the
   cursor up to the _line_ that
   contains specified text. Here are solutions.

   Exclude the line from the selection: (?s).+?(?=((?-s)^.*HELLO.*$))
   Include the line in the selection:   (?s).+?((?-s)^.*HELLO.*$)

   These will fail if the current line contains the text.

   Steve

   On Mar 10, 5:39 pm, Steve Samuels sjsamu...@gmail.com wrote:

You are welcome, Mark. To give you a head start, with manual
references:

(?s) extends the search over line endings (p. 188)

.+?HELLO searches text up through the first occurrence of HELLO (non-
greedy matching, p. 177)

(?=HELLO) says to search up to HELLO but not include HELLO in
the found text (positive lookahead, pp. 187,190).

Parentheses around HELLO are a stylistic choice and don't affect
this search, though they might be important in other, more complicated
searches.

Steve

On Mar 10, 2:49 pm, Simdude markmille...@gmail.com wrote:

 Wow. Thanks Steve. I have to give this a try as soon as I get home.
 And I guess it's time to dig into the BBedit docs some more!

 On Mar 10, 2:35 pm, Steve Samuels sjsamu...@gmail.com wrote:

  Searching for  (?s).+?(HELLO) will select all text from the cursor
  up through the first HELLO and (?s).+?(?=HELLO) will select all
  text up to first HELLO.

  Steve

  On Mar 10, 8:35 am, Simdude markmille...@gmail.com wrote:

   Thanks Chris. I did know about the selection operations but when 
   you
   have to do this repeatedly in a file, it's not as efficient. 
   Scripting
   is probably a better option but I'll have to improve my 
   Applescript
   skills to be able to do this faster.

   For any Barebones guys, adding something like to to a future 
   BBedit
   would be a killer feature. With the help of some books, I've used 
   vi
   to rearrange sections of large documents by using commands like 
   this
   to find and move sections.  The problem is while you can do this 
   with
   a single line in vi, it can take 30 minutes to figure out what to 
   type
   in that line!

   Mark

   On Mar 9, 5:26 pm, Christopher Stone 
   listmeis...@thestoneforge.com
   wrote:

On Mar 09, 2011, at 10:28, Simdude wrote: Is there a way in 
BBedit to operate on ranges of data? For example, when I use 
vi, if I want to do a search and replace on all text from my 
current cursor to the line that contains HELLO, I would do 
this:

 :.,/HELLO/ s/this/that/g

 Can BBedit do this sort of range stuff?

__

Hey Mark,

Not directly.  But you can script that kind of search, or you 
can find/replace in the current selection.  So 

Re: Command line make results

2011-03-16 Thread Charlie Garrison

Good morning,

On 16/03/11 at 10:40 AM -0400, Peter Zion peter.z...@gmail.com wrote:

Yes, I tried it.  I guess I'm used to tools such as Xcode which 
just allow you to hit command-B to build then left-click on a 
line to jump to an error.  This is one of the most common 
things I do in my workflow and it has to be as fast as possible.


Assign Cmd-B to an Applescript which brings the worksheet 
forward, selects the make command and runs it. Then when errors 
appear, click line with file name, and do Cmd-L, Cmd-D. Doesn't 
really seem like lots more work to me.



Charlie

--
   Ꮚ Charlie Garrison ♊ garri...@zeta.org.au

O ascii ribbon campaign - stop html mail - www.asciiribbon.org
〠  http://www.ietf.org/rfc/rfc1855.txt

--
You received this message because you are subscribed to the 
BBEdit Talk discussion group on Google Groups.

To post to this group, send email to bbedit@googlegroups.com
To unsubscribe from this group, send email to
bbedit+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/bbedit?hl=en
If you have a feature request or would like to report a problem, 
please email supp...@barebones.com rather than posting to the group.

Follow @bbedit on Twitter: http://www.twitter.com/bbedit


Re: Command line make results

2011-03-16 Thread Doug McNutt
Has anyone offered a script or setting that will open a perl script and go to 
the line specified in an error message when the script is executed from within 
a worksheet?

-- 
--  The best programming tool is a soldering iron --

-- 
You received this message because you are subscribed to the 
BBEdit Talk discussion group on Google Groups.
To post to this group, send email to bbedit@googlegroups.com
To unsubscribe from this group, send email to
bbedit+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/bbedit?hl=en
If you have a feature request or would like to report a problem, 
please email supp...@barebones.com rather than posting to the group.
Follow @bbedit on Twitter: http://www.twitter.com/bbedit


Re: Command line make results

2011-03-16 Thread Charlie Garrison

Good afternoon,

On 16/03/11 at 6:59 PM -0600, Doug McNutt 
dougl...@macnauchtan.com wrote:


Has anyone offered a script or setting that will open a perl 
script and go to the line specified in an error message when 
the script is executed from within a worksheet?


I either don't understand the question or no script is needed. 
Assuming the error message uses the standard format of appending 
the line number; bbedit will already do that. Eg, from the 
command line:


$ bbedit /etc/hosts:7

Or from within an open document, select the file name ( line 
number) and hit cmd-D.


If the error message uses a different format to identify the 
line, then use Perl (or whatever) to munge it into the above 
format and pass to the bbedit tool.



Charlie

--
   Ꮚ Charlie Garrison ♊ garri...@zeta.org.au

O ascii ribbon campaign - stop html mail - www.asciiribbon.org
〠  http://www.ietf.org/rfc/rfc1855.txt

--
You received this message because you are subscribed to the 
BBEdit Talk discussion group on Google Groups.

To post to this group, send email to bbedit@googlegroups.com
To unsubscribe from this group, send email to
bbedit+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/bbedit?hl=en
If you have a feature request or would like to report a problem, 
please email supp...@barebones.com rather than posting to the group.

Follow @bbedit on Twitter: http://www.twitter.com/bbedit