diff options
author | Brad King <brad.king@kitware.com> | 2020-07-01 11:00:34 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2020-07-01 11:00:42 (GMT) |
commit | 0ca6bb85755c5db38c5b6a9d6b6e19f85e51a3c5 (patch) | |
tree | 56e33f8055cef66ffde63925bd0ea0f4c1f8cdff /Help/command | |
parent | 208b8a81ce3b61188214819090278e1b3437d609 (diff) | |
parent | bbcff21f716f25649d744553b9085c8e6c0c1a35 (diff) | |
download | CMake-0ca6bb85755c5db38c5b6a9d6b6e19f85e51a3c5.zip CMake-0ca6bb85755c5db38c5b6a9d6b6e19f85e51a3c5.tar.gz CMake-0ca6bb85755c5db38c5b6a9d6b6e19f85e51a3c5.tar.bz2 |
Merge topic 'file-ARCHIVE-files-dirs' into release-3.18
bbcff21f71 file(ARCHIVE*): Collapse FILES and DIRECTORY options
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4955
Diffstat (limited to 'Help/command')
-rw-r--r-- | Help/command/file.rst | 30 |
1 files changed, 16 insertions, 14 deletions
diff --git a/Help/command/file.rst b/Help/command/file.rst index db2e580..c1a2032 100644 --- a/Help/command/file.rst +++ b/Help/command/file.rst @@ -899,15 +899,15 @@ Archiving .. code-block:: cmake file(ARCHIVE_CREATE OUTPUT <archive> - [FILES <files>] - [DIRECTORY <dirs>] + PATHS <paths>... [FORMAT <format>] [COMPRESSION <compression>] [MTIME <mtime>] [VERBOSE]) -Creates the specified ``<archive>`` file with the content of ``<files>`` and -``<dirs>``. +Creates the specified ``<archive>`` file with the files and directories +listed in ``<paths>``. Note that ``<paths>`` must list actual files or +directories, wildcards are not supported. Use the ``FORMAT`` option to specify the archive format. Supported values for ``<format>`` are ``7zip``, ``gnutar``, ``pax``, ``paxr``, ``raw`` and @@ -933,21 +933,23 @@ the ``MTIME`` option. .. code-block:: cmake file(ARCHIVE_EXTRACT INPUT <archive> - [FILES <files>] - [DIRECTORY <dirs>] [DESTINATION <dir>] + [PATTERNS <patterns>...] [LIST_ONLY] [VERBOSE]) -Extracts or lists the content of an archive specified by ``INPUT``. +Extracts or lists the content of the specified ``<archive>``. -The directory where the content of the archive will be extracted can -be specified via ``DESTINATION``. If the directory does not exit, it -will be created. +The directory where the content of the archive will be extracted to can +be specified using the ``DESTINATION`` option. If the directory does not +exist, it will be created. If ``DESTINATION`` is not given, the current +binary directory will be used. -To select which files and directories will be extracted or listed -use ``FILES`` and ``DIRECTORY`` options. +If required, you may select which files and directories to list or extract +from the archive using the specified ``<patterns>``. Wildcards are supported. +If the ``PATTERNS`` option is not given, the entire archive will be listed or +extracted. -``LIST_ONLY`` will only list the files in the archive. +``LIST_ONLY`` will list the files in the archive rather than extract them. -With ``VERBOSE`` the command will produce verbose output. +With ``VERBOSE``, the command will produce verbose output. |