snapshot: document --export and --import options

See: https://trac.macports.org/ticket/72628
(cherry picked from commit d9a94cc142)
This commit is contained in:
Joshua Root
2025-06-23 15:30:47 +10:00
parent 2bd23e458a
commit d85b76c294
2 changed files with 22 additions and 0 deletions
+13
View File
@@ -28,6 +28,7 @@ port-snapshot \- Manage snapshots of installed ports\&.
[\-\-create [\-\-note <note>]]
[\-\-list] [\-\-diff \fIsnapshot\-id\fR [\-\-all]]
[\-\-delete \fIsnapshot\-id\fR] [\-\-help]
[\-\-export \fIsnapshot\-id\fR] [\-\-import \fIfilename\fR]
.fi
.SH "DESCRIPTION"
.sp
@@ -64,6 +65,18 @@ Consider all ports when displaying diffs\&. By default, only differences in requ
Delete the snapshot with the given ID number\&.
.RE
.PP
\fB\-\-export ID\fR
.RS 4
Generate a JSON representation of the snapshot with the given ID number and print it to stdout\&.
.RE
.PP
\fB\-\-import <filename>\fR
.RS 4
Create a new snapshot from the information in the given file, which should contain JSON as generated by the
\fB\-\-export\fR
option\&.
.RE
.PP
\fB\-\-help\fR
.RS 4
Display brief usage information\&.
+9
View File
@@ -13,6 +13,7 @@ SYNOPSIS
[--create [--note <note>]]
[--list] [--diff 'snapshot-id' [--all]]
[--delete 'snapshot-id'] [--help]
[--export 'snapshot-id'] [--import 'filename']
DESCRIPTION
-----------
@@ -45,6 +46,14 @@ differences in requested ports are shown.
*--delete ID*::
Delete the snapshot with the given ID number.
*--export ID*::
Generate a JSON representation of the snapshot with the given ID number
and print it to stdout.
*--import <filename>*::
Create a new snapshot from the information in the given file, which
should contain JSON as generated by the *--export* option.
*--help*::
Display brief usage information.