wapt-outlook-ddaddin/setup.py

18 lines
657 B
Python
Raw Normal View History

2019-04-17 15:04:40 +02:00
# -*- coding: utf-8 -*-
from setuphelpers import *
import json
from cryptography.fernet import Fernet
import os
from jinja2 import Environment, FileSystemLoader
uninstallkey = []
# Read local variables file if available
if isfile(makepath(programfiles32,'wapt','private','symetric.txt')) and isfile(makepath(programfiles32,'wapt','private','variables.txt')):
print('Reading local encrypted variables file')
f = Fernet(open(makepath(programfiles32,'wapt','private','symetric.txt'),'r').read())
variables.update(json.loads(f.decrypt(open(makepath(programfiles32,'wapt','private','variables.txt'),'r').read())))
def install():