def generate_swift
      self.generated_paths = [] # reset generated paths in case we're called multiple times
      file_content = []
      file_content << "import Foundation"

      tool_details = []
      ActionsList.all_actions do |action|
        next if self.actions_not_supported.include?(action.action_name)

        swift_function = process_action(action: action)
        if defined?(swift_function.class_name)
          tool_details << SwiftToolDetail.new(
            command_line_tool_name: action.action_name,
            swift_class: swift_function.class_name,
            swift_protocol: swift_function.protocol_name
          )
        end
        unless swift_function
          next
        end

        file_content << swift_function.swift_code
      end
      file_content << "" # newline because we're adding an extension
      file_content << "// These are all the parsing functions needed to transform our data into the expected types"
      file_content << generate_lanefile_parsing_functions

      tool_objects = generate_lanefile_tool_objects(classes: tool_details.map(&:swift_class))
      file_content << tool_objects
      new_file_content = file_content.join("\n")

      fastlane_swift_api_path = File.join(@target_output_path, "Fastlane.swift")
      old_file_content = File.read(fastlane_swift_api_path)

      # compare old file content to potential new file content
      api_version = determine_api_version(new_file_content: new_file_content, old_file_content: old_file_content)
      old_api_version = find_api_version_string(content: old_file_content)

      # if there is a change, we need to write out the new file
      if api_version != old_api_version
        new_file_content.concat(autogen_version_warning_text(api_version: api_version))

        File.write(fastlane_swift_api_path, new_file_content)
        UI.success(fastlane_swift_api_path)
        self.generated_paths << fastlane_swift_api_path
      end

      default_implementations_path = generate_default_implementations(tool_details: tool_details)

      # we might not have any changes, like if it's a hotpatch
      self.generated_paths += default_implementations_path if default_implementations_path.length > 0

      return self.generated_paths
    end
def generate_swift
      self.generated_paths = [] # reset generated paths in case we're called multiple times
      file_content = []
      file_content << "import Foundation"

      tool_details = []
      ActionsList.all_actions do |action|
        next if self.actions_not_supported.include?(action.action_name)

        swift_function = process_action(action: action)
        if defined?(swift_function.class_name)
          tool_details << SwiftToolDetail.new(
            command_line_tool_name: action.action_name,
            swift_class: swift_function.class_name,
            swift_protocol: swift_function.protocol_name
          )
        end
        unless swift_function
          next
        end

        file_content << swift_function.swift_code
      end
      file_content << "" # newline because we're adding an extension
      file_content << "// These are all the parsing functions needed to transform our data into the expected types"
      file_content << generate_lanefile_parsing_functions

      tool_objects = generate_lanefile_tool_objects(classes: tool_details.map(&:swift_class))
      file_content << tool_objects
      new_file_content = file_content.join("\n")

      fastlane_swift_api_path = File.join(@target_output_path, "Fastlane.swift")
      old_file_content = File.read(fastlane_swift_api_path)

      # compare old file content to potential new file content
      api_version = determine_api_version(new_file_content: new_file_content, old_file_content: old_file_content)
      old_api_version = find_api_version_string(content: old_file_content)

      # if there is a change, we need to write out the new file
      if api_version != old_api_version
        new_file_content.concat(autogen_version_warning_text(api_version: api_version))

        File.write(fastlane_swift_api_path, new_file_content)
        UI.success(fastlane_swift_api_path)
        self.generated_paths << fastlane_swift_api_path
      end

      default_implementations_path = generate_default_implementations(tool_details: tool_details)

      # we might not have any changes, like if it's a hotpatch
      self.generated_paths += default_implementations_path if default_implementations_path.length > 0

      return self.generated_paths
    end
stores all file names of generated files (as they are generated)