[libvirt] [PATCH] doc: fix typo in virsh.pod

--- tools/virsh.pod | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/virsh.pod b/tools/virsh.pod index 5932aaa..f677383 100644 --- a/tools/virsh.pod +++ b/tools/virsh.pod @@ -301,7 +301,7 @@ L<http://libvirt.org/formatdomain.html#elementsCPU> The following commands manipulate domains directly, as stated previously most commands take domain-id as the first parameter. The -I<domain-id> can be specified as an short integer, a name or a full UUID. +I<domain-id> can be specified as a short integer, a name or a full UUID. =over 4 @@ -326,7 +326,7 @@ If I<--console> is requested, attach to the console after creation. B<Example> virsh dumpxml <domain-id> > domain.xml - edit domain.xml + virsh edit domain.xml virsh create < domain.xml =item B<define> I<FILE> -- 1.7.2.3

On 11/02/2010 04:18 AM, Osier Yang wrote:
--- tools/virsh.pod | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/tools/virsh.pod b/tools/virsh.pod index 5932aaa..f677383 100644 --- a/tools/virsh.pod +++ b/tools/virsh.pod @@ -301,7 +301,7 @@ L<http://libvirt.org/formatdomain.html#elementsCPU>
The following commands manipulate domains directly, as stated previously most commands take domain-id as the first parameter. The -I<domain-id> can be specified as an short integer, a name or a full UUID. +I<domain-id> can be specified as a short integer, a name or a full UUID.
=over 4
@@ -326,7 +326,7 @@ If I<--console> is requested, attach to the console after creation. B<Example>
virsh dumpxml <domain-id> > domain.xml - edit domain.xml + virsh edit domain.xml virsh create < domain.xml
NACK. The whole point is that you are using your external editor here; that is: virsh edit dom is shorthand for: virsh dumpxml dom > domain.xml $EDITOR domain.xml virsh create < domain.xml rm domain.xml However, a patch that changes 'edit' to $EDITOR would be welcome (and there's more than one instance that needs fixing; for example, see also net-edit). -- Eric Blake eblake@redhat.com +1-801-349-2682 Libvirt virtualization library http://libvirt.org

于 2010年11月03日 00:01, Eric Blake 写道:
On 11/02/2010 04:18 AM, Osier Yang wrote:
--- tools/virsh.pod | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/tools/virsh.pod b/tools/virsh.pod index 5932aaa..f677383 100644 --- a/tools/virsh.pod +++ b/tools/virsh.pod @@ -301,7 +301,7 @@ L<http://libvirt.org/formatdomain.html#elementsCPU>
The following commands manipulate domains directly, as stated previously most commands take domain-id as the first parameter. The -I<domain-id> can be specified as an short integer, a name or a full UUID. +I<domain-id> can be specified as a short integer, a name or a full UUID.
=over 4
@@ -326,7 +326,7 @@ If I<--console> is requested, attach to the console after creation. B<Example>
virsh dumpxml<domain-id> > domain.xml - edit domain.xml + virsh edit domain.xml virsh create< domain.xml
NACK. The whole point is that you are using your external editor here; that is:
urgh, didn't check it carefully, trusted QE. :-)
virsh edit dom
is shorthand for:
virsh dumpxml dom> domain.xml $EDITOR domain.xml virsh create< domain.xml rm domain.xml
However, a patch that changes 'edit' to $EDITOR would be welcome (and there's more than one instance that needs fixing; for example, see also net-edit).
however, this sentence is to tell editing the domain.xml, but not using "virsh *-edit", so $EDITOR will be meaningless here somehow. I could use whatever I like to edit it, right? :-) how about just to change it into: - % virsh dumpxml dom > domain.xml - edit domain.xml - % virsh create < domain.xml - Osier

On 03/11/2010, at 2:17 PM, Osier Yang <jyang@redhat.com> wrote:
how about just to change it into:
- % virsh dumpxml dom > domain.xml - edit domain.xml - % virsh create < domain.xml
It's a thought, but still isn't making it completely clear. If we were to change it like this: virsh dumpxml dom > domain.xml vi domain.XML (make changes to the XML using your text editor) virsh create < domain.xml That would probably work. The "vi" here is only useful because people will recognize it easily. We could put in any other editor name too, say "nano" or "gedit" or "emacs". "$EDITOR" isn't as obvious unfortunately. :/

On Tue, Nov 02, 2010 at 11:34:39PM -0400, jclift@redhat.com wrote:
On 03/11/2010, at 2:17 PM, Osier Yang <jyang@redhat.com> wrote:
how about just to change it into:
- % virsh dumpxml dom > domain.xml - edit domain.xml - % virsh create < domain.xml
It's a thought, but still isn't making it completely clear.
If we were to change it like this:
virsh dumpxml dom > domain.xml vi domain.XML (make changes to the XML using your text editor) virsh create < domain.xml
That would probably work. The "vi" here is only useful because people will recognize it easily. We could put in any other editor name too, say "nano" or "gedit" or "emacs". "$EDITOR" isn't as obvious unfortunately. :/
That's clear, fine by me, ACK Daniel -- Daniel Veillard | libxml Gnome XML XSLT toolkit http://xmlsoft.org/ daniel@veillard.com | Rpmfind RPM search engine http://rpmfind.net/ http://veillard.com/ | virtualization library http://libvirt.org/

On 11/02/2010 09:34 PM, jclift@redhat.com wrote:
On 03/11/2010, at 2:17 PM, Osier Yang <jyang@redhat.com> wrote:
how about just to change it into:
- % virsh dumpxml dom > domain.xml - edit domain.xml - % virsh create < domain.xml
It's a thought, but still isn't making it completely clear.
If we were to change it like this:
virsh dumpxml dom > domain.xml vi domain.XML (make changes to the XML using your text editor) virsh create < domain.xml
Or maybe: virsh dumpxml dom > domain.xml vi domain.XML # or other text editor of your choice virsh create < domain.xml
That would probably work. The "vi" here is only useful because people will recognize it easily.
That, and vi is the only editor required by POSIX, unless you count ed (rms explicitly requested that emacs not be part of POSIX, and nano, gedit, kate, and so forth are all relative whippersnappers in the editor market). But whatever you do, please don't change it to 'notepad.exe domain.xml' :) -- Eric Blake eblake@redhat.com +1-801-349-2682 Libvirt virtualization library http://libvirt.org

On 11/04/2010 01:42 AM, Eric Blake wrote: <snip>
If we were to change it like this:
virsh dumpxml dom > domain.xml vi domain.XML (make changes to the XML using your text editor) virsh create < domain.xml
Can we keep the explicit meta "perform this action" step? Something like: (make changes to the XML using your text editor) <change the XML with your text editor> It's that little bit clearer and easier for the unfamiliar. :)

于 2010年11月03日 22:42, Eric Blake 写道:
On 11/02/2010 09:34 PM, jclift@redhat.com wrote:
On 03/11/2010, at 2:17 PM, Osier Yang<jyang@redhat.com> wrote:
how about just to change it into:
- % virsh dumpxml dom> domain.xml - edit domain.xml - % virsh create< domain.xml
It's a thought, but still isn't making it completely clear.
If we were to change it like this:
virsh dumpxml dom> domain.xml vi domain.XML (make changes to the XML using your text editor) virsh create< domain.xml
Or maybe:
virsh dumpxml dom> domain.xml vi domain.XML # or other text editor of your choice virsh create< domain.xml
I prefer this one, but not sure if '#' is fine for non-programmer.
That would probably work. The "vi" here is only useful because people will recognize it easily.
That, and vi is the only editor required by POSIX, unless you count ed (rms explicitly requested that emacs not be part of POSIX, and nano, gedit, kate, and so forth are all relative whippersnappers in the editor market). But whatever you do, please don't change it to 'notepad.exe domain.xml' :)
urgh, never.. :-) - Osier
participants (5)
-
Daniel Veillard
-
Eric Blake
-
jclift@redhat.com
-
Justin Clift
-
Osier Yang