Is there a way to tell Visual Studio to only show the file name in the search results instead of the full path? By default it shows the full file path followed by the actual line.
If it did, I could make the results window take less space on the screen and wouldn't have to bother with scrolling to see the actual line (yes, the full paths are quite long).
Yes, it's possible, although involves registry hack:
HKCU\Software\Microsoft\VisualStudio\10.0\Find
Find result format
with value $f$e($l,$c):$t\r\n
Here are the values you can use in the string:
Files
$p
path $f
filename $v
drive/unc share $d
dir $n
name $e
.ext Location
$l
line $c
col $x
end col if on first line, else end of first line$L
span end line$C
span end colText
$0
matched text $t
text of first line$s
summary of hit$T
text of spanned linesChar
\n
newline \s
space \t
tab \\
slash \$
$ If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With