Visual Studio Code plugin that displays a Quick Pick input with capabilities similar to Sublime Text 3 Go To Anything functions.
After installation use the default Cmd+P/Ctrl+P
keyboard shortcut or Go To Anything
command to open the extension
Something missing? Found a bug? - Create a pull request or an issue. Github
Type anything to find files in the current workspace. Select the desired file and type @
to load all functions in that file. If preview is enabled you will see the selected function in the editor. Press enter to open the file or press cancel to return to the previous editor.
If you type directly @
it will load all functions in the currently opened file
Type anything to find files in the current workspace. Select the desired file and type :
and the line number to jump to the corresponding line
Type anything to find files in the current workspace. Select the desired file and type $
to load symbol declarations (constants, variables, interfaces, classes, etc) in that file. If preview is enabled you will see the selected declartion in the editor. Press enter to open the file or press cancel to return to the previous editor.
If you type $
directly it will load all declarations in the currently opened file
To display symbols properly this extension relies on the existing VSCode symbol detection that depends on the installed Language settings and packages. If symbol is not available as expected check if it's available in the native VSCode Go To Symbol in File.
The default shortcut is Cmd+P
for Mac (Ctrl+P
for Windows). To change it search for Go To Anything
in the keyboard shortcut settings or add
{
"extension.GoToAnything": "keyboard shortcut"
}
to your keybindings.json
file
This extension utilizes the following workspace settings:
-
workbench.editor.enablePreview
enables or disables the file preview functionality when changing the selected item -
files.exclude
andsearch.exclude
are used as exclude patterns for the file search -
search.useIgnoreFiles
is used to respect and exclude patterns from.gitignore
and.ignore
-
GoToAnything.prefix.Functions
Prefix to invoke search by function name. Empty string to disable. The default is@
-
GoToAnything.prefix.Declarations
Prefix to invoke search for declarations. Empty string to disable. The default is#
-
GoToAnything.prefix.Commands
Prefix to invoke a command search (active only on first char). Empty string to disable. The default is>
-
GoToAnything.prefix.Symbols
Prefix to invoke search for all symbols in workspace (active only on first char). Empty string to disable. The default is#
-
GoToAnything.prefix.Recent
Prefix to invoke the vscode go to file search (active only on first char, no functions or declarations search). Empty string to disable. The default is*
-
GoToAnything.symbols.Functions
List of symbol types to include in the Functions search. The efault is:[5, 8, 11]
. For options visit: https://github.com/Cmacu/gotoanything/blob/master/src/symbolIcons.ts -
GoToAnything.symbols.Declarations
List of symbol types to include in the Declarations search. The default is:[4, 6, 7, 9, 10, 12, 13]
. For options visit: https://github.com/Cmacu/gotoanything/blob/master/src/symbolIcons.ts -
gotoanything.previewDelay
: The delay in miliseconds for displaying the selected dropdown item (only if preview is enabled)
Pasting in the search box may not behave as expected since the extension rellies on selecting the file before filtering for symbols in file
Bug fixes Added prefix and symbol customizations
Return to original editor on cancel fix
Various bug fixes and speed improvements
Publised on VSCode Marketplace
Initial release
- Enable prefix customizations
- Add tooltips when no results are found
This software is released under MIT License
Enjoy!