Match one part of a regular expression in a Kwrite find-and-replace regex
3
votes
1
answer
5219
views
Among the joys of KDE, Kwrite is surely noteworthy. Having regular expression support built in by default into text editor is probably one of the top 10 best ideas of all time. Since I often need to do a lot of finding and replacing, I have already begun to save a lot of time and hassle by using Kwrite.
I suppose it's probably a lot like in
sed
, but anyway, I am matching stuff like
numbersdonot8
belongattheend0
ofwords2
using the simple regex [a-z][0-9]. How do I then tell kwrite to replace the text using the first part of the regex? Using [a-z] in the 'replace' box gives things like 'numbersdonot[a-z]' as a result. But I want,
numbersdonot
belongattheend
ofwords
Asked by ixtmixilix
(13520 rep)
Dec 29, 2011, 02:08 PM
Last activity: Aug 20, 2018, 11:27 PM
Last activity: Aug 20, 2018, 11:27 PM