Base réécriture script package

This commit is contained in:
2017-01-19 17:39:55 +01:00
parent 86216e639e
commit 8469bf2c08
3 changed files with 66 additions and 41 deletions

View File

@ -1,6 +1,11 @@
import os, glob, subprocess
import web, system
def get_available_profiles():
profiles_dir = os.path.realpath(os.path.dirname(os.path.abspath(__file__)) + "/../profiles")
profile_files = glob.glob(profiles_dir + '/*.conf')
return [os.path.splitext(os.path.basename(f))[0] for f in profile_files]
def get_workspace_dir():
"""Return the absolute path to the tamarin workspace ($HOME/.tamarin)"""
home = os.environ["HOME"]