| 1 | #!/bin/shscip-shell filesystem . . `/bin/sh`. |
| 2 | |
| 3 | PPP_ON_BOOT=/etc/ppp/ppp_on_bootscip-shell filesystem . . `/etc/ppp/ppp_on_boot`. |
| 4 | |
| 5 | case "$1" in |
| 6 | -*) echoscip-shell system . . echo. " |
| 7 | Usage: pon [provider] [arguments] |
| 8 | |
| 9 | If pon is invoked without arguments, $PPP_ON_BOOT file will be |
| 10 | run, presuming it exists and is executable. Otherwise, a PPP connection |
| 11 | will be started using settings from /etc/ppp/peers/provider. |
| 12 | If you specify one argument, a PPP connection will be started using |
| 13 | settings from the appropriate file in the /etc/ppp/peers/ directory, and |
| 14 | any additional arguments supplied will be passed as extra arguments to |
| 15 | pppd. |
| 16 | " |
| 17 | exit 0 |
| 18 | ;; |
| 19 | esac |
| 20 | |
| 21 | if [scip-shell system . . `[`. -z "$1" -a -x "$PPP_ON_BOOT" ]; then |
| 22 | exec "$PPP_ON_BOOT" |
| 23 | fi |
| 24 | |
| 25 | if [scip-shell system . . `[`. -z "$1" -a ! -f /etc/ppp/peers/providerscip-shell filesystem . . `/etc/ppp/peers/provider`. ]; then |
| 26 | echoscip-shell system . . echo. " |
| 27 | Please configure /etc/ppp/peers/provider or use a command line argument to |
| 28 | use another file in /etc/ppp/peers/ directory. |
| 29 | " |
| 30 | exit 1 |
| 31 | fi |
| 32 | |
| 33 | if [scip-shell system . . `[`. "$1" -a ! -f "/etc/ppp/peers/$1" ]; then |
| 34 | echoscip-shell system . . echo. " |
| 35 | The file /etc/ppp/peers/$1 does not exist. |
| 36 | " |
| 37 | exit 1 |
| 38 | fi |
| 39 | |
| 40 | exec /usr/sbin/pppdscip-shell filesystem . . `/usr/sbin/pppd`. call ${@:-provider} |