3 ms·
I rewrote 2,650 lines of C as a seven line shell script. The previous programming team had written a data transfer program with its own implementation of ftp. I
by mrlyc 4y ago
I rewrote 2,650 lines of C as a seven line shell script. The previous programming team had written a data transfer program with its own implementation of ftp. I just used the one that was already on the computer.
- gaws 4y agoCan you share this script? I'm interested to see how 2,650 lines of C got boiled down to seven lines of shell.
- mrlyc 4y agoI just wrote echo "open $mainframe\ \nuser $mf_username $mf_password \nsite lr=160\ \ncd ..\ \nmput \*\ \nquit" | ftp -i -n -v > $ftp_log 2>&1 The program collected data from the telephone company's Nortel MD110 switches, tidied it up and sent it to their mainframes.