diff mbox

Add manpage for QEMU Backup Tool

Message ID 1496957498-17127-1-git-send-email-chugh.ishani@research.iiit.ac.in
State New
Headers show

Commit Message

Ishani June 8, 2017, 9:31 p.m. UTC
Signed-off-by: Ishani Chugh <chugh.ishani@research.iiit.ac.in>
---
 Makefile                        |   2 +-
 contrib/backup/qemu-backup.texi | 147 ++++++++++++++++++++++++++++++++++++++++
 2 files changed, 148 insertions(+), 1 deletion(-)
 create mode 100644 contrib/backup/qemu-backup.texi

Comments

no-reply@patchew.org June 9, 2017, 2:29 a.m. UTC | #1
Hi,

This series seems to have some coding style problems. See output below for
more information:

Subject: [Qemu-devel] [PATCH] Add manpage for QEMU Backup Tool
Message-id: 1496957498-17127-1-git-send-email-chugh.ishani@research.iiit.ac.in
Type: series

=== TEST SCRIPT BEGIN ===
#!/bin/bash

BASE=base
n=1
total=$(git log --oneline $BASE.. | wc -l)
failed=0

git config --local diff.renamelimit 0
git config --local diff.renames True

commits="$(git log --format=%H --reverse $BASE..)"
for c in $commits; do
    echo "Checking PATCH $n/$total: $(git log -n 1 --format=%s $c)..."
    if ! git show $c --format=email | ./scripts/checkpatch.pl --mailback -; then
        failed=1
        echo
    fi
    n=$((n+1))
done

exit $failed
=== TEST SCRIPT END ===

Updating 3c8cf5a9c21ff8782164d1def7f44bd888713384
Switched to a new branch 'test'
71c5bbc Add manpage for QEMU Backup Tool

=== OUTPUT BEGIN ===
Checking PATCH 1/1: Add manpage for QEMU Backup Tool...
ERROR: trailing whitespace
#28: FILE: contrib/backup/qemu-backup.texi:1:
+                   $

ERROR: trailing whitespace
#29: FILE: contrib/backup/qemu-backup.texi:2:
+ $

ERROR: trailing whitespace
#117: FILE: contrib/backup/qemu-backup.texi:90:
+ $

ERROR: trailing whitespace
#120: FILE: contrib/backup/qemu-backup.texi:93:
+ $

ERROR: trailing whitespace
#128: FILE: contrib/backup/qemu-backup.texi:101:
+ $

ERROR: trailing whitespace
#132: FILE: contrib/backup/qemu-backup.texi:105:
+ $

ERROR: trailing whitespace
#134: FILE: contrib/backup/qemu-backup.texi:107:
+ $

ERROR: trailing whitespace
#137: FILE: contrib/backup/qemu-backup.texi:110:
+ $

ERROR: trailing whitespace
#143: FILE: contrib/backup/qemu-backup.texi:116:
+ $

ERROR: trailing whitespace
#147: FILE: contrib/backup/qemu-backup.texi:120:
+ $

ERROR: trailing whitespace
#151: FILE: contrib/backup/qemu-backup.texi:124:
+ $

ERROR: trailing whitespace
#155: FILE: contrib/backup/qemu-backup.texi:128:
+ $

ERROR: trailing whitespace
#161: FILE: contrib/backup/qemu-backup.texi:134:
+ $

ERROR: trailing whitespace
#163: FILE: contrib/backup/qemu-backup.texi:136:
+ $

ERROR: trailing whitespace
#166: FILE: contrib/backup/qemu-backup.texi:139:
+ $

ERROR: trailing whitespace
#168: FILE: contrib/backup/qemu-backup.texi:141:
+ $

ERROR: trailing whitespace
#173: FILE: contrib/backup/qemu-backup.texi:146:
+ $

total: 17 errors, 0 warnings, 155 lines checked

Your patch has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

=== OUTPUT END ===

Test command exited with code: 1


---
Email generated automatically by Patchew [http://patchew.org/].
Please send your feedback to patchew-devel@freelists.org
Stefan Hajnoczi June 9, 2017, 8:33 a.m. UTC | #2
On Thu, Jun 08, 2017 at 07:29:55PM -0700, no-reply@patchew.org wrote:
> === OUTPUT BEGIN ===
> Checking PATCH 1/1: Add manpage for QEMU Backup Tool...
> ERROR: trailing whitespace
> #28: FILE: contrib/backup/qemu-backup.texi:1:
> +                   $

Hi Ishani,
In case you are wondering about these errors - please send a new
revision (v2) of this patch with the whitespace issues fixed.

Here are a few Vim tips but I'm sure you can do the same in Emacs or
other editors:

1. Add the following to your .vimrc to highlight trailing whitespace:

   hi WhiteSpaceEOL ctermbg=red guibg=red
   au InsertEnter * match WhiteSpaceEOL /\s\+\%#\@<!$/
   au InsertLeave * match WhiteSpaceEOL /\s\+$/

2. Use this search-and-replace command to get rid of trailing
   whitespace:

   :%s/\s\+$//g

I recommend running scripts/checkpatch.pl yourself before submitting
patches.  You can do it automatically from a git hook (see githooks(5))
by following the instructions here:

http://blog.vmsplice.net/2011/03/how-to-automatically-run-checkpatchpl.html

Stefan
diff mbox

Patch

diff --git a/Makefile b/Makefile
index c830d7a..f42cb1d 100644
--- a/Makefile
+++ b/Makefile
@@ -504,7 +504,7 @@  clean:
 VERSION ?= $(shell cat VERSION)
 
 dist: qemu-$(VERSION).tar.bz2
-
+qemu-backup.8: contrib/qemu-backup/qemu-backup.texi
 qemu-%.tar.bz2:
 	$(SRC_PATH)/scripts/make-release "$(SRC_PATH)" "$(patsubst qemu-%.tar.bz2,%,$@)"
 
diff --git a/contrib/backup/qemu-backup.texi b/contrib/backup/qemu-backup.texi
new file mode 100644
index 0000000..41e2b16
--- /dev/null
+++ b/contrib/backup/qemu-backup.texi
@@ -0,0 +1,147 @@ 
+                   
+ 
+@setfilename qemu-backup-tool-manpage
+
+@documentlanguage en
+@documentencoding UTF-8
+
+\input texinfo
+@settitle Manpage_backup_tool 1.0
+@copying
+This is a manpage for qemu_backup_tool, version 1.0.
+
+Copyright @copyright{} 2016 Free Software Foundation, Inc.
+@end copying
+@ifinfo
+@direntry
+* QEMU: (qemu-backup-tool-manpage).    Man page for QEMU backup tool.
+@end direntry
+@end ifinfo
+@iftex
+@titlepage
+@sp 7
+@center @titlefont{QEMU_backup_tool}
+@sp 1
+@center @titlefont{Man Page}
+@sp 3
+@end titlepage
+@end iftex
+@ifnottex
+@node Top
+@top Short Sample
+
+@menu
+* Name::
+* Synopsis::
+* list of Commands::
+* Command Parameters::
+* Command Descriptions::
+* License::
+@end menu
+
+@end ifnottex
+
+@node Name
+@chapter Name
+
+QEMU disk backup tool.
+
+@node Synopsis
+@chapter Synopsis
+
+
+qemu-backup command [ command options].
+
+@node  list of Commands
+@chapter  list of Commands
+@cindex chapter, first dummy
+@itemize
+@item qemu-backup guest add [--id id] [--qmp socketpath]
+@item qemu-backup guest list
+@item qemu-backup drive add [--guest guestname] [--id driveid] [--target target]
+@item qemu-backup drive list [--guest guestname]
+@item qemu-backup backup [--guest guestname]
+@item qemu-backup restore [--guest guestname]
+@item qemu-backup drive-remove [--guest guestname] [--id driveid]
+@item qemu-backup remove [--guest guestname]
+@item qemu-backup drive add [--all] [--guest guestname] [--target target]
+@item qemu-backup backup [--inc] [--guest guestname]
+@end itemize
+@node  Command Parameters
+@chapter  Command Parameters
+@cindex chapter, first dummy
+@itemize
+@item --guest: Name of the guest.
+@item --id: id of guest or drive.
+@item --target: Destination on which you want your backup to be made.
+@item --all: Add all the drives present in a guest for backup except cd-rom.
+@item --inc: For incremental backup.
+@item --qmp: Path of qmp socket.
+@end itemize
+
+@node  Command Descriptions
+@chapter  Command Descriptions
+@cindex chapter, first dummy
+@itemize
+@item qemu-backup guest add [--id id] [--qmp socketpath]
+This command adds a guest to the configuration file given its path to qmp socket.
+example:
+qemu-backup guest add --id=fedora –qmp=/var/run/qemu/fedora.sock
+ 
+@item qemu-backup guest list
+This commands lists the names of guests which are added to configuration file.
+ 
+@item qemu-backup drive add [--guest guestname] [--id driveid] [--target target]
+This command adds different drives for backup in a particular guest by giving the name of drive to be backed up and target imagefile in which we want to store the drive backup.
+example:
+qemu-backup drive add --guest=fedora --id=root
+--target=/backup/fedora/root.img
+qemu-backup drive add --guest=fedora --id=data
+--target=/backup/fedora/data.img
+ 
+@item qemu-backup drive list [--guest guestname]
+This commands gives the names of the drive present in a guest which are added for backup.
+example: qemu-backup drive list --guest=fedora
+ 
+@item qemu-backup backup [--guest guestname]
+ 
+This command makes the backup of the drives, in their respective given destinations. The ids of drive and their destinations are taken from the configuration file.
+example: qemu-backup backup --guest=fedora
+ 
+@item qemu-backup restore [--guest guestname]
+This command is needed if we want to restore the backup. It will list the commands to be run for performing the same but will not perform any action.
+example: qemu-backup restore --guest=fedora
+cp /backup/fedora/root.img /var/run/qemu/fedora/root.img
+cp /backup/fedora/data.img /var/run/qemu/fedora/data.img
+ 
+@item qemu-backup drive-remove [--guest guestname] [--id driveid]
+This command helps remove a drive which is set for backup in configuration of given host.
+example: qemu-backup remove --guest=fedora --id=root
+ 
+@item qemu-backup remove [--guest guestname]
+This command removes the guest from the configuration file.
+example: qemu-backup remove –guest=fedora
+ 
+@item qemu-backup drive add --all [-guest guestname] [-destination destination]
+This command adds all the drives of the guest for backup other than CDROM drive. Here all the backup drives will have the same names as original drives and target will be the destination folder.
+example: qemu-backup drive add --all --guest fedora --destination =/backup/fedora/
+ 
+@end itemize
+
+
+@node License
+@appendix License
+ 
+QEMU is a trademark of Fabrice Bellard.
+ 
+QEMU is released under the GNU General Public License (TODO: add link).
+Parts of QEMU have specific licenses, see file LICENSE.
+ 
+TODO (refer to file LICENSE, include it, include the GPL?)
+ 
+
+@bye
+
+
+ 
+