Skip to content
Snippets Groups Projects
Commit 9b18248b authored by Kristina Mazur's avatar Kristina Mazur
Browse files

Merge branch 'feature/renamed_start_file' into 'develop'

rce_workflow (schueltke): renamed start file

See merge request !47
parents 67125493 babd49f7
No related branches found
No related tags found
2 merge requests!48Initial open source version,!47rce_workflow (schueltke): renamed start file
......@@ -217,18 +217,18 @@ def prepare_resume_of_parameter_study(paths_and_names, path_to_folder_old_refere
else:
abort_parameter_study_flag = True
# check if the current element contains the string 'CPACS'
# check if the current element contains the string 'start'
# -> if true: -> copy aircraft exchange file to project folder
if 'start' in element:
# copy working version of aircraft exchange file
# copy start version and rename it to working version of aircraft exchange file
shutil.copyfile(path_to_folder_old_reference + element,
temporary_working_directory + '/' + aircraft_project[:-4] + '/'
+ aircraft_project)
# copy csd version of aircraft exchange file
# copy start version of aircraft exchange file
shutil.copyfile(path_to_folder_old_reference + element,
temporary_working_directory + '/' + aircraft_project[:-4] + '/'
+ aircraft_project[:-4] + '_startCSD.xml')
+ aircraft_project[:-4] + '_start.xml')
else:
abort_parameter_study_flag = True
......
......@@ -246,22 +246,21 @@ def check_design_logic(paths_and_names, parameter_for_design_case, control_setti
''' set design mode specific settings and perform initializing steps '''
if design_mode == 1 or design_mode == 2 or design_mode == 4:
''' set design mode specific settings '''
# design mode 1 or 4 is selected -> check existence of _startCSD.xml file
# design mode 1 or 4 is selected -> set mode to clean_sheet_design
if design_mode == 1 or design_mode == 4:
program_switch = "mode_0"
file_name = aircraft_project + '_startCSD.xml'
check_flag_for_start_file = os.path.isfile(path_of_working_directory_rce + current_workflow_name
+ '/' + aircraft_project + '/' + file_name)
design_type = 'clean_sheet_design'
# design mode 2 is selected -> sizing with an existing
# design mode 2 is selected -> set mode to sizing with an existing geometry
if design_mode == 2:
program_switch = "mode_1"
file_name = aircraft_project + '_startRFD.xml'
check_flag_for_start_file = os.path.isfile(path_of_working_directory_rce + current_workflow_name
+ '/' + aircraft_project + '/' + file_name)
design_type = 'retrofit_design/without_calibration'
''' check existance of start file '''
file_name = aircraft_project + '_start.xml'
check_flag_for_start_file = os.path.isfile(path_of_working_directory_rce + current_workflow_name
+ '/' + aircraft_project + '/' + file_name)
''' perform initializing steps '''
# append final file separator to path_to_aircraft_project if not exiting
if not path_to_aircraft_projects[-1] == '/':
......
......@@ -404,7 +404,7 @@ def set_configuration_parameter(paths_and_names, global_loop_counter):
elif set_to_default_before_run:
content_list_of_project_folder = os.listdir(path_to_project)
starting_file = aircraft_project + '_startCSD.xml'
starting_file = aircraft_project + '_start.xml'
cpacs_file = aircraft_project + '_CPACS.xml'
for element in content_list_of_project_folder:
# delete current file from project folder
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment