Hi all,
I mainly work with Pythonista on the biggest iPad with external keyboard. And I miss some features like Open quickly, registering shortcuts for my scripts, ... so I decided to add them by myself. Hope it will be natively supported in the future.
Here's screen recording of what I can do with external keyboard only. If you would like to try it, feel free to clone all files from pythonista-site-packages-3 repository to your local site-packages-3 folder. Just download them or use git via StaSH.
Then you can hit ...
Cmd /- to toggle commentsCmd N- to open new tab and to show new file dialogCmd Shift N- to open just new tabCmd 0(zero) - to toggle library view (I call it navigator)Cmd W- to close current tabCmd Shift W- to close all tabs except current oneCmd O(letter o) - to quickly open files
If you need more shortcuts for more actions, just let me know and I'll try to add them.
WARNING It works, but it's experimental, dangerous. There's some swizzling, some direct calls to ObjC instances, passing guessed parameter values, etc. It can crash your Pythonista, you can lost data, ... I warned you :) If you will modify this code and Pythonista will crash during startup, just open pythonista3:// in your browser and fix your changes.
Will write more issues, so, Pythonista modules can be enhanced (like editor module functions to close tab, open file, etc.). Then I can remove some of these crazy calls.
Back to open quickly ... It just supports Python (.py) and Markdown (.md) files. That's because I have no clue yet what should I pass as editor type, when force reload should be used, ... Also some directories are excluded, so, you know why if some files are missing in open quickly dialog. Also the open quickly dialog has hidden title bar -> no close button -> you need to hit Esc (or Ctrl [ on smart keyboard) to close it.
Anyway, it's pretty scary, fascinating, ... that we can do all these things directly on iPad. Many thanks to Ole for this wonderful tool. This tool let me play with Python on iPad and I can drive our AWS services directly from iPad as well. I'm not forced to bring MBP everywhere, iPad is enough :) Thanks again.
Enjoy!
