Project file list support for the grepview part
Kris Wong
wongk at seapine.com
Thu Oct 19 14:20:28 UTC 2006
Hi,
One of the first things I noticed when I started using kdevelop was that
the grep feature did not support only searching the files that are in a
project. This was a big weakness for me due to our project structure,
so I added the feature. By this point I have grown tired of readding
the feature everytime I upgrade, so I figured I'd submit it to the list
and see what people thought. I realize this isn't exactly the best
timing, due to feature freeze on Monday, but I figured I'd give it a
shot. I'm new to this whole thing, so I hope this is the appropriate
process.
Here's a quick overview of the feature: A checkbox has been added to the
grep dialog that allows the user to specify that they would only like to
search the files in a project. This checkbox is enabled/disabled based
on whether a project is open and has at least 1 file in its file list.
If the user selects this option, when the grepviewwidget actually does
its search, it will dump all of the files in the file list to a
temporary file named ".grep.tmp" in the project directory, which it will
then cat and pipe to xargs. Otherwise it will behave as normal. When
the search is done or is killed, the temporary file is removed. I first
tried an impelementation that did not use a temporary file using echo,
but the command line became too long for large projects. I have tested
this using several qmake projects, an automake project
(kdevelop.kdevelop), and a simple manual makefile type project. It
worked as expected in all 3 tests. I have also been using this feature
on a daily basis for quite some time.
The attached patch was created from the kdevelop 3.4 branch as of about
an hour ago.
Kris Wong
Seapine Software, Inc.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20061019/e9f84812/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: grepview_with_project_support.patch
Type: application/octet-stream
Size: 11832 bytes
Desc: grepview_with_project_support.patch
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20061019/e9f84812/attachment.obj>
More information about the KDevelop-devel
mailing list