[sork] Aliases and Vacation

Tommi Sakari Uimonen tuimonen at cc.hut.fi
Thu Aug 19 01:48:44 PDT 2004


>> if(strcmp($item[2],$user)==0) {
>> 	$name=split("[.]",$item[1]);
>> 	foreach($name as $n) {
>> 		$n=trim($n,".");
>> 		// don't add if the alias is already added
>> 		if(!strstr($aliases," -a $n")) { $aliases.= " -a $n";}
>> 	}
>> }
> I don't understand what you do there. For example:
> sebastien.corbeau: scorbeau
> s.corbeau: scorbeau
>
> "ereg" gives sebastien.corbeau and s.corbeau. It's ok.
> But after, we only have "-a sebastien -a s"

Umm. I built it to handle cases like

tommi.uimonen:  tuimonen
tommi:          tuimonen
uimonen:        tuimonen

so it will add
-a tommi -a uimonen tuimonen


It needs some fixing in your case, but I don't have the time to do it.

If vacation accepts '-a s.corbeau' just leave the last parsing out.



Tommi


More information about the sork mailing list