• Linux之tar.gz file


      A tarball (tar.gz file) is compressed tar archive.

      The tar program provides the ability to create tar archives, as well as various other kinds of manipulation. For example, you can use Tar on previously created archives to extract files, to store additional files, or to update or list files which were already stored.

      Syntax  

    tar options file.tar.gz
    tar options file.tar.gz pattern
    tar -xf file.tar.gz
    tar -xvf file.tar.gz
    tar -zxvf file.tar.gz
    tar -zxvf file.tar.gz file1 file2 dir1 dir2

      Extract tar.gz file 

      Extract one or more members from an archive, enter:

    tar -zxvf {file.tar.gz}

      If your tarball name is backup.tar.gz, enter the following at a shell prompt to extract files:

    tar -zxvf backup.tar.gz

      Extract resume.doc file from backup.tar.gz tarball, enter:

    tar -zxvf backup.tar.gz resume.doc

      Where,

      -z :  Work on gzip compression automatically when reading archives

      -x :  Extract archives

      -v :  Produce verbose output  i.e. progress and extracted file list on screen

      -f  :  Read the archive from the archive to the specified file.

      -t  :  List the files in the archive

     

      Extracting an entire archive

      To extract an entire archive, specify the archive file name only, with no individual file names as arguments.

    tar -zxvf backup.tar.gz

      List files in archive

      To view a detailed table of contents (list of file), enter:  

    tar -tvf backup.tar.gz
  • 相关阅读:
    C#中Equals和= =(等于号)的比较)(转载)
    C# 控制台应用程序输出颜色字体
    c#获取当前运行程序所在的目录
    java环境配置
    c#随机产生颜色
    Git学习
    git删除所有提交历史记录
    git忽略项gitegnore配置
    不搭建git服务器对git仓库进行局域网内共享多人合作开发项目
    搭建Git服务器-SCM-Manager
  • 原文地址:https://www.cnblogs.com/mengdie/p/4581582.html
Copyright © 2020-2023  润新知