Forum Archive

Wifi Transfer your projects to another device.

briarfox

Hello all, I'm new to python and I thought I would share a little app that I've been using. It's a simple socket client/server that will gz a directory or file and send it to another device then unpack it. I got tired of emailing projects between my pc and iphone. Please feel free to give me any feedback/advice as I said before i'm very new to python.

Usage:

args:

server - Opens in server mode

ip | path - uploads file to device

examples: 
    192.168.1.50 Projects/example project 
    192.168.1.50:8091 Projects/coolapp.py

no args:

console prompts

https://gist.github.com/briarfox/b1880157f149d36154d5

briarfox

Updated the gist, server will stay up until it receives the 'quit' command from the client.

briarfox

I'm having an issue that maybe one of you has dealt with. When running in server mode on windows cmd the script finishes while the server should be running. This can be fixed with a raw_input() at the end. However, using raw_input in pythonista causes the sever to wait for a key press before processing the data.