Commit 2921fc01 authored by Betoule Marc's avatar Betoule Marc
Browse files

Merge branch 'newbase' of gitorious.org:pipelet/pipelet into newbase

parents 29b18b9c 0669a6b6
......@@ -225,13 +225,13 @@ The segment code is executed in a specific environment that provides:
2. Functionnalities to use the automated hierarchical data storage system.
- get_data_fn(basename): complete the filename with the path to the working directory.
- glob_seg(regexp, seg): return the list of filename matching regexp from segment seg
- glob_seg(seg, regexp): return the list of filename matching regexp from segment seg
- get_tmp_fn(): return a temporary filename.
3. Functionnalities to use the automated parameters handling
- lst_par: list of parameter names of the segment
- lst_tag: list of parameter names which will be made visible from the web interface
- load_param(seg, lst_par)
- load_param(seg, globals(), lst_par)
4. Various convenient functionalities
- save_products(filename=', lst_par='*'): use pickle to save a
......
......@@ -82,6 +82,9 @@ def str_file(obj):
if isinstance(obj, str):
s = _sup.sub('',obj)
s = _rep.sub('_',s)
elif isinstance(obj, dict):
obj = [v for k,v in obj.iteritems()]
s = '_'.join([str_file(o) for o in obj])
else:
try:
s = '_'.join([str_file(o) for o in obj])
......
......@@ -570,7 +570,7 @@ class Web:
"""
directory = self.check_path (segid, directory)
html = html_tmp + '<h1> Content of %s </h1> <div class="list"><ul>'%directory
for filename in glob(os.path.join(directory,'*')):
for filename in sorted(glob(os.path.join(directory,'*'))):
absPath = os.path.abspath(filename)
if os.path.islink(absPath):
html += '<li><a href="pipedir?segid=%d&directory='%int(segid) + absPath + '">' + os.path.basename(filename)+"("+os.path.realpath(filename)+")" + "</a></li>"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment