ssr-ad 284 B

123456789
  1. #!/bin/sh -e
  2. if [ -f /tmp/adnew.conf ]; then
  3. if (grep -wq "address=" /tmp/adnew.conf); then
  4. cp /tmp/adnew.conf /tmp/ssr-update.$1
  5. else
  6. cat /tmp/adnew.conf | grep ^\|\|[^\*]*\^$ | sed -e 's:||:address\=\/:' -e 's:\^:/0\.0\.0\.0:' >/tmp/ssr-update.$1
  7. fi
  8. fi
  9. rm -f /tmp/adnew.conf