[yum-git] repoquery.py yum-utils.spec
James Antill
james at linux.duke.edu
Sun Aug 10 22:05:54 UTC 2008
repoquery.py | 16 +---------------
yum-utils.spec | 2 +-
2 files changed, 2 insertions(+), 16 deletions(-)
New commits:
commit 1639bf5702c0117df9aaae45eac888e493479418
Author: James Antill <james at and.org>
Date: Sun Aug 10 18:03:56 2008 -0400
Use the new setup_locale yum call, and bump the requires version
diff --git a/repoquery.py b/repoquery.py
index 19b93ec..115ff39 100755
--- a/repoquery.py
+++ b/repoquery.py
@@ -844,21 +844,7 @@ def main(args):
repoq.runQuery(regexs)
if __name__ == "__main__":
- import locale
- # This test needs to be before locale.getpreferredencoding() as that
- # does setlocale(LC_CTYPE, "")
- try:
- locale.setlocale(locale.LC_ALL, '')
- except locale.Error, e:
- # default to C locale if we get a failure.
- print >> sys.stderr, 'Failed to set locale, defaulting to C'
- os.environ['LC_ALL'] = 'C'
- locale.setlocale(locale.LC_ALL, 'C')
-
- if True: # not sys.stdout.isatty():
- import codecs
- sys.stdout = codecs.getwriter(locale.getpreferredencoding())(sys.stdout)
- sys.stdout.errors = 'replace'
+ misc.setup_locale()
main(sys.argv)
# vim:sw=4:sts=4:expandtab
diff --git a/yum-utils.spec b/yum-utils.spec
index 6ebde54..c1950cc 100644
--- a/yum-utils.spec
+++ b/yum-utils.spec
@@ -8,7 +8,7 @@ Source: http://linux.duke.edu/yum/download/yum-utils/%{name}-%{version}.tar.gz
URL: http://linux.duke.edu/yum/download/yum-utils/
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch
-Requires: python >= 2.4 , yum >= 3.1.1
+Requires: python >= 2.4 , yum >= 3.2.19
%description
yum-utils is a collection of utilities and examples for the yum package
More information about the Yum-cvs-commits
mailing list