file transfer question
Ali Dada
afd00 at aub.edu.lb
Mon Apr 28 17:19:58 EDT 2003
More information about the Python-list mailing list
Mon Apr 28 17:19:58 EDT 2003
- Previous message (by thread): Slice confusion : a[n:p] is a list exclude the last element p (thus spoke Dijkstra)
- Next message (by thread): file transfer question
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
hi all:
i want to read a file from a network pc and use it in a local python script. i
thought of an easy way: i log on from within the python script to the host pc
using ssh then copy the file to my working directory using scp. below is the code:
import os
os.popen('ssh username at hostname')
os.popen('scp username at hostname:~/requiredFile ./copiedFile')
but what's happening is that when i execute the code, i get prompted for the
password by ssh, so i enter it, and then the program freezes and i can do
nothing. how do you think i should alter the code? thanks in advance..
----------
Ali Dada
- Previous message (by thread): Slice confusion : a[n:p] is a list exclude the last element p (thus spoke Dijkstra)
- Next message (by thread): file transfer question
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list