導航:首頁 > 程序命令 > zip命令打包

zip命令打包

發布時間:2022-01-30 17:18:45

A. linux zip壓縮。壓縮當前文件夾下所有文件,壓縮為a.zip。命令行的方法是怎樣。

linux zip壓縮。壓縮當前文件夾下所有文件,壓縮為a.zip。可以使用命令zip -r mydata.zip dir。例如:

要壓縮/home/data這個目錄,則壓縮命令為zip -q -r mydata.zip /home/data;

如果現在在/home 這個目錄下,則命令是zip -q -r data.zip data;

如果在/home/data 這個目錄下,則命令是zip -q -r data.zip * 。

(1)zip命令打包擴展閱讀

linux zip壓縮命令主要參數介紹:

1、-c:將解壓縮的結果。

2、-l:顯示壓縮文件內所包含的文件。

3、-p:與-c參數類似,會將解壓縮的結果顯示到屏幕上,但不會執行任何的轉換。

4、-t:檢查壓縮文件是否正確。

5、-u:與-f參數類似,但是除了更新現有的文件外,也會將壓縮文件中的其它文件解壓縮到目錄中。

6、-v:執行是時顯示詳細的信息。

7、-z:僅顯示壓縮文件的備注文字。

8、-a:對文本文件進行必要的字元轉換。

9、-b:不要對文本文件進行字元轉換。

10、-C:壓縮文件中的文件名稱區分大小寫。

B. 如何用bat命令把當前目錄的所有文件和文件夾打包為一個zip

@echooff&title打包當前目錄By依夢琴瑤

setWinRAR_Dir=%ProgramFiles%WinRAR

setPATH=%PATH%;%WinRAR_Dir%

WinRAR.exea-r"當前目錄備份.zip"-rr-m5*-ibck
pause

C. 如何在Windows平台實現zip壓縮命令

操作步驟如下:
1、打開winrar的安裝文件夾,復制rar.exe到c:\windows文件夾下;
2、點擊開始,點擊運行,輸入cmd,點擊確定;
3、提示符後輸入rar 1.zip c:\lizi,回車,該命令是將c:\lizi文件夾壓縮為1.zip。

D. 如何使用rar在命令行下打包目錄

這個問題本來很簡單,因為多數站點主機都會安裝winrar,如果你獲得的shell能夠運行exe文件,你就可以使用rar.exe這個命令行程序進行打包,rar的詳細命令可以在winrar的安裝目錄里Rar.txt文件中找到,也許因為大家習慣了圖形界面,忽略了這些命令,下面我就給大家一個打包例子,希望對大家能有點幫助. 例:把E:\web\目錄下的所有東西打包為1.rar放到E:\web\目錄下,以便下載 C:\Program Files\WinRAR\Rar.exe a -k -r -s -m1 E:\web\1.rar E:\web\參數說明: a 添加文件到壓縮文件中 -k 鎖定壓縮文件 -s產生固體存檔,這樣可以增大壓縮比 -r包括子目錄 -m1 設置壓縮比 -m0 存儲 添加到壓縮文件時不壓縮文件。 -m1 最快 使用最快方式(低壓縮) -m2 較快 使用快速壓縮方式 -m3 標准 使用標准(默認)壓縮方式 -m4 較好 使用較好壓縮方式(較好壓縮,但是慢) -m5 最好 使用最大壓縮方式(最好的壓縮,但是最慢)Sample Text

E. winzip命令行打包文件夾,要加什麼參數,才能不包含文件夾的路徑到zip中

應該不直接支持你說的功能,間接的辦法是list一個文件表。不過你文件多了話還是沒辦法。你可以看網上的教程。

What command line parameters does WinZip support?

Below is some information about the undocumented command line options for using the WinZip program mole, winzip32.exe.

WinZip supports command line options to add and extract from files. Be sure to read the Notes section below for additional important information.
Adding Files

The command format is:

winzip32 [-min] action [options] filename[.zip] files

where:

-min specifies that WinZip should run minimized. If -min is specified, it must be the first command line parameter.

action
-a for add, -f for freshen, -u for update, and -m for move. You must specify one (and only one) of these actions. The actions correspond to the actions described in the section titled "Add dialog box options" in the online manual.

options
-r corresponds to the Include subfolders checkbox in the Add dialog and causes WinZip to add files from subfolders. Folder information is stored for files added from subfolders. If you add -p, WinZip will store folder information for all files added, not just for files from subfolders; the folder information will begin with the folder specified on the command line.

-ex, -en, -ef, -es, and -e0 determine the compression method: eXtra, Normal, Fast, Super fast, and no compression. The default is "Normal". -hs includes hidden and system files. Use -sPassword to specify a case-sensitive password. The password can be enclosed in quotes, for example, -s"Secret Password".

filename.zip
Specifies the name of the Zip file involved. Be sure to use the full filename (including the folder).

files
Is a list of one or more files, or the @ character followed by the filename containing a list of files to add, one filename per line. Wildcards (e.g. *.bak) are allowed.
Extracting Files

The command format is:

winzip32 -e [options] filename[.zip] folder

where -e is required.

options
-o and -j stand for "Overwrite existing files without prompting" and "Junk pathnames", respectively. Unless -j is specified, folder information is used. Use -sPassword to specify a case-sensitive password. The password can be enclosed in quotes, for example, -s"Secret Password".

filename.zip
Specifies the name of the Zip file involved. Be sure to specify the full filename (including the folder).

folder
Is the name of the folder to which the files are extracted. If the folder does not exist it is created.

Notes

* VERY IMPORTANT: always specify complete filenames, including the full folder name and drive letter, for all file IDs.

* To run WinZip in a minimized inactive icon use the "-min" option. When specified this option must be the first option.

* Only operations involving the built-in zip and unzip are supported.

* Enclose long filenames in quotes.

* When using a list ("@") file, no leading or trailing spaces should appear in file IDs in the list.

* The action and each option must be separated by at least one space.

* WinZip can be used to compress files with cc:Mail . Change the compress= line in the [cc:Mail] section of the appropriate WMAIL.INI files to specify the full path for WinZip followed by "-a %1 @%2". For example, if WinZip is installed in your c:\winzip folder, specify

compress=c:\winzip\winzip.exe -a %1 @%2

F. 如何用dos命令將檔壓縮成ZIP

那你安WINRAR或者WINZIP,我的機器上沒有7Z,無法為你測試,我的批處理程序調用WINRAR進行數據壓縮備份的語句如下,你可以參考:

e:
cd e:\mysql5.0.51a\data
del d:\backup\www\web.rar
"C:\Program Files\WinRAR\Rar.exe" a -m5 -s d:\backup\www\web.rar web

G. linux下將整個文件夾打包成zip該用什麼命令

zip -r /usr/abc.zip

其中 -r 是為了將你的目錄全部循環一遍 如果是單個文件就可以不加
另外如果要指定zip到哪裡可以在後面加路徑 空格 然後加上路徑就好

H. linux zip命令。把當前文件夾下的多個文件夾、文件壓縮為 bbb.zip,命令是什麼

zip -r bbb.zip aaa bc.zip bbb

關鍵是 -r 選項:包含子目錄。 (recurse 遞歸)

I. linux下,壓縮ZIP文件,用命令怎麼實現分包壓縮

要將目錄logs打包壓縮並分割成多個1M的文件,可以用下面的命令:
tar cjf - logs/ |split -b 1m -
logs.tar.bz2.
完成後會產生下列文件:
logs.tar.bz2.aa, logs.tar.bz2.ab,
logs.tar.bz2.ac
要解壓的時候只要執行下面的命令就可以了:
cat logs.tar.bz2.a* | tar xj

J. linux zip 壓縮命令 解壓命令 unzip

linux
zip命令的基本用法是:
zip
[參數]
[打包後的文件名]
[打包的目錄路徑]
linux
zip命令參數列表:
-a
將文件轉成ASCII模式
-F
嘗試修復損壞的壓縮文件
-h
顯示幫助界面
-m
將文件壓縮之後,刪除源文件
-n
特定字元串
不壓縮具有特定字尾字元串的文件
-o
將壓縮文件內的所有文件的最新變動時間設為壓縮時候的時間
-q
安靜模式,在壓縮的時候不顯示指令的執行過程
-r
將指定的目錄下的所有子目錄以及文件一起處理
-t
日期
把壓縮文件的最後修改日期設為指定的日期,日期格式為mmddyyyy
舉例:
將/home/Blinux/html/
這個目錄下所有文件和文件夾打包為當前目錄下的html.zip
zip
–q
–r
html.zip
/home/Blinux/html
上面的命令操作是將絕對地址的文件及文件夾進行壓縮.以下給出壓縮相對路徑目錄
比如目前在Bliux

閱讀全文

與zip命令打包相關的資料

熱點內容
播放解壓的圖 瀏覽:228
新建一個名為hux的文件夾 瀏覽:532
橋水基金加密貨幣 瀏覽:196
還有什麼好app 瀏覽:152
微軟最慘的源碼 瀏覽:40
上海靈意壓縮機 瀏覽:415
泰拉瑞亞2020最新伺服器ip地址 瀏覽:563
安卓機玩吃雞什麼畫質 瀏覽:873
徒步緩解壓力的視頻 瀏覽:238
圖像演算法口訣 瀏覽:859
人踩什麼解壓 瀏覽:921
php語法檢查命令 瀏覽:330
如何重設伺服器網關 瀏覽:865
世界經濟pdf 瀏覽:108
異或演算法找缺失的數 瀏覽:326
單片機flagt1 瀏覽:486
單片機清理 瀏覽:660
東風景逸空調壓縮機 瀏覽:158
天津程序員炒股 瀏覽:230
pcl源碼目錄 瀏覽:968