•
•
•
•
What is DaniWeb IT Discussion Community?
You're currently browsing the Shell Scripting section within the Software Development category of DaniWeb, a massive community of 423,631 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 3,194 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our Shell Scripting advertiser: Programming Forums
Views: 3330 | Replies: 5
![]() |
•
•
Join Date: May 2006
Posts: 6
Reputation:
Rep Power: 0
Solved Threads: 0
Hello,
I am new to shell scripting but I am attempting to create a script that connects to an ftp and downloads a folder of files. It then compares the downloaded folder on the local machine to another local folder. I am not sure how to work the compare function at the moment i was looking into diff's. I would also like to record the differences to a file i am also not sure how to do this. Here is what i have so far i was hoping someone could help or point me in the right direction.
I am new to shell scripting but I am attempting to create a script that connects to an ftp and downloads a folder of files. It then compares the downloaded folder on the local machine to another local folder. I am not sure how to work the compare function at the moment i was looking into diff's. I would also like to record the differences to a file i am also not sure how to do this. Here is what i have so far i was hoping someone could help or point me in the right direction.
•
•
•
•
# !/bin/bash
ftp -n -i <<EOF
open ftp.coe.neu.edu
user user pass
bin
cd www/backup
lcd ~/Desktop/backup
mget *.*
lcd ~/Desktop/
disconnect
diff backup bin
EOF
![]() |
•
•
•
•
•
•
•
•
DaniWeb Shell Scripting Marketplace
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
Similar Threads
- Looking for good FTP client with compare/sync feature (Web Developers' Lounge)
Other Threads in the Shell Scripting Forum
- Previous Thread: Complete guideline book for the DB2
- Next Thread: Ping Script


Linear Mode