# Path: persepolis/constants/Os.py
# class OS:
#     LINUX = 'Linux'
#     WINDOWS = 'Windows'
#     FREE_BSD = 'FreeBSD'
#     OPEN_BSD = 'OpenBSD'
#     OSX = DARWIN = 'Darwin'
#     BSD_FAMILY = [FREE_BSD, OPEN_BSD]
#     UNIX_LIKE = BSD_FAMILY + [LINUX]
#     LIST = [LINUX, WINDOWS, FREE_BSD, OPEN_BSD, OSX]


from persepolis.constants import OS
import subprocess
import platform
import shutil
import os
                             creationflags=CREATE_NO_WINDOW)
        else:

            # In linux and bsd a dot character must be added in the start of the directory's name
            dir_name = os.path.basename(folder_path)
            dir_name = '.' + dir_name 
            folder_path = os.path.join(os.path.dirname(folder_path), dir_name)

            os.makedirs(folder_path, exist_ok=True)

    else:
        os.makedirs(folder_path, exist_ok=True)

    return folder_path
    
# this function returns mount point
def findMountPoint(path):

    while not os.path.ismount(path):
        path = os.path.dirname(path)

    return path

# this function creates temporary download folder in mount point of given path
def makeTempDownloadDir(path):

    # if path and home_address are in the same partition,
    # create temp folder in default settings address.
    if os.lstat(path).st_dev == os.lstat(home_address):


# Path: persepolis/constants/Os.py
# class OS:
#     LINUX = 'Linux'
#     WINDOWS = 'Windows'
#     FREE_BSD = 'FreeBSD'
#     OPEN_BSD = 'OpenBSD'
#     OSX = DARWIN = 'Darwin'
#     BSD_FAMILY = [FREE_BSD, OPEN_BSD]
#     UNIX_LIKE = BSD_FAMILY + [LINUX]
#     LIST = [LINUX, WINDOWS, FREE_BSD, OPEN_BSD, OSX]


# Path: persepolis/scripts/osCommands.py
from persepolis.constants import OS
import subprocess
import platform
import shutil
import os

                             creationflags=CREATE_NO_WINDOW)
        else:

            # In linux and bsd a dot character must be added in the start of the directory's name
            dir_name = os.path.basename(folder_path)
            dir_name = '.' + dir_name 
            folder_path = os.path.join(os.path.dirname(folder_path), dir_name)

            os.makedirs(folder_path, exist_ok=True)

    else:
        os.makedirs(folder_path, exist_ok=True)

    return folder_path
    
# this function returns mount point
def findMountPoint(path):

    while not os.path.ismount(path):
        path = os.path.dirname(path)

    return path

# this function creates temporary download folder in mount point of given path
def makeTempDownloadDir(path):

    # if path and home_address are in the same partition,
    # create temp folder in default settings address.
    if os.lstat(path).st_dev == os.lstat(home_address):


        if os_type != OS.WINDOWS: