相关疑难解决方法(0)

如何覆盖现有的 zip 文件而不是在 Info-Zip 中更新它?

要像 tar 一样获取新的 zip 文件,我是否必须在执行rm foo.zip之前执行zip

$ mkdir foo; touch foo/bar
$ zip -r foo.zip foo
  adding: foo/ (stored 0%)
  adding: foo/bar (stored 0%)
$ rm foo/bar; touch foo/baz
$ zip -r foo.zip foo
  adding: foo/ (stored 0%)
  adding: foo/baz (stored 0%)
$ unzip -l foo.zip
Archive:  foo.zip
  Length      Date    Time    Name
---------  ---------- -----   ----
        0  2011-10-27 07:49   foo/
        0  2011-10-27 07:49   foo/bar
        0  2011-10-27 07:49   foo/baz
---------                     -------
        0                     3 files
Run Code Online (Sandbox Code Playgroud)

zip command-line

43
推荐指数
2
解决办法
3万
查看次数

标签 统计

command-line ×1

zip ×1