added top directory functions
first merge