123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115 |
- .\" Man page generated from reStructuredText.
- .
- .
- .nr rst2man-indent-level 0
- .
- .de1 rstReportMargin
- \\$1 \\n[an-margin]
- level \\n[rst2man-indent-level]
- level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
- -
- \\n[rst2man-indent0]
- \\n[rst2man-indent1]
- \\n[rst2man-indent2]
- ..
- .de1 INDENT
- .\" .rstReportMargin pre:
- . RS \\$1
- . nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
- . nr rst2man-indent-level +1
- .\" .rstReportMargin post:
- ..
- .de UNINDENT
- . RE
- .\" indent \\n[an-margin]
- .\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
- .nr rst2man-indent-level -1
- .\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
- .in \\n[rst2man-indent\\n[rst2man-indent-level]]u
- ..
- .TH "BORG-PLACEHOLDERS" "1" "2025-05-22" "" "borg backup tool"
- .SH NAME
- borg-placeholders \- Details regarding placeholders
- .SH DESCRIPTION
- .sp
- Repository URLs, \fB\-\-name\fP, \fB\-a\fP / \fB\-\-match\-archives\fP, \fB\-\-comment\fP
- and \fB\-\-remote\-path\fP values support these placeholders:
- .INDENT 0.0
- .TP
- .B {hostname}
- The (short) hostname of the machine.
- .TP
- .B {fqdn}
- The full name of the machine.
- .TP
- .B {reverse\-fqdn}
- The full name of the machine in reverse domain name notation.
- .TP
- .B {now}
- The current local date and time, by default in ISO\-8601 format.
- You can also supply your own format string <https://docs.python.org/3.9/library/datetime.html#strftime-and-strptime-behavior>
- , e.g. {now:%Y\-%m\-%d_%H:%M:%S}
- .TP
- .B {utcnow}
- The current UTC date and time, by default in ISO\-8601 format.
- You can also supply your own format string <https://docs.python.org/3.9/library/datetime.html#strftime-and-strptime-behavior>
- , e.g. {utcnow:%Y\-%m\-%d_%H:%M:%S}
- .TP
- .B {user}
- The user name (or UID, if no name is available) of the user running borg.
- .TP
- .B {pid}
- The current process ID.
- .TP
- .B {borgversion}
- The version of borg, e.g.: 1.0.8rc1
- .TP
- .B {borgmajor}
- The version of borg, only the major version, e.g.: 1
- .TP
- .B {borgminor}
- The version of borg, only major and minor version, e.g.: 1.0
- .TP
- .B {borgpatch}
- The version of borg, only major, minor and patch version, e.g.: 1.0.8
- .UNINDENT
- .sp
- If literal curly braces need to be used, double them for escaping:
- .INDENT 0.0
- .INDENT 3.5
- .sp
- .EX
- borg create \-\-repo /path/to/repo {{literal_text}}
- .EE
- .UNINDENT
- .UNINDENT
- .sp
- Examples:
- .INDENT 0.0
- .INDENT 3.5
- .sp
- .EX
- borg create \-\-repo /path/to/repo {hostname}\-{user}\-{utcnow} ...
- borg create \-\-repo /path/to/repo {hostname}\-{now:%Y\-%m\-%d_%H:%M:%S%z} ...
- borg prune \-a \(aqsh:{hostname}\-*\(aq ...
- .EE
- .UNINDENT
- .UNINDENT
- .sp
- \fBNOTE:\fP
- .INDENT 0.0
- .INDENT 3.5
- systemd uses a difficult, non\-standard syntax for command lines in unit files (refer to
- the \fIsystemd.unit(5)\fP manual page).
- .sp
- When invoking borg from unit files, pay particular attention to escaping,
- especially when using the now/utcnow placeholders, since systemd performs its own
- %\-based variable replacement even in quoted text. To avoid interference from systemd,
- double all percent signs (\fB{hostname}\-{now:%Y\-%m\-%d_%H:%M:%S}\fP
- becomes \fB{hostname}\-{now:%%Y\-%%m\-%%d_%%H:%%M:%%S}\fP).
- .UNINDENT
- .UNINDENT
- .SH AUTHOR
- The Borg Collective
- .\" Generated by docutils manpage writer.
- .
|