hi rob,

it SHOULD work even if you have a lot of domains (and so they are organized
in subdirectories)

here is my proof:

this is my test.sh
---cut---
#!/bin/sh
USERNAME=`echo ${PWD##*/}`
USERHOST=`PWDTMP=${PWD%/*}; echo ${PWDTMP##*/}`
pwd
echo [EMAIL PROTECTED]
---cut---

and this is my test.sh running:
---cut---
/var/vpopmail/domains/5/test.de/test
[EMAIL PROTECTED]
---cut---

you can use annother code instead of this to get $USERNAME and $USERHOST.
but there was an error with catchall-accounts so i used these lines (i found
them in this list a few weeks / months ago)


Reply via email to