From: Guillaume Rousse <Guillaume.Rousse@inria.fr>
To: xen-devel@lists.xensource.com
Subject: Re: [PATCH] yet another package check
Date: Thu, 14 Dec 2006 15:27:28 +0100 [thread overview]
Message-ID: <45815F50.6030101@inria.fr> (raw)
In-Reply-To: <200612141522.15699.Christoph.Egger@amd.com>
Christoph Egger wrote:
> Why do you write non-portable shell scripts?
>
> Some time ago, I made these portable:
>
> check_brctl
> check_iproute
> check_libvncserver
> check_python
I don't know if this one has been rewritten since stable version, but
here is a patch I recently submited to the user list, to rely on python
instead of ugly grep:
diff -Naur xen-3.0.3_0-src/tools/check/check_python
xen-3.0.3_0-src.better-python-check/tools/check/check_python
--- xen-3.0.3_0-src/tools/check/check_python 2006-10-15
14:22:03.000000000 +0200
+++ xen-3.0.3_0-src.better-python-check/tools/check/check_python
2006-12-11 16:26:01.000000000 +0100
@@ -7,4 +7,4 @@
exit 1
}
-python -V 2>&1 | cut -d ' ' -f 2 | grep -q '^2.[2345]' || error
+python -c 'import sys; sys.exit(sys.version_info[0] < 2 or
sys.version_info[1] < 2);' || error
next prev parent reply other threads:[~2006-12-14 14:27 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-12-14 14:06 [PATCH] yet another package check Jan Beulich
2006-12-14 14:22 ` Christoph Egger
2006-12-14 14:27 ` Guillaume Rousse [this message]
2006-12-14 14:32 ` Christoph Egger
2006-12-14 15:23 ` Jan Beulich
2006-12-14 17:38 ` Brendan Cully
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=45815F50.6030101@inria.fr \
--to=guillaume.rousse@inria.fr \
--cc=xen-devel@lists.xensource.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.