Home Download Buy Blog Forum Support

FuzzyFileNav Plugin (on package control...finally)

Re: FuzzyFileNav Plugin (on package control...finally)

Postby skuroda on Thu Nov 15, 2012 7:31 am

I figured it was something like that, as you are very consistent in that regard. I've done a quick trace of the methods (because I'm curious too and giving you the most information will probably make the bug, if it exists, easier to fix).

I think the path getting passed to get_files(), well initially the "fuzzy_file_nav" command, is "C:". os.listdir() is then called on this, which is where things don't happen like one would expect. When you enter "C:\" as the path, the "start" variable already contains the slash ("C:\")

Well with that, I don't think there is any more information I can think of off the top of my head to help reproduce the issue. I'll check back tomorrow though, so let me know if there's anything I can clarify.
skuroda
 
Posts: 676
Joined: Fri Oct 05, 2012 8:11 am

Re: FuzzyFileNav Plugin (on package control...finally)

Postby facelessuser on Thu Nov 15, 2012 3:54 pm

There is something wrong. I want to say this is new. Slash took me to the Windows System32 folder which makes no sense.
facelessuser
 
Posts: 1542
Joined: Tue Apr 05, 2011 7:38 pm

Re: FuzzyFileNav Plugin (on package control...finally)

Postby facelessuser on Thu Nov 15, 2012 4:15 pm

My notes say slash should show all drives not the root of the drive. You were correct in your assessment that I access the root of the drive via (c:\ or c:/ not / or \); I didn't realize that :).

I should have a fix soon.
facelessuser
 
Posts: 1542
Joined: Tue Apr 05, 2011 7:38 pm

Re: FuzzyFileNav Plugin (on package control...finally)

Postby facelessuser on Thu Nov 15, 2012 4:26 pm

Never mind, it was only supposed to show all drives when the root drive could not be found. I updated the branch to fix this issue. It should now accept / or \ like the windows cmd prompt does. Thanks for reporting this issue @skuroda. get_drives was a different part of the code that generates drives right before I append slashes to all folders/drives. FuzzyFileNav should of accepted the drive with the slash not without.
facelessuser
 
Posts: 1542
Joined: Tue Apr 05, 2011 7:38 pm

Re: FuzzyFileNav Plugin (on package control...finally)

Postby facelessuser on Thu Nov 15, 2012 4:45 pm

Nix style path complete is in. To get true nix style path complete, also enable case-sensitivity...but if you are on windows, probably leave that out.

It still isn't quite there. It only matches a file when only one file matches instead of updating the string with the max shared chars. I will add that later.
facelessuser
 
Posts: 1542
Joined: Tue Apr 05, 2011 7:38 pm

Re: FuzzyFileNav Plugin (on package control...finally)

Postby facelessuser on Thu Nov 15, 2012 5:17 pm

Okay, full nix path completion is now in. I have to get some real work done, so that is it for now. Report bugs here, or issue pull requests.
facelessuser
 
Posts: 1542
Joined: Tue Apr 05, 2011 7:38 pm

Re: FuzzyFileNav Plugin (on package control...finally)

Postby skuroda on Thu Nov 15, 2012 5:40 pm

Glad you could reproduce the bug. Also, wow that was faster than I expected. Guess I don't have to use my hack-y implementation of nix file completion. Thanks for the update. Have fun with your real work! :D
skuroda
 
Posts: 676
Joined: Fri Oct 05, 2012 8:11 am

Re: FuzzyFileNav Plugin (on package control...finally)

Postby facelessuser on Fri Nov 16, 2012 1:13 am

Unix/Linux case_sensitive setting has been removed. If you set the new setting nix_style_path_complete to true the auto-complete will use case sensitivity since this method of auto-complete will not work reliably with insensitive case. And if you use the windows method of auto-complete by setting nix_style_path_complete to false, Linux/Unix will use case insensitive (since you can just tab through the actual files, case sensitivity is a non issue here). This makes it less confusing in the settings file, and more reliable when using.
facelessuser
 
Posts: 1542
Joined: Tue Apr 05, 2011 7:38 pm

Re: FuzzyFileNav Plugin (on package control...finally)

Postby dungpt on Fri Nov 30, 2012 9:13 am

Hi facelessuser, thank you for your great plugin :D btw, how can I open a folder in nav panel ? (I mean select folder and its content is displayed on the sidebar, I want to add that folder to Project ^^ )
dungpt
 
Posts: 4
Joined: Fri Nov 30, 2012 9:11 am

Re: FuzzyFileNav Plugin (on package control...finally)

Postby facelessuser on Fri Nov 30, 2012 3:50 pm

dungpt wrote:Hi facelessuser, thank you for your great plugin :D btw, how can I open a folder in nav panel ? (I mean select folder and its content is displayed on the sidebar, I want to add that folder to Project ^^ )


Currently it only does copy, cut, paste, delete, create files and folders. It also can do a "save as" operation on files.

Adding a folder to a project could be added, but Jon has not really provided a reasonable way to access the project file via the ST2 API. You have do some really odd things just to find the project file. I did a little of this in my "Favorite Files" plugin just to locate where the project file was stored so I could store a project specific settings file with the project file...it was ridiculous... That doesn't even account for adding folders to a project file that does not exist on disk yet. For me to add support for adding the folder to a project, Jon really needs to expose that access in the API first. It is just a big headache to add it with the current API.
facelessuser
 
Posts: 1542
Joined: Tue Apr 05, 2011 7:38 pm

PreviousNext

Return to Plugin Announcements

Who is online

Users browsing this forum: No registered users and 6 guests