Skip to content

Instantly share code, notes, and snippets.

@ryanwilsonperkin
Created September 13, 2014 02:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ryanwilsonperkin/f04ba25b56ec632e09a5 to your computer and use it in GitHub Desktop.
Save ryanwilsonperkin/f04ba25b56ec632e09a5 to your computer and use it in GitHub Desktop.
Register a shell function called ldapuser to search the University of Guelph's LDAP server for a record with the given username.
# Use as `ldapuser username` to lookup ldap record for "username"
function ldapuser {
ldapsearch -x -H ldap://directory.uoguelph.ca -b "ou=People,o=uoguelph.ca" "uid=$1"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment