linux如何解压多个目录下的多个zip包

[复制链接]
查看11 | 回复3 | 2012-3-12 22:07:54 | 显示全部楼层 |阅读模式
解压到.zip所在的目录:find test -type f -iname '*.zip' -execdir unzip {} \;解压到当前目录:find test -type f -iname '*.zip' -exec unzip {} \;...
回复

使用道具 举报

千问 | 2012-3-12 22:07:54 | 显示全部楼层
将下列脚本保存,执行./xxx.shtest的全路径或者直接将test的路径替换“$1"#!/bin/shziphome=$1ziplist=`du -a $ziphome |grep '\.zip$'| awk '{print $2}'`for loop in $ziplistdocd ${loop%/*}unzip -o $lo...
回复

使用道具 举报

千问 | 2012-3-12 22:07:54 | 显示全部楼层
# find /文件夹/ -name *.gz >zip.list# for TAR in `cat zip.list`;do tar zxvf $TAR;done;...
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行