def create_directory_if_missing(dir_):
    """
        Create the vault and configuration file storage folder if it does not exist
    """
    import os
    try:
        if not os.path.exists(dir_):
            os.makedirs(dir_)
            return True
        return False
    except Exception:
        import sys
        print()
        print(
            'We were unable to create the folder `%s` to store the vault and configuration file.'
             % dir_)
        print(
            'Please check the permissions or run `./vault.py --help` to find out how to specify an alternative path for both files.'
            )
        print()
        sys.exit()
