#!/usr/bin/env python 
import os
import sys
import yaml
import argparse
from ikcms.cli import manage

if __name__ == '__main__':
    try:
        with open('apps.yaml') as f:
            apps_cfg = yaml.load(f)
    except OSError:
        print("Can't open file {}".format('apps.yaml'))
        sys.exit()

    apps = apps_cfg.get('apps', [])
    paths = apps_cfg.get('paths', [])
    manage(apps=apps, paths=paths)
