USR_BIN := \
proxmox-backup-client \
pxar \
- pmtx
+ pmtx \
+ pmt
# Binaries usable by admins
USR_SBIN := \
--- /dev/null
+# pmt bash completion
+
+complete -C 'pmt bashcomplete' pmt
debian/proxmox-backup-manager.bc proxmox-backup-manager
debian/pmtx.bc pmtx
+debian/pmt.bc pmt
usr/lib/x86_64-linux-gnu/proxmox-backup/sg-tape-cmd
usr/sbin/proxmox-backup-manager
usr/bin/pmtx
+usr/bin/pmt
usr/share/javascript/proxmox-backup/index.hbs
usr/share/javascript/proxmox-backup/css/ext6-pbs.css
usr/share/javascript/proxmox-backup/images
usr/share/man/man1/proxmox-backup-manager.1
usr/share/man/man1/proxmox-backup-proxy.1
usr/share/man/man1/pmtx.1
+usr/share/man/man1/pmt.1
usr/share/zsh/vendor-completions/_proxmox-backup-manager
usr/share/zsh/vendor-completions/_pmtx
+usr/share/zsh/vendor-completions/_pmt
proxmox-backup-manager/synopsis.rst \
pxar/synopsis.rst \
pmtx/synopsis.rst \
+ pmt/synopsis.rst \
backup-protocol-api.rst \
reader-protocol-api.rst
MANUAL_PAGES := \
pxar.1 \
pmtx.1 \
+ pmt.1 \
proxmox-backup-proxy.1 \
proxmox-backup-client.1 \
proxmox-backup-manager.1
rst2man $< >$@
+pmt/synopsis.rst: ${COMPILEDIR}/pmt
+ ${COMPILEDIR}/pmt printdoc > pmt/synopsis.rst
+
+pmt.1: pmt/man1.rst pmt/description.rst pmt/synopsis.rst
+ rst2man $< >$@
+
+
proxmox-backup-client/synopsis.rst: ${COMPILEDIR}/proxmox-backup-client
${COMPILEDIR}/proxmox-backup-client printdoc > proxmox-backup-client/synopsis.rst
--- /dev/null
+Description
+^^^^^^^^^^^
+
+The ``pmt`` command controls Linux tape devices.
+
--- /dev/null
+==========================
+pmt
+==========================
+
+.. include:: ../epilog.rst
+
+-------------------------------------------------------------
+Control Linux Tape Devices
+-------------------------------------------------------------
+
+:Author: |AUTHOR|
+:Version: Version |VERSION|
+:Manual section: 1
+
+
+Synopsis
+========
+
+.. include:: synopsis.rst
+
+
+Common Options
+==============
+
+All command supports the following parameters to specify the tape device:
+
+--device <path> Path to the Linux tape device
+
+--drive <name> Use drive from Proxmox Backup Server configuration.
+
+
+Commands generation output supports the ``--output-format`` parameter. It accepts
+the following values:
+
+:``text``: Text format (default). Human readable.
+
+:``json``: JSON (single line).
+
+:``json-pretty``: JSON (multiple lines, nicely formatted).
+
+
+Description
+===========
+
+.. include:: description.rst
+
+
+.. include:: ../pbs-copyright.rst
};
let cmd_def = CliCommandMap::new()
+ .usage_skip_options(&["device", "drive", "output-format"])
.insert("asf", std_cmd(&API_METHOD_ASF).arg_param(&["count"]))
.insert("bsf", std_cmd(&API_METHOD_BSF).arg_param(&["count"]))
.insert("bsfm", std_cmd(&API_METHOD_BSFM).arg_param(&["count"]))
--- /dev/null
+#compdef _pmt() pmt
+
+function _pmt() {
+ local cwords line point cmd curr prev
+ cworkds=${#words[@]}
+ line=$words
+ point=${#line}
+ cmd=${words[1]}
+ curr=${words[cwords]}
+ prev=${words[cwords-1]}
+ compadd -- $(COMP_CWORD="$cwords" COMP_LINE="$line" COMP_POINT="$point" \
+ pmt bashcomplete "$cmd" "$curr" "$prev")
+}