Switched from old to new form of string rfind()
1 parent f5601d1 commit 1af0f807e8e5ea62ed076b90c1cdab4aa2c968ca
@tundra tundra authored on 5 Jul 2001
Showing 1 changed file
View
5
tdir
# python Library Imports
 
import getopt
import os
import string
import sys
 
# Version info
 
VERSION = "$Id: tdir,v 1.59 2001/07/04 00:02:12 tundra Exp $"
VERSION = "$Id: tdir,v 1.60 2001/07/05 15:37:56 tundra Exp $"
 
 
# Booleans
 
def OrderByExtension(list):
ExtList = {}
ExtList[""] = [] # List of files with no extension
for x in list:
y = string.rfind(x, SEP)
y = x.rfind(SEP)
if y != -1: # File has extension
ext = x[y+1:]
name = x[:y]
if not ExtList.has_key(ext):