Re: Ledger syntax coloring

2019-12-19 Thread Rich Siegel
On 12/19/19 at 10:31 PM, nicovhaastre...@gmail.com (Nico van Haastrecht) wrote: I found a ledger language module at https://github.com/ledger/ledger/wiki/Editing-Ledger-files-with- TextWrangler and I installed it in the Bbedit language modules folder but it does not work, it is not recognised.

Ledger syntax coloring

2019-12-19 Thread Nico van Haastrecht
I found a ledger language module at https://github.com/ledger/ledger/wiki/Editing-Ledger-files-with-TextWrangler and I installed it in the Bbedit language modules folder but it does not work, it is not recognised. Can anybody give me a hand in how to make this working? Thanks, Nico van

Re: Use GREP to select all characters up to a character

2019-12-19 Thread Howard Rosenberg
Massimo, Thanks for the response. When I used ^(.*)(\\) it also selected the backslash. Before: Max Stassi\stassma01 After: Max Stassi\ Howard On Dec 19, 2019, 4:03 PM -0500, bbedit@googlegroups.com, wrote: > > ^(.*)(\\) -- This is the BBEdit Talk public discussion group. If you have a

Re: Use GREP to select all characters up to a character

2019-12-19 Thread Massimo Rainato
I hope this help ^(.*)(\\) as you know select upto backslash \0 is entire select > Jose Rondon\ \1 is first subset > Jose Rondon Greetins from Italy EU > Il giorno 19 dic 2019, alle ore 20:59, Howard > ha scritto: > > This is the opposite question to

Re: GREP question

2019-12-19 Thread Howard Rosenberg
Thanks. On Dec 19, 2019, 1:53 PM -0500, Fletcher Sandbeck , wrote: > You can think of the pattern as a state machine. It scans forward in the > input until the first match in the pattern. In this case the first match is > the first "a" in the input so that's where the match starts. The rest of

Use GREP to select all characters up to a character

2019-12-19 Thread Howard
This is the opposite question to one I asked previously. Given rows of data with the format below, *Jose Rondon\rondojo02* how can I configure GREP to select all the characters up to but not including the backslash? Howard -- This is the BBEdit Talk public discussion group. If you have a

Re: GREP question

2019-12-19 Thread Sam Hathaway
What Fletcher said. :-) On 19 Dec 2019, at 13:53, Fletcher Sandbeck wrote: You can think of the pattern as a state machine. It scans forward in the input until the first match in the pattern. In this case the first match is the first "a" in the input so that's where the match starts. The

Re: GREP question

2019-12-19 Thread Fletcher Sandbeck
You can think of the pattern as a state machine. It scans forward in the input until the first match in the pattern. In this case the first match is the first "a" in the input so that's where the match starts. The rest of the pattern tells it how far to extend the match, through the next "b".

Re: GREP question

2019-12-19 Thread Howard Rosenberg
Sam, Why does the pattern .*?b only match aaab and not aab? Isn’t aab the shortest string possible? Howard On Dec 19, 2019, 1:17 PM -0500, bbedit@googlegroups.com, wrote: > > The pattern .*b will match aaabaab, while the pattern .*?b will match aaab. -- This is the BBEdit Talk public

Re: GREP question

2019-12-19 Thread Sam Hathaway
Putting a `?` after a quantifier like `*` or `+` indicates that you want it to be _lazy_ instead of _greedy_. In short, this means that the quantifier will match the shortest string possible rather than the longest string possible. For example, take the text `aaabaaba`. The pattern `.*b` will

Re: GREP question

2019-12-19 Thread Fletcher Sandbeck
The question mark after the + makes it non-greedy so it won't match the character immediately following. However, in this case you're matching until the end of the line so I don't think it does anything. Compare these two patterns matched against the input. The ? after the + prevents the match

GREP question

2019-12-19 Thread Howard
I am new both to BBEdit and to GREP and have a question about this GREP code: \\.+?$ It is used in Search's Find box to remove all text from the backslash on, and is accompanied by no value in the Replace box. *Sample Input* Tyler Rogers\rogerty01 *Desired Output* Tyler Rogers I understand

Javascript Syntax Coloring

2019-12-19 Thread John Masone
Is there a way I can "trick" BBEdit into using the PHP color palette for Javascript? I know I can change the code type manually at the bottom of the page, but I'd like to have BBEdit always use it's PHP coloring on what it thinks is javascript code. The PHP coloring is much more useful than