{"action":"created","issue":{"url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/issues/69","labels_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/issues/69/labels{/name}","comments_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/issues/69/comments","events_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/issues/69/events","html_url":"https://github.com/ctrlpvim/ctrlp.vim/issues/69","id":54161792,"number":69,"title":"Giving preferences to exact match","user":{"login":"edi9999","id":2071336,"avatar_url":"https://avatars.githubusercontent.com/u/2071336?v=3","gravatar_id":"","url":"https://api.github.com/users/edi9999","html_url":"https://github.com/edi9999","followers_url":"https://api.github.com/users/edi9999/followers","following_url":"https://api.github.com/users/edi9999/following{/other_user}","gists_url":"https://api.github.com/users/edi9999/gists{/gist_id}","starred_url":"https://api.github.com/users/edi9999/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/edi9999/subscriptions","organizations_url":"https://api.github.com/users/edi9999/orgs","repos_url":"https://api.github.com/users/edi9999/repos","events_url":"https://api.github.com/users/edi9999/events{/privacy}","received_events_url":"https://api.github.com/users/edi9999/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":16,"created_at":"2015-01-13T08:12:51Z","updated_at":"2015-02-23T07:48:00Z","closed_at":null,"body":"Crossposting from https://github.com/kien/ctrlp.vim/issues/562\r\n\r\n> First let me say how much I love CtrlP. It's super useful and powerful. Thanks so much, Kien!\r\n> \r\n> An enhancement that I would find very helpful would be that when I'm not in regex mode, the list would automatically sort with preference to exact matches. Exact matches of filename would come first, then exact matches anywhere in the path (if in path mode), then fuzzy (aka spread out) matches in the filename, then fuzzy matches anywhere in the path.\r\n> \r\n> For example, in my current project, I'm looking for this file:\r\n> \r\n> public/angular/estimate_form/views/main.html\r\n> \r\n> But if I just type \"main.html\" (in path/non-regex mode), I get a whole bunch of files that spell out all of those letters over the whole path. Sometimes there's a \"main\" all together, sometimes there's an \"html\" all together, and sometimes those letters are all spread out:\r\n> \r\n> app/views/estimates/rfqs/index.html.erb\r\n> app/views/companies/settings.html.erb\r\n> doc/app/classes/MainController.html\r\n> doc/app/classes/FormattingHelper.html\r\n> app/views/companies/index.html.erb\r\n> app/views/equipment_items/_packing.html.erb\r\n> app/views/companies/new.html.erb\r\n> doc/app/classes/WideFormatSection.html\r\n> app/views/main/index.html.erb\r\n> app/views/main/about.html.erb\r\n> doc/app/classes/InventoryItemLocation.html\r\n> doc/app/classes/CompanyInformation.html\r\n> \r\n> With my current results list height (25), I actually don't get my desired file at all.\r\n> \r\n> Of course, if I switch to regex mode, or if I use filename mode or \"filename;path\", I get better results. But when I do any of those things, there are drawbacks that come from them. For example, in regex mode I have to be precise with spelling and in filename mode I can't do \"a/c/main_controller\". So I have to be switching between modes to get different benefits at different times.\r\n> \r\n> If the results were already ordered in the way I described above, my file would probably be the very first one in the list, but I could still use paths if desired. I could set it to path/non-regex by default, and pretty much leave it there all the time without thinking about modes, which one to switch to, etc.\r\n> \r\n> I could see this feature either as just the default way it works or as an option that could be set in vimrc.\r\n> \r\n> Again, thanks for the great plugin, and thanks for considering my suggestion.\r\n"},"comment":{"url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/issues/comments/75500500","html_url":"https://github.com/ctrlpvim/ctrlp.vim/issues/69#issuecomment-75500500","issue_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/issues/69","id":75500500,"user":{"login":"Tobbe","id":30793,"avatar_url":"https://avatars.githubusercontent.com/u/30793?v=3","gravatar_id":"","url":"https://api.github.com/users/Tobbe","html_url":"https://github.com/Tobbe","followers_url":"https://api.github.com/users/Tobbe/followers","following_url":"https://api.github.com/users/Tobbe/following{/other_user}","gists_url":"https://api.github.com/users/Tobbe/gists{/gist_id}","starred_url":"https://api.github.com/users/Tobbe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Tobbe/subscriptions","organizations_url":"https://api.github.com/users/Tobbe/orgs","repos_url":"https://api.github.com/users/Tobbe/repos","events_url":"https://api.github.com/users/Tobbe/events{/privacy}","received_events_url":"https://api.github.com/users/Tobbe/received_events","type":"User","site_admin":false},"created_at":"2015-02-23T07:48:00Z","updated_at":"2015-02-23T07:48:00Z","body":"Or how about matching from right to left?"}}