1#! /usr/bin/python 2# Copyright (c) 2006 The Regents of The University of Michigan 3# All rights reserved. 4# 5# Redistribution and use in source and binary forms, with or without 6# modification, are permitted provided that the following conditions are 7# met: redistributions of source code must retain the above copyright 8# notice, this list of conditions and the following disclaimer; --- 32 unchanged lines hidden (view full) --- 41 42def oksuffix(f): 43 for s in suffixes: 44 if f.endswith(s): 45 return True 46 return False 47 48file_list = file('cscope.files', 'w') |
49cwd = os.getcwd() |
50 |
51for dirpath,subdirs,files in os.walk(os.path.join(cwd, 'src')): |
52 # filter out undesirable subdirectories 53 for i,dir in enumerate(subdirs): 54 if dir == 'SCCS': 55 del subdirs[i] 56 break 57 58 # filter out undesirable absolute paths 59 if dirpath in skipdirs: --- 13 unchanged lines hidden --- |