Skip to content
This repository was archived by the owner on Jan 27, 2023. It is now read-only.

Commit 09d42b5

Browse files
UI and readme improvements
1 parent 27e4871 commit 09d42b5

4 files changed

Lines changed: 61 additions & 14 deletions

File tree

Default.sublime-commands

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,19 @@
22
{
33
"caption": "Search In Project",
44
"command": "search_in_project"
5+
},
6+
{
7+
"caption": "Preferences: Search in Project Settings – Default",
8+
"command": "open_file", "args":
9+
{
10+
"file": "${packages}/Search in Project/SearchInProject.sublime-settings"
11+
}
12+
},
13+
{
14+
"caption": "Preferences: Search in Project Settings – User",
15+
"command": "open_file", "args":
16+
{
17+
"file": "${packages}/User/SearchInProject.sublime-settings"
18+
}
519
}
620
]

README.md

Lines changed: 24 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2,36 +2,46 @@
22

33
![Search in Project screencast](https://raw.githubusercontent.com/leonid-shevtsov/SearchInProject_SublimeText/screencast/screencast.gif)
44

5-
This plugin for [Sublime Text 2 and 3](http://www.sublimetext.com/) lets you use your favorite search tool (`grep`, `ack`, `ag`, `git grep`, or `findstr`) to find strings aross your entire current Sublime Text project.
5+
This plugin for [Sublime Text 2 and 3](http://www.sublimetext.com/) lets you use your favorite search tool (`grep`, `ack`, `ag`, `pt`, `git grep`, or `findstr`) to find strings aross your entire current Sublime Text project.
66

77
It opens a quick selection panel to browse results, and highlights matches inside files.
88

9-
It's easy to add another search tool, if you so desire.
9+
## Usage
10+
11+
* Use the key binding (`⌘⌥⇧F` on OS X, `Ctrl+Alt+Shift+F` on Windows and Linux), or
12+
* Call the "Search in Project" command;
13+
* Enter the search query;
14+
* Hit `Enter` (`Return`). You'll be presented with a "quick select" panel with the search results. Select any file from that panel (it supports fuzzy searching) to go to the match. The search string will be highlighted with an outline and a circle symbol in the gutter area.
15+
* The last item on the quick select panel is "List results in view". Pick it to see results in a regular editor view. (Tip: if you enter three ticks ("`") in the search box - it's going to be to be the first item.)
16+
17+
If you select text and then run Search In Project, it will pre-fill the search string with the selection text; for example, to search for a word project-wide, do `⌘D, ⌘⌥⇧F, ↩`
18+
19+
If you run Search In Project again, it will remember the last search string, so the next search is just an `` away.
1020

1121
**Important note for Windows users: the current release has known issues with running executables, I'd appreciate any bug reports from the field.**
1222

1323
## Installation
1424

15-
* [Package Control](http://sublime.wbond.net): install package **Search in Project** (this is the recommended method)
25+
[Package Control](http://sublime.wbond.net): install package **Search in Project** (this is the recommended method)
1626

17-
* Download an [archive of the repository](https://github.com/leonid-shevtsov/SearchInProject_SublimeText/archive/master.zip), and unzip into the Sublime Text Packages folder.
27+
Manual installation: download an [archive of the repository](https://github.com/leonid-shevtsov/SearchInProject_SublimeText/archive/master.zip), and unzip into the Sublime Text Packages folder.
1828

1929
### Installing search engines
2030

2131
My idea is that if you use this plugin it's because you already use one of the superior search engines like [The Silver Searcher](https://github.com/ggreer/the_silver_searcher) and want to use it from within Sublime Text.
2232

23-
## Usage
33+
The supported search engines are:
2434

25-
* Use the key binding (`⌘⌥⇧F` on OS X, `Ctrl+Alt+Shift+F` on Windows), or
26-
* Call the "Search in Project" command;
27-
* Enter the search query;
28-
* Hit `Enter` (`Return`). You'll be presented with a "quick select" panel with the search results. Select any file from that panel (it supports fuzzy searching) to go to the match. The search string will be highlighted with an outline and a circle symbol in the gutter area.
29-
* The last item on the quick select panel is "List results in view". Pick it to see results in a regular editor view. (Tip: if you enter three ticks ("`") in the search box - it's going to be to be the first item.)
35+
| Name | Description | Search in Project key
36+
| - | - | - |
37+
**[pt (The Platinum Searcher)](https://github.com/monochromegane/the_platinum_searcher)** | **fast, has binaries for every platform, recommended.** | `the_platinum_searcher`
38+
**[ag (The Silver Searcher)](http://geoff.greer.fm/ag/)** | **equally fast, only 3rd party binaries for Windows, also recommended** | `the_silver_searcher`
39+
[ack](http://beyondgrep.com/) | not as fast as `pt` and `ag`, but still pretty good. Depends on perl, thus not so easy to install on Windows. | `ack`
40+
[git grep](http://git-scm.com/docs/git-grep) | packaged with Git and really fast, but only works in Git repositories. Recommended if you use Windows and Git and really don't want to install anything else. | `git_grep`
41+
[grep](https://en.wikipedia.org/wiki/Grep) | fallback search tool available on Linux and OSX systems. Not recommended - just use the built-in Sublime Text search instead. | `grep`
42+
[findstr](https://technet.microsoft.com/en-us/library/Bb490907.aspx) | fallback search tool available on Windows. Not recommended - just use the built-in Sublime Text search instead. | `find_str`
3043

31-
32-
If you select text and then run Search In Project, it will pre-fill the search string with the selection text; for example, to search for a word project-wide, do `⌘D, ⌘⌥⇧F, ↩`
33-
34-
If you run Search In Project again, it will remember the last search string, so the next search is just an `` away.
44+
**You need to choose the engine you want to use in the configuration file. The default is the one available on every system, but easily the worst.**
3545

3646
## Configuration
3747

install.txt

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
Thanks for installing Search in Project!
2+
----------------------------------------
3+
4+
Please make sure you open the configuration file ( `Preferences - Search in Project Settings - User` in the Command Palette) and configure the engine you want to use:
5+
6+
{
7+
"search_in_project_engine": "<your_search_engine>"
8+
}
9+
10+
where <your_search_engine> is one of:
11+
12+
the_platinum_searcher, the_silver_searcher, ack, grep, git_grep, grep, or find_str
13+
14+
depending on your preference.
15+
16+
* * *
17+
18+
You can find detailed instructions in the readme at
19+
20+
https://github.com/leonid-shevtsov/SearchInProject_SublimeText#search-in-project

messages.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"install": "install.txt"
3+
}

0 commit comments

Comments
 (0)