Created
June 22, 2015 08:27
-
-
Save prongs/a74b456e27547127efcb to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def f(a): | |
if a is full file path: | |
return a | |
elif a is a full directory path: | |
ret = [] | |
for line in readfile(a+orderfile): | |
if line starts with "/" or has ":/": | |
ret += f(line) | |
else: # relative path | |
ret += f(a+"/"+line) | |
elif a is regex: | |
ret = [] | |
for b in glob(a): | |
ret += f(a) | |
return ret | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment