From e7b7748277ee932c25122631aee492fa727e006fc19a449895219e7ca1bc9652 Mon Sep 17 00:00:00 2001 From: Fridrich Strba Date: Wed, 9 Aug 2023 05:54:26 +0000 Subject: [PATCH] OBS-URL: https://build.opensuse.org/package/show/LibreOffice:Factory/libreoffice-share-linker?expand=0&rev=14 --- libreoffice-share-linker.changes | 6 ++++++ libreoffice-share-linker.py | 6 +++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/libreoffice-share-linker.changes b/libreoffice-share-linker.changes index 615a195..3d31402 100644 --- a/libreoffice-share-linker.changes +++ b/libreoffice-share-linker.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Wed Aug 9 05:53:27 UTC 2023 - Fridrich Strba + +- Do not format using f-strings, since it is python 3.6+ feature + and SLE12-SP5 has python 3.4 + ------------------------------------------------------------------- Thu Mar 16 07:30:43 UTC 2023 - Martin Liška diff --git a/libreoffice-share-linker.py b/libreoffice-share-linker.py index c126c76..ac08a14 100644 --- a/libreoffice-share-linker.py +++ b/libreoffice-share-linker.py @@ -52,7 +52,7 @@ for libdir in LIBDIRS: # we have to be sure it is not owned by anything else # doing in 2nd run to ensure avoiding collisions if link.is_dir() and not any(link.iterdir()): - r = subprocess.run(f'rpm -qf {file}', shell=True, + r = subprocess.run("rpm -qf {}".format(file), shell=True, stdout=subprocess.PIPE, stderr=subprocess.DEVNULL) if not r.stdout: link.rmdir() @@ -76,8 +76,8 @@ for libdir in LIBDIRS: if leftover.is_dir() and not any(leftover.iterdir()): leftover.rmdir() - # remove dangling links as they might happen when migratin from older + # remove dangling links as they might happen when migrating from older # libreoffice versions # Run find directly as it's faster than os.walk run and a os.path.islink! - subprocess.run(f'find {str(lodir)} -type l -xtype l -delete', + subprocess.run("find {} -type l -xtype l -delete".format(str(lodir)), shell=True, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL)