def precmd(self, line):
	"""Handle alias expansion and ';;' separator."""
	self.curline = line
	if not line:
	    return line
	args = line.split()
	while self.aliases.has_key(args[0]):
	    line = self.aliases[args[0]]
	    if '%' in line:
		ii = 1
		for tmpArg in args[1:]:
		    line = line.replace("%" + str(ii),
					  tmpArg)
		    line = line.replace('%>=' + str(ii),
					' '.join(args[ii:]))
		    ii = ii + 1
		line = line.replace("%*", ' '.join(args[1:]))
	    else:
		line = line + ' ' + ' '.join(args[1:])
	    args = line.split()
	# split into ';;' separated commands
	# unless it's an alias command
	if args[0] != 'alias':
	    marker = line.find(';;')
	    if marker >= 0:
		# queue up everything after marker
		next = line[marker+2:].lstrip()
		self.cmdqueue.append(next)
		line = line[:marker].rstrip()
	return line
dataset/ETHPy150Open cloudera/hue/desktop/core/ext-py/guppy-0.1.10/guppy/heapy/Monitor.py/MonitorConnection.precmd/original