from setuphelpers import *
import platform

def install():
    if platform.system() == 'Windows':
        pathdoc = r'C:\documentation\doc-wapt'
    else:
        pathdoc = "/opt/documentation/doc-wapt"
        
    if isdir(pathdoc):
        remove_tree(pathdoc)
    
    # mkdirs(pathdoc)
    # copytree2('build',pathdoc)

    mkdirs(pathdoc)
    build_src = makepath(os.path.dirname(__file__), 'build')

    print("Source build : %s" % build_src) 
    print("Destination  : %s" % pathdoc)

    copytree2(build_src, pathdoc)


def uninstall():
    if platform.system() == 'Windows':
        pathdoc = r'C:\documentation\doc-wapt'
    else:
        pathdoc = "/opt/documentation/doc-wapt"

    if isdir(pathdoc):
        remove_tree(pathdoc)