On 1/5/11 3:16 PM, Flatfender wrote: > Yeah we hacked trac and the email2trac to do AD lookups and fill in > the user records automagically so that we always had consistent info. > And I'll second that the limitations for our purposes we're livable.
We do this via a cron job: #!/bin/sh # for user in `sqlite3 $1 'select distinct sid from session_attribute;'`; do # EMAIL=`sqlite3 $1 "select sid,value from session_attribute \ where name='email' and sid='$user';"` if [ x${EMAIL} == x ] ; then LCUSER=`echo $user | tr [:upper:] [:lower:]` EMAIL=`/root/bin/GetLDAPEMailForUser.pl $LCUSER` if [ x${EMAIL} != x ] ; then sqlite3 $1 "insert into session_attribute \ values('$user',1,'email','${EMAIL}');" echo "Added ${EMAIL} for user $user in trac.db" fi fi done To write GetLDAPEMailForUser.pl is up to the reader ;-))) Rainer -- You received this message because you are subscribed to the Google Groups "Trac Users" group. To post to this group, send email to trac-us...@googlegroups.com. To unsubscribe from this group, send email to trac-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/trac-users?hl=en.