]> git.pld-linux.org Git - packages/librsvg.git/commitdiff
- really ported rsvg script to python3; release 2 master auto/th/librsvg-2.58.0-2
authorJakub Bogusz <qboosh@pld-linux.org>
Wed, 17 Apr 2024 17:36:55 +0000 (19:36 +0200)
committerJakub Bogusz <qboosh@pld-linux.org>
Wed, 17 Apr 2024 17:36:55 +0000 (19:36 +0200)
librsvg.spec
rsvg

index e216a57f456ad557ba70a1dd40a90b8af4d86506..bc1daae5ed6f446cf87392c8ec48115047745530 100644 (file)
@@ -13,7 +13,7 @@ Summary(ru.UTF-8):    SVG библиотека
 Summary(uk.UTF-8):     SVG бібліотека
 Name:          librsvg
 Version:       2.58.0
-Release:       1
+Release:       2
 Epoch:         1
 License:       LGPL v2+
 Group:         X11/Libraries
diff --git a/rsvg b/rsvg
index 437e86ce25c38d49d020c983e4124993eedc6efd..c4349f96e4ef23cc1c2ec586b6b658cbd3343f48 100755 (executable)
--- a/rsvg
+++ b/rsvg
@@ -8,13 +8,13 @@
 import getopt, sys, os
 
 def usage():
-    print >> sys.stdout, """Usage: rsvg [-v?] [-d|--dpi-x <float>] [-p|--dpi-y <float>]
+    print("""Usage: rsvg [-v?] [-d|--dpi-x <float>] [-p|--dpi-y <float>]
         [-x|--x-zoom <float>] [-y|--y-zoom <float>] [-w|--width <int>]
         [-h|--height <int>] [-q|--quality <int>] [-f|--format [png, jpeg]]
-        [-v|--version] [-?|--help] [--usage] [OPTIONS...] file.svg file.png"""
+        [-v|--version] [-?|--help] [--usage] [OPTIONS...] file.svg file.png""")
 
 def help():
-    print >> sys.stdout, """Usage: rsvg [OPTIONS...] file.svg file.png
+    print("""Usage: rsvg [OPTIONS...] file.svg file.png
   -d, --dpi-x=<float>          pixels per inch
   -p, --dpi-y=<float>          pixels per inch
   -x, --x-zoom=<float>         x zoom factor
@@ -27,8 +27,7 @@ def help():
 
 Help options:
   -?, --help                   Show this help message
-  --usage                      Display brief usage message
-""",
+  --usage                      Display brief usage message""")
 
 def shellEscape(param):
     """Escape a string parameter for the shell."""
@@ -45,7 +44,7 @@ def main():
 
     for o, a in opts:
         if o in ("-v", "--version"):
-            print "rsvg version %s" % ("2.34.2")
+            print("rsvg version %s" % ("2.34.2"))
             sys.exit(0)
         elif o in ("--usage"):
             usage()
@@ -55,10 +54,10 @@ def main():
             sys.exit(0)
         elif (o in ("-f", "--format")):
             if a in ("jpg", "jpeg"):
-                print >> sys.stderr, "The JPEG output format is no longer supported"
+                print("The JPEG output format is no longer supported", file=sys.stderr)
                 sys.exit(1)
         elif (o in ("-q", "--quality")):
-            print "The --quality option is no longer supported"
+            print("The --quality option is no longer supported")
             sys.exit(1)
         else:
             command_str += " " + shellEscape(o) + " " + shellEscape(a)
This page took 0.284452 seconds and 4 git commands to generate.