File: ftpgrab

package info (click to toggle)
trn4 4.0-test76-15
  • links: PTS
  • area: non-free
  • in suites: lenny
  • size: 3,048 kB
  • ctags: 2,964
  • sloc: ansic: 48,338; sh: 6,770; tcl: 1,696; yacc: 660; perl: 108; makefile: 73
file content (20 lines) | stat: -rw-r--r-- 400 bytes parent folder | download | duplicates (12)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/bin/sh
#This script requires six arguments:
#1. site name
#2. account name to use (usually "ftp")
#3. password to use (usually user@site.net)
#4. directory to CD to
#5. filename on remote system
#6. filename on local system

#Localization note: if ftp is not always in a users path, you may want
#to use a full path name below.
ftp -n<<EOT
open $1
user $2 $3
binary
cd $4
get $5 $6
close
quit
EOT