Sie -FS
Argument verwenden können, um FileSync:
$(which zip) -FSr ../data.zip .
Alle Dateien nicht im aktuellen Verzeichnis und bereits in der zip wird daraus gelöscht und alle neuen Dateien werden hinzugefügt.
Von man zip:
-FS
--filesync
Synchronize the contents of an archive with the files on the OS. Normally when an archive is updated, new files are added and changed files are updated but files that no longer exist
on the OS are not deleted from the archive. This option enables a new mode that checks entries in the archive against the file system. If the file time and file size of the entry
matches that of the OS file, the entry is copied from the old archive instead of being read from the file system and compressed. If the OS file has changed, the entry is read and com‐
pressed as usual. If the entry in the archive does not match a file on the OS, the entry is deleted. Enabling this option should create archives that are the same as new archives,
but since existing entries are copied instead of compressed, updating an existing archive with -FS can be much faster than creating a new archive. Also consider using -u for updating
an archive.
bitte Dokumentation Link – user2727195
liefern Ich habe mit einem Link zu Zip-Handbuch aktualisiert –