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.
How to copy a source file in the Pythonista app UI?
-
Is there a way to copy a file in the Pythonista app UI? I can see how to copy a file in the share sheet, but can't figure out how to paste the copied file back into the Pythonista project folder.
(Note that this question is not asking how to copy a file in Python.)
-
@smarteepantz instead of copy the file in the share sheet, select "run Pythonista script"
Then select "import file" and your file will be imported in the Pythonista root
-
@cvp is the standard means if importing. what i have been doing is i have files in my Files app and i add that file to Pythonista using External File and just saving there..
-
@stephen I know but it could happen that the wanted file is not in Files app.
If it is here, you can also, in Pythonista do + / import / Files -
@stephen and you can also, in split view, perform a drag & drop from Files to Pythonista
-
There is also a system wide Clipboard:
Use Universal Clipboard to copy and paste between your Apple devices(doesnt help here, but i found it interest to know)
-
@smarteepantz you could write a script (used as a Pythonista tool for instance) to paste the file from UIPasteBoard but you should loose the file name 😢
-
@cvp One could compress the file into a
zip
for example and then save Archive file then paste and decompress inside Pythonista. not only should this preserve FileName but also alow transferring of multiple Files in one go? can set it up to run from pyKeys" -
@stephen If you compress the file into a zip, that will say that you run a script, thus you don't have used "copy" action in the share sheet but "run Pythonista script", and in this case, you don't loose the name, thus you can do what you want, like "import file"
-
And, if you select multiple files in once, they are all passed to the share sheet and Pythonista standard script "import file" imports all of them in one shot.
-
@cvp said:
And, if you select multiple files in once, they are all passed to the share sheet and Pythonista standard script "import file" imports all of them in one shot.
outstanding 😊 thank you