sender.sh 461 B

1234567891011121314151617181920
  1. #!/bin/bash
  2. #Run script for sender as part of
  3. #Assignment 2
  4. #Computer Networks (CS 456)
  5. #Number of parameters: 4
  6. #Parameter:
  7. # $1: <host_address>
  8. # $2: <receiving_port_on_host>
  9. # $3: <receiveing_port_on_sender>
  10. # $4: file_to_be_transmitted
  11. #For Python implementation
  12. if [ "$#" -ne 4 ];
  13. then
  14. echo "Program takes 4 parameters, which are a host address, host port, sender's port, and filename to be sent"
  15. exit 1
  16. fi
  17. python3 sender.py $1 $2 $3 $4