Skip to content

Commit

Permalink
fixup formatting to be python compatible
Browse files Browse the repository at this point in the history
  • Loading branch information
antheas committed Aug 13, 2024
1 parent 94d92d3 commit e46fb40
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/rechunk/fedora.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
STARTSEP = "M2Dqm7H6"
ENDSEP = "7mhjAuF8"


def get_packages(dir: str):
packages = []

Expand All @@ -26,7 +27,10 @@ def get_packages(dir: str):
"rpm",
"-qa",
"--queryformat",
f"{STARTSEP}\n[%{FILESIZES} %{FILENAMES}\n]{ENDSEP}%{NAME} %{NEVRA} %{VERSION} %{RELEASE} %{SIZE}\n",
STARTSEP
+ "\n[%{FILESIZES} %{FILENAMES}\n]"
+ ENDSEP
+ "%{NAME} %{NEVRA} %{VERSION} %{RELEASE} %{SIZE}\n",
"--changes",
"--dbpath",
dir,
Expand All @@ -36,7 +40,7 @@ def get_packages(dir: str):
line = eline.decode("utf-8")

if line.startswith(ENDSEP):
data = line[len(ENDSEP):].split(" ")
data = line[len(ENDSEP) :].split(" ")
name = data[0]
nevra = data[1]
version = data[2]
Expand Down

0 comments on commit e46fb40

Please sign in to comment.