34 lines
500 B
Python
Executable File
34 lines
500 B
Python
Executable File
#!/sf/bernina/applications/bm/envs/default/bin/python
|
|
import sys
|
|
from pathlib import Path
|
|
from tabulate import tabulate
|
|
name = sys.argv[1]
|
|
def name2pgrous(name):
|
|
tp = '/sf/bernina/exp/'
|
|
d = Path(tp)
|
|
dirs = [i for i in d.glob('*') if i.is_symlink()]
|
|
names = [i.name for i in dirs]
|
|
targets = [i.resolve().name for i in dirs]
|
|
return [[i_n,i_p] for i_n,i_p in zip(names,targets) if name in i_n]
|
|
|
|
print(tabulate(name2pgrous(name),tablefmt='plain'))
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|