Search Results
Search type | Search syntax |
---|---|
Tags | [tag] |
Exact | "words here" |
Author |
user:1234 user:me (yours) |
Score |
score:3 (3+) score:0 (none) |
Answers |
answers:3 (3+) answers:0 (none) isaccepted:yes hasaccepted:no inquestion:1234 |
Views | views:250 |
Code | code:"if (foo != bar)" |
Sections |
title:apples body:"apples oranges" |
URL | url:"*.example.com" |
Saves | in:saves |
Status |
closed:yes duplicate:no migrated:no wiki:no |
Types |
is:question is:answer |
Exclude |
-[tag] -apples |
For more details on advanced search visit our help page |
is for patterns specifying search or replace strings. Also known as `regex` or `regexp`, the patterns describe strings to match when searching or replacing. Emacs provides extensive support for `regex` patterns in many commands. Emacs also provides an interactive expression builder for such patterns.
4
votes
Accepted
Regex: Only match base.extension filenames
You could use M-x re-builder to construct your regexp visually.
To match the stuff described in your question, you just have to add ^ at the beginning of your regex. Then it starts at the beginning …
1
vote
Finding Numbers in Brackets and Summing Them
Here is the function you wished for.
I put some extra variables inside this function, so it is easier for you to enhance it.
(defun sum-the-brackets (begin end)
"sums up values in brackets with s …
1
vote
Accepted
Counting number of matches in number of lines for regex search
I took your code as base and rewrote it somewhat.
The following function is one possible solution to solve that problem in one function:
(defun my-search-results (pattern)
(interactive (list (read- …
9
votes
Accepted
Emacs replace-regexp reference the match in the replace argument
replace-regexp is perfect for the job. You could also use query-replace-regexp, which is more visual.
You want to replace XYZ\(...\) with 'XYZ\1'.
Explanation:
. stands for a single character, you co …
0
votes
How can I paste a defvar into the minibuffer?
Define an interactive function (aka command), which inserts this string. Then put this function on a key binding.
(defun my-insert-regex ()
(interactive)
(insert (format "%S" markdown-link-to-org- …