Also known as regular expression or regexp, a description of a set of strings, often used for searching and validating strings.

learn more… | top users | synonyms (1)

1
vote
2answers
255 views

Use Sublime Text find to highlight a regex group in search pattern

Is there a way to make Sublime Text highlight (match) only part of a regex search pattern? For example, I want to exclusively highlight Text when searching for Some(Text).
0
votes
0answers
39 views

Outlook Query to highlight messages that mention me?

In essence, I want to do some conditional formatting on messages that mention me. Below are 3 sample Messages (Bodies). The first two should be purple, the last one should not be purple because I ...
0
votes
1answer
95 views

Printing matching subgroups in a perl one liner

I have the regex[1] (/foo/bar/(GW|GREV)[^/]*).* I was able to get this to work with GNU sed with sed -n 's/\(\/foo\/bar\/\(GW\|GREV\)[^\/]*\).*/\1/p' But that was a modern GNU sed and I'm on ...
1
vote
1answer
703 views

Replace variable in string with Regex in Notepad++

I'm new to Regex and Notepad++ need to remove variables from code. For example, remove everything between the double quotes in lines like this: alt=""Frontline Plus for Dogs and Cats"" To leave me ...
1
vote
1answer
111 views

How to find the missing number in a sequence

I have a Holy Bible file which starts every line with a verse number (e.g. 1, 2, 3, 4) and so on. But on certain chapters some verses are skipped or are not present, for example 10, 11, 12, 14, etc. ...
0
votes
0answers
39 views

insert text and numbers in notepad++

I have this: ...something...data-src="TEXT"...something...src="images/BBP/BBP0001/01SMALL.jpg"...something... ...something...data-src="TEXT"...something...src="images/BBP/BBP0001/02SMALL.jpg"......
0
votes
1answer
100 views

Transform a CSV with Notepad++

Suppose I have a CSV file like this: 1,"abc",,,, 2,"def",,,"ghi", 3,,"jkl",,,"mno" Now I need to transform it in 3 steps: Replace all empty spaces with the String NULL Add at the beginning of ...
0
votes
0answers
39 views

Find and Replace in .txt file by extracting data from spreadsheet

I need to replace instances like Manhole Name="1" with Manhole Name="SW3/001" for instance by extracting the data from spreadsheet. Would that be possible using regex, or in any possible way ? ...
3
votes
2answers
405 views

Find and replace multiple times in txt file

I know this might have been asked before, but I could not find an answer to it. I need to replace the following: CoverLevel="XX" with CoverLevel="0" , this includes XX being any number, without ...
3
votes
2answers
95 views

Word 2010 wildcard search - Find text in format ABC.DEF.XYZ

I am trying to find text in Word 2010 in the following format: ABC.DEF.XYZ. This is essentially finding code references, using Java syntax, written into the word document. Please note that a 3-...
0
votes
0answers
67 views

Regular Expression to match a dot followed by a space inside a tag

I must be missing something quite obvious, but I need to match every dot followed by a space ". " inside these tags: <example:label xml:lang="en">One. Two. Three. Four</example:label> <...
0
votes
1answer
71 views

What is the regular expression in Notepad++ which matches 1 to 8 character words?

I have a very big text file. Every line in this textfile has a one word in it. How do I search for words which are 1 to 8 characters long? [A-Za-z]{1,7} doesn't work.
1
vote
2answers
543 views

Match multi-line pattern in Charles proxy rewrite rule

In Charles proxy, I'm trying to use a rewrite rule to match a pattern that spans three lines in a response body, using \s* in the Match value (with 'Regex' checked) to match new lines. It appears ...
2
votes
1answer
351 views

unknown exception error when I run Notepad++ v6.8.2 when starting Regex Helper

I get an unknown exception error in Notepad++ v6.8.2 when starting Regex Helper? Any suggestions? OS: Win7 64-bit Installed with installer package
0
votes
2answers
69 views

awk and regex with {}

I want to print whole record if it contain word and some character, which are optional. Script: /mount[ein]{0,2}/{ print $0} Unfortunately it doesn't work. Without "{" and "}" it work. I tried with ...
0
votes
1answer
19 views

Remove all lines after /

I have 2 lists one with this format: http://www.example.com/archives/573 http://www.example.com/1812.html http://example.com/hello-world/ but i want it in this format www.example.com www.example....
0
votes
0answers
39 views

mutt regex for limit filters

Does mutt support multi-line regex for its search filters? I cannot find an yes or no in the documentation. I'm assuming its not supported, but cannot tell if maybe I am improperly escaping my regex. ...
1
vote
1answer
19 views

Vim: Columising a long line of arrays

In writing tests I often want to compare a generated value to something I've previously generated, but dumping the output from my console into vim leads to a very long ugly line. Is there any way to ...
1
vote
1answer
28 views

How to remove pattern containing blank space and special characters in sed

How to remove following words from a text file: DEFAULT ('') DEFAULT ((0)) DEFAULT (((1)/(1))/(1900)) DEFAULT (getdate()) I am not able to delete above four pattens using sed.
0
votes
1answer
46 views

VLOOKUP returning N/A because references contain “.” and “ ” in one table, not in other

OK I am trying to vlookup a table but the problem is the references on one table are slightly different to the references on the other table. I can get the VLOOKUP function working, but it is ...
1
vote
1answer
25 views

Replace a line with a specified pattern

As shown in the example, the number 1 appears in the same column in every line, and in my file, there are 6000 lines like that in total. 1. 1 2. 1 3. 1 4. 1 5. 1 6. 1 7. 1 8. 1 9. 1 I want to ...
1
vote
1answer
87 views

Notepad++ find and replace string or text with new string or text

I have some code several hundred lines long and I want to find each "String" and replace it with a different "String". Example below... $BR360Button.Add_Click({BR360Button}) $BR368Button.Add_Click({...
0
votes
1answer
36 views

How to remove lines not ending in a number?

How do I null or better yet, remove, the lines in a file that do not end in a number [0-9]? I'm using gvim blahblahblah delete this line foobarbizzbuzz keep this line because it ends in 9999113 I'...
-1
votes
1answer
120 views

replace/rename directory name using regex

i have multiple folder with this pattern "720p.MP4-ABC[abcde]" trying to replace or rename "720p.MP4-CAB[aedcb]" to "."
1
vote
0answers
54 views

MS Word, can we write a multilingual regular expression?

I want to find all the occurrences of the from x.y and change it to x,y where x and y are numbers: I was using this: ([0-9]).([0-9) and doing the replace using \1,\2 but here is the catch , if the ...
0
votes
0answers
45 views

HTTPD 2.2.15 AliasMatch

I have built a regex for an AliasMatch that tests out fine against the PCRE tester at regex101.com. The task I am trying to accomplish it to allow any alias matching a pattern to refer to a common ...
0
votes
1answer
22 views

Quotes in sed when used in bash script

I am generating sed expression in Bash script, and I am having a following problem. I want to add a space in front of each appearance of abc. This commands works as expected echo abc | sed -e "s/...
3
votes
2answers
3k views

Replace every nth instance of a character with a new line in Notepad++

I have a pipe delimited string of NAME|VALUE pairs looking something like this.. Name1|Value1|Name2|Value2|Name3|Value3 What I want to do is to replace every second instance of | with a new line so ...
1
vote
0answers
106 views

Search & replace speed in Notepad++ / indexing

I am using Notepad++ to search and replace in around 60, 000 files, one folder. It only seems to be processing around 2 files per second, is there any way to speed this up? I have an i7 processor ...
0
votes
1answer
38 views

Excel search character range

Is it possible to use character classes ([A-C] or [abc]) instead of wildcards in the SEARCH function of excel? I want to do something like the following: =SEARCH("[AB]"; A1) This should result in ...
2
votes
1answer
106 views

Notepad++ regex find/replace adjacent ids

I have a csv file that looks like this: ID, term, functional category GO:0008166,viral replication,P, GO:0008167,sigma virus replication,P, GO:0008168,GO:0004480,methyltransferase activity,F, GO:...
0
votes
0answers
107 views

How expand NSDataDetector's NSTextCheckingType and corresponding pattern?

I want detect some condition more than NSDataDetector's internal types, so need know whether IOS system already provide a interface for expand NSTextCheckingResult. apple document just say: the ...
0
votes
1answer
204 views

regex to match everything but substrings beginning with hashkey

I am building a regex to filter out any substrings beginning with '#' or '@'. I am trying to filter tweets from those. Currently it matches everything no matter if the string contains words beginning ...
2
votes
2answers
45 views

Delete everything in second column not in parentheses

I have a file that looks like this: gene ID protein Solyc06g062540 (Z) PYROPHOSPHATASE 3 (PTHR20889:SF0) Solyc10g075050 ALBUMIN SUPERFAMILY (PTHR33076:SF11) Solyc07g061760 ...
1
vote
1answer
121 views

Abobe Brackets how to find in a folder

In the official web: https://github.com/adobe/brackets/wiki/How-to-Use-Brackets Under the title: 'Instant Find in Files' they say: "You could even make the search in a specific folder" Can anyone ...
2
votes
0answers
64 views

Regex expression cuts zero in the end

I have a script with powershell regex in it, and after I upgraded from Windows 7 to 10 it working different. Regex: if ($srv -match '^[0-9]{1,3}\.[0-9]{1,3}$'){$srv = "192.168.$srv"} Expected: ...
0
votes
1answer
174 views

Regular expression for find in files in Textpad

I want to use regular expression for find in files in TextPad. I need to find URLs starting with "Areas/" and ending with "/pdf"(something like this Areas/../../...pdf). Please suggest me the correct ...
1
vote
2answers
62 views

Notepad++ Regular Expression Assistance

I am currently trying to find \000\000\001\031704_news_release.pdf Which I have successfully done with 000\\000\\\d\d\d\\ I am pretty sure I am doing something wrong here though because I want ...
0
votes
0answers
27 views

FatRat - How to add FTP credentials?

I am wondering, how to add FTP credentials to FatRat? You have to insert an regular expression, but how exactly does it have to look like? Anyone has an example of an regular expression? For example ...
1
vote
1answer
174 views

Remove everything before the colon character (regex) in ms word

I need a regex to remove everything before the : character. An example would be: UNIDENTIFIED MALE #1: Thank you. Roll camera. Do you have numbers moving out at the sound? UNIDENTIFIED MALE #...
1
vote
1answer
49 views

Regex Expression in Notepad ++ (Replacing value)

I'm trying to replace a statement that has this pattern: readonly="if(xxxx.x_DATE lt yyyy.y_yyyyy,True,False)" where "DATE" in the statement are dynamic (vary in the file, i.e. 0101, 0102, 0103 etc) ...
0
votes
1answer
52 views

How to exclude certain paths in Hudson using regular expression

We use Hudson and like to exclude certain paths from the code checkout source using regular expression. Paths to exclude: src/abc/def/efg/z.h src/abc/def/m.h src/abc/def/efg/kvt/y.h We tried but ...
0
votes
2answers
279 views

Notepad++ comment all lines containing string or all bookmarked lines

I wanted to comment out some java code using Notepad++ e.g. StringBuffer sbTest = new StringBuffer(); sbTest.append("aaa"); sbTest.append("bbb"); sbTest.append("ccc"); sbTest.append("aaa"); sbTest....
1
vote
2answers
154 views

Regular expression to match cell boundaries

Is there a regular expression solution in Microsoft Word to match cell boundaries? Recently I had a table with several cells starting with a space and I had to remove them, unfortunately ^ to match ...
0
votes
1answer
27 views

how to delete the line after a special number?

How I can delete the numbers and characters more than a special number by regex in notepad++? This is a part of text: 1230 مهندسی برق-تبریز 126 مهندسی کامپیوتر-شریف 234 مهندسی کامپیوتر-تهران 786 ...
0
votes
1answer
174 views

Delete all code inside a tag in multiple HTML files with Notepad++

I need to delete all code contained within <li class="share"> ... </li> including the <li> tags themselves. There are multiple other <li> tags inside the li class="share" ...
0
votes
2answers
46 views

Find files to find multiple instances of the same code with Notepad++

I might have inserted <meta charset="UTF-8"> twice in some HTML files, and there are too many of them to check manually. Is there a regular expression I can use with Notepad++ to search for ...
0
votes
1answer
80 views

Regex for “Delete everything going forward but only up until start of [Expression]” [duplicate]

I am in Notepad++. I have the following data embedded in a large html file. I want to get the variables before the </ix:nonNumeric> at the end of the lines, onto their own lines by themselves so ...
0
votes
1answer
62 views

expr bash command returning 0 in substring evaluation

What I'm trying to do is read a line from a file, store it in a variable $line and extract all instances of (that is, angle brackets with only uppercase letters between them). What I'm trying is: ...
1
vote
0answers
152 views

Sublime Text: Why regex in syntax highlighting does not work?

In Sublime Text 3, a default syntax highlighting rule paints a SQL SELECT just fine if it's in the same line, but not if it's in the next line: vs After reading this question I opened the PHP ...