Welcome!
This is the community forum for my apps Pythonista and Editorial.
For individual support questions, you can also send an email. If you have a very short question or just want to say hello — I'm @olemoritz on Twitter.
filenav - a simple file navigator
-
Thanks for telling me, will fix that now. Looks like I forgot to change a few small things.
-
A few commits later:
- A bunch of internal optimizations, thanks @ccc!
- Special support for opening HTML, audio and image files
- Conditional default actions depending on file type
- Activity indicator while loading folders
-
http://github.com/dgelessus/filenav
After five months of doing nothing with it I got around to rearranging filenav's internals into a separate module, hopefully this will make writing a full iPad version easier. Few visible changes have happened, though there are a few new things:
- The starting folder is a favorites list loaded from a JSON file, which has a few common locations in it by default.
- Favorites can be moved and deleted from the UI, new ones can currently only be added by editing the JSON directly.
- This once again makes it possible to access the Pythonista.app bundle, even in the 1.6 beta!
- Slightly better command line support.
Under-the-hood changes:
- No more use of globals, instead a
FilenavApp
object is used to store data and is available under theapp
attribute of all data sources. FilenavApp
also serves as a common interface to the two versions of filenav (once both of them exist).- The
FileItem
class should be slightly cleaner, there were a few things I wrote strangely... - And the usual uninteresting improvements and fixes here and there.
There's probably still the odd bug here and there, if you happen to find one, please report it here or on GitHub. Pull requests are also welcome, as usual.
-
Hi @dgelessus I put all the files in a folder called filename but when I hit play it say "ImportError: No module named filenav" when trying to import common
-
Hi @dgelessus forget it, I didn't import all the files
-
@dgelessus I don't know how the edit button works, I press it and then press a file or folder an nothing happens, i'm on an iphone 5
-
At the moment the edit button does nothing in folder view. In the favorites list you can use it to move and delete favorites.
-
Thanks @dgelessus, it would be great add the possibility of delete and move files and folders, zip and unzip files. Great software congrats
-
I love the full 'panel" view implementation. I would be cool if you could find a way to auto scroll to any newly opened views.
Bug: Quick Look Preview "Done" button does nothing and system is hung.
I tried switching slim over to 'panel' and it does not work the same. I got it to crash once.
Thanks also for providing litenav. This is a really great example app for the NavigationView.
-
I'm aware that Quick Look (or any other function that overlays a second UI) causes Pythonista to hang in panel view, but there's unfortunately nothing I can do about that. Views presented in panel mode do not respond to the close method as they should, so there is no way to hide filenav before opening the quick look sheet.
Automatic scrolling is a good idea and should be easy to add, thanks for the suggestion.
-
The favorites list now has a "plus" button to add new favorites from the UI, no need to edit
favorites.json
anymore. It shouldn't be too hard to implement this for folder views as well to create new files/folders.Known problem - it is impossible to use list reordering controls in a panel view. Dragging a move handle is registered as a horizontal swipe to switch between console and editor, which cancels the list item dragging. @omz this is most likely bug in Pythonista, I've experienced it previously with table views in sidebar mode.
-
Zip files on Ipad?
I am using Pythonista on an Ipad Air for an introductory Python course. I am new to programming and to apple products (the tablet is my wife's) and am bewildered by the lack of a file handling utility. I am stubbornly determined to figure this all out.
I attempted to download the following in order access a problem set for the course:
https://courses.edx.org/c4x/MITx/6.00.1x_5/asset/ProblemSet4.zip
No sucess to either Dropbox or Google Drive. Would filenav be able to do that? Or do I need to get an app like Goodreader? And please let me know if this is the right forum to be asking this.
Thank you @dgelessus -
Dgelessus- yeah, that's a pet peeve of mine (I wish just the title bar switched to editor, since
touch_moved
are off limits in panel. ) I have noticed some other components, like scrollbar do correctly capture the touch move, as long as the touch is a certain distance away from the edge of the screen. Have you tried moving the component away from the edge ? -
Cynicuss:
I'd recommend installing stash, by copying the getstash script and running it. If you add at all comfortable with the commandline, this has a ton of feature.Otherwise, you can always download a file using urllib.urlretrieve, and use other python libs to unzip...
In stash, downloading from a url would be
wget https://courses.edx.org/c4x/MITx/6.00.1x_5/asset/ProblemSet4.zip
After which you can use the unzip command on the downloaded file.
-
Filenav doesn't have any un/zipping capabilities at the moment, though there are a few other scripts that can do that. If you know the basics of how to use a shell, StaSh is probably the easiest way. An external app like GoodReader is usually not a good choice if you want to get the files back into Pythonista - there's no way to pass entire folders or multiple files between apps, and Pythonista is not allowed to accept files via "open in" because of Apple's app review guidelines.
-
@cynicuss, I used StaSH:
Just copy and paste the
get_stash.py
code into Pythonista and run it to download and build StaSH. Then runstash.py
and...StaSh v0.4.0 [~/Documents]$ mkdir MITx [~/Documents]$ cd MITx [MITx]$ wget https://courses.edx.org/c4x/MITx/6.00.1x_5/asset/ProblemSet4.zip [MITx]$ unzip * [MITx]$ cd ProblemSet4 [ProblemSet4]$ ls ps4a.py ps4b.py test_ps4a.py words.txt
-
Thank you people. I installed StaSH and am reminded of how ignorant I am of the cmd line. The blessing is that this amazing piece of work will force me to figure it out. Live, lose, and learn!
Thanks again. -
So I just updated
filenav
to be compatible with Pythonista 3. Hopefully it'll be useful for snooping around in Pythonista internals until stash is updated (which might take a while, considering how much more complex it is). -
@dgelessus , just installed in on v2.x , it's very impressive and really a must have if you are new to this file system.
However the name is very unassuming for how full featured it is. -
@dgelessus said:
So I just updated
filenav
to be compatible with Pythonista 3. Hopefully it'll be useful for snooping around in Pythonista internals until stash is updated (which might take a while, considering how much more complex it is).It may take a while before StaSh is ready for Python 3. Honestly I am not even sure I want to do that. So far I have zero use case for Python 3. I am lack of both experience and incentive ...