view vixm/util.py @ 19:a3385f616b53

Implemented the run shell command command
author Josef "Jeff" Sipek <jeffpc@josefsipek.net>
date Sun, 20 Aug 2006 00:31:33 -0400
parents b5370c42288b
children dfcf1a46fc56
line wrap: on
line source

def strtime(t):
	ms = t % 1000
	t /= 1000

	s = t % 60
	t /= 60

	ret = "%02d.%03d" % (s, ms)

	if t != 0:
		m = t
		ret = "%d:%s" % (m, ret)
	
	return ret

def special2int(s):
	if s == '$':
		return -1
	if s == '':
		return 1
	return int(s)

def fixupint(i, m):
	if i == -1:
		return m
	return i