diff --git a/src/var/lib/tyto/program/infos.py b/src/var/lib/tyto/program/infos.py index 4686c26..78a626d 100644 --- a/src/var/lib/tyto/program/infos.py +++ b/src/var/lib/tyto/program/infos.py @@ -23,16 +23,12 @@ def tyto(target): noinfos = False # Show Version - try: - if os.path.exists('/usr/bin/tyto'): - tytobin = open('/usr/bin/tyto').read() - for line in tytobin.rsplit('\n'): - if line.startswith('# Version:'): - print(line) - break - except: - noinfo = True - print(':< No /usr/bin/tyto') + tytobin = open('/usr/bin/tyto').read() + for line in tytobin.rsplit('\n'): + if line.startswith('# Version:'): + print(line) + break + # Show domains list try: diff --git a/src/var/lib/tyto/program/wip.py b/src/var/lib/tyto/program/wip.py index 5594b74..297e10f 100644 --- a/src/var/lib/tyto/program/wip.py +++ b/src/var/lib/tyto/program/wip.py @@ -44,7 +44,8 @@ def manage_wip(target): if post_db.endswith('.conf'): # Load DB post_db = '%s%s'%(db.articles_db, post_db) - args.target = 'index.tyto' + exec(open(post_db).read(),globals()) + args.target = post_src.rsplit('%s/'%db.in_dir)[1] importlib.reload(db) print(':> [%s] | %s'%(db.title, db.post_src)) if not db.hash_wip: continue