def dump_targets(self, output_file_name): result = [] with open(output_file_name, 'w') as f: for target_key in self.__expanded_command_targets: target = self.__target_database[target_key] result.append(target.dump()) json.dump(result, fp=f, indent=2) print(file=f)
def dump_targets(self, output_file_name): result = [] with open(output_file_name, 'w') as f: for target_key in self.__all_command_targets: target = self.__target_database[target_key] result.append(target.dump()) json.dump(result, fp=f, indent=2) print(file=f)