def get_pack_directory(pack_name):
 packs_base_paths = get_packs_base_paths()
 for packs_base_path in packs_base_paths:
  pack_base_path = os.path.join(packs_base_path, quote_unix(pack_name))
  pack_base_path = os.path.abspath(pack_base_path)
  if os.path.isdir(pack_base_path):
   return pack_base_path
 return None

def get_pack_directory ( pack_name ) : packs_base_paths = get_packs_base_paths ( ) for packs_base_path in packs_base_paths : pack_base_path = os . path . join ( packs_base_path , quote_unix ( pack_name ) ) pack_base_path = os . path . abspath ( pack_base_path ) if os . path . isdir ( pack_base_path ) : return pack_base_path return None
retrieve a directory for the provided pack .