mirror of
https://github.com/stronk-dev/Guitar-Sheet-Parser.git
synced 2025-07-05 00:25:08 +02:00
Fix trailing whiteline added after metadata
This commit is contained in:
parent
a69606ee4c
commit
72b8a1ab3d
@ -47,13 +47,12 @@ def outputToTxt(folderLocation, printRaw, songObj):
|
||||
|
||||
lineCounter = 0
|
||||
# Write metadata
|
||||
for line in songObj.metadata.split('\n'):
|
||||
for line in songObj.metadata.splitlines(True):
|
||||
# remove any unwanted characters from metadata
|
||||
line = line.rstrip()
|
||||
if not songObj.keepEmptyLines and not line:
|
||||
continue
|
||||
#print("meta line '{}'".format(line))
|
||||
output += line + '\r\n'
|
||||
output += line
|
||||
metadataLines.append(lineCounter)
|
||||
lineCounter += 1
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user