def archive(self):
        """
        Save a copy of the download zip file on RawDataVersion and a copy of
        each .TSV file on the associated RawDataFile.
        """
        if self.verbosity:
            self.log(" Archiving original files")
        # Remove previous zip file
        self.version.zip_file_archive.delete()
        # Open up the zipped file so we can wrap it in the Django File obj
        zipped_file = open(self.zip_path)
        # Save the zip on the raw data version
        self.version.zip_file_archive.save(
            self.url.split('/')[-1],
            File(zipped_file)
        )
        zipped_file.close()

        # make the RawDataFile records
        for raw_data_file in self.raw_data_files.filter(version=self.version):
            # Remove previous .TSV file
            raw_data_file.download_file_archive.delete()
            # Open up the .TSV file so we can wrap it in the Django File obj
            with open(self.tsv_dir + raw_data_file.file_name % '.TSV') as f:
                # Save the .TSV on the raw data file
                raw_data_file.download_file_archive.save(
                    raw_data_file.file_name + '.TSV',
                    File(f)
                )
dataset/ETHPy150Open california-civic-data-coalition/django-calaccess-raw-data/calaccess_raw/management/commands/downloadcalaccessrawdata.py/Command.archive/operator `+` -> `%`