廣告廣告
  加入我的最愛 設為首頁 風格修改
首頁 首尾
 手機版   訂閱   地圖  簡體 
您是第 8438 個閱讀者
 
發表文章 發表投票 回覆文章
  可列印版   加為IE收藏   收藏主題   上一主題 | 下一主題   
aa 手機 會員卡 葫蘆墩家族
個人文章 個人相簿 個人日記 個人地圖 個人商品
特殊貢獻獎 社區建設獎
頭銜:            
站長
級別: 站長 該用戶目前不上站
推文 x1963 鮮花 x5260
分享: 轉寄此文章 Facebook Plurk Twitter 複製連結到剪貼簿 轉換為繁體 轉換為簡體 載入圖片
推文 x0
[Linux] [教學]tar 解壓縮部份目錄
由於我備份的壓縮檔太大(3.6G),若全部解壓縮要 9G 的空間,而我只要救
其中的200多k的資料,全解要很久又很佔空間,用 man tar 也找不到指令
的用法,後來問了一下朋友,才查到的

複製程式
Listing the Contents of a Stored Directory 
(This message will disappear, once this node revised.) 
@quote-arg {i changed the order of these nodes around and haven't had a chance to play around with this node's example, yet. i have to play with it and see what it actually does for my own satisfaction, even if what it says *is* correct..} 

To get information about the contents of an archived directory, use the directory name as a file name argument in conjunction with --list (-t). To find out file attributes, include the --verbose (-v) option. 

For example, to find out about files in the directory `practice', in the archive file `music.tar', type: 

  $ tar --list --verbose --file=music.tar practice


tar responds: 

  drwxrwxrwx myself user 0 1990-05-31 21:49 practice/
-rw-rw-rw- myself user 42 1990-05-21 13:29 practice/blues
-rw-rw-rw- myself user 62 1990-05-23 10:55 practice/folk
-rw-rw-rw- myself user 40 1990-05-21 13:30 practice/jazz
-rw-rw-rw- myself user 10240 1990-05-31 21:49 practice/collection.tar


When you use a directory name as a file name argument, tar acts on all the files (including sub-directories) in that directory. 

例如我要解 home.tgz 中的 ncc 目錄
複製程式
tar zxvf home.tgz home/ncc


[ 此文章被andyz在2005-05-18 19:40重新編輯 ]



獻花 x0 回到頂端 [樓 主] From:台灣數位聯合 | Posted:2003-08-19 11:13 |

首頁  發表文章 發表投票 回覆文章
Powered by PHPWind v1.3.6
Copyright © 2003-04 PHPWind
Processed in 0.018907 second(s),query:15 Gzip disabled
本站由 瀛睿律師事務所 擔任常年法律顧問 | 免責聲明 | 本網站已依台灣網站內容分級規定處理 | 連絡我們 | 訪客留言