libsaria: Remove unused libsaria.path code
I eventually want to get rid of this directory, so removing this code helps.
This commit is contained in:
parent
e59a613499
commit
07c673fa47
|
@ -46,24 +46,6 @@ def saria_dir_rest():
|
|||
return s_dir
|
||||
saria_dir = saria_dir_once
|
||||
|
||||
|
||||
def plugin_dir_once():
|
||||
global p_dir
|
||||
global saria_dir
|
||||
saria = saria_dir()
|
||||
dir = "plugins"
|
||||
if libsaria.__dev__ == True:
|
||||
dir += "-dev"
|
||||
p_dir = join(saria, dir)
|
||||
if exists(p_dir) == False:
|
||||
mkdir(p_dir)
|
||||
plugin_dir = plugin_dir_rest
|
||||
return p_dir
|
||||
def plugin_dir_rest():
|
||||
global p_dir
|
||||
return p_dir
|
||||
plugin_dir = plugin_dir_once
|
||||
|
||||
def cp_once(src, dest):
|
||||
global cp
|
||||
global shutil
|
||||
|
@ -75,19 +57,3 @@ cp = cp_once
|
|||
def mkdir(path):
|
||||
if not exists(path):
|
||||
makedir(path)
|
||||
|
||||
def make_tree_once(path):
|
||||
global FSTree
|
||||
from libsaria.trees import FSTree
|
||||
global make_tree
|
||||
make_tree = make_tree_rest
|
||||
return make_tree(path)
|
||||
def make_tree_rest(path):
|
||||
global FSTree
|
||||
tree = FSTree()
|
||||
for root,dirs,files in walk(path):
|
||||
split = root.split(sep)
|
||||
for file in files:
|
||||
tree.insert_path_split(split, file)
|
||||
return tree
|
||||
make_tree = make_tree_once
|
||||
|
|
Loading…
Reference in New Issue