def create_files(project_name, root_dir):
    """Creates all of the necessary files for a given project skeleton"""
    root_dir = projectfolders.create_path(root_dir, project_name) #Modify the root
    
    write_setup(project_name, root_dir)
    write_inits(project_name, root_dir)
    write_tests(project_name, root_dir)
Exemple #2
0
def get_file_path(root_dir, sub_dir, filename):
    if sub_dir == None:  #In case we're writing directly to the root directory
        return os.path.normpath(os.path.join(root_dir, filename))

    #Otherwise, build out the appropriate path for the subdirectory
    return os.path.normpath(
        os.path.join(projectfolders.create_path(root_dir, sub_dir), filename))
Exemple #3
0
def create_files(project_name, root_dir):
    """Creates all of the necessary files for a given project skeleton"""
    root_dir = projectfolders.create_path(root_dir,
                                          project_name)  #Modify the root

    write_setup(project_name, root_dir)
    write_inits(project_name, root_dir)
    write_tests(project_name, root_dir)
Exemple #4
0
def get_file_path(root_dir, sub_dir, filename):
    if sub_dir == None: #In case we're writing directly to the root directory
        return os.path.normpath(os.path.join(root_dir, filename))
    
    #Otherwise, build out the appropriate path for the subdirectory
    path_ = projectfolders.create_path(root_dir, sub_dir)
    filepath = os.path.join(path_, filename)
    return os.path.normpath(filepath)