MATLAB Answers

Possible to open file by text, go to file, quick open, quick search

15 views (last 30 days)
Chris Anderson
Chris Anderson on 2 Nov 2016
Answered: Josh Philipson on 19 May 2020
Visual Studio Code, Atom, BBEdit all have the ability to type a keyboard shortcut that opens a "quick file search" text field. You type the first few letters of the file name like "myT" and it shows you all files in the file browser that begin with "myT" and lets you quickly select one. Does the MATLAB IDE have similar functionality?
You can think of the functionality as similar to the "Help Search" where you type in the name of a function and it lists suggestions you can quickly open in Help. I want this but with all of the filenames of my working directory indexed to quickly open a particular file. Clicking through the tree is terrible.

  0 Comments

Sign in to comment.

Answers (2)

Nick Counts
Nick Counts on 5 Nov 2016
Edited: Nick Counts on 5 Nov 2016
Chris,
I am not 100% sure I know the behavior you are after, but I might have something for you that comes close. It is the 'Find Files' tool. While it doesn't update results instantly, it does let you do some pretty powerful file searching across the entire Matlab path (or any other set of folders).
It's especially useful for finding code that depends on one of your functions.
Also, if you have a script or function that is on the path, you can start typing the name in the command window and use tab complete. You can do the same thing with open (this doesn't always work).
I believe open grabs whichever file which returns, so if you have overloaded file/function names, it doesn't work as well.
Hopefully there's something useful in there
<<
>>

  0 Comments

Sign in to comment.


Josh Philipson
Josh Philipson on 19 May 2020
I believe the idea here is that you have an array of files open in your editor - and you know the name (or part of the name) of the file that you want to jump to - and you want a pop-up that will allow you to search and jump to that file.
That'd qualify as a quick-jump file-edit, IMO. Sort of like PyCharm's quick-jump capabilities (which are enviable, to be sure!)

  0 Comments

Sign in to comment.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!