1
0
mirror of https://github.com/SoftEtherVPN/SoftEtherVPN.git synced 2024-11-22 09:29:52 +03:00

version.py: Fix CI failure on macOS by avoiding inline if statement

File "version.py", line 25
    print(version, end = end)
                       ^
SyntaxError: invalid syntax
This commit is contained in:
Davide Beatrici 2021-02-20 16:55:43 +01:00
parent 2981a44de3
commit 63b841efc0

View File

@ -5,7 +5,10 @@ def main():
parser.add_argument('-n', '--newline', action = 'store_true', help = 'Break line after printing version') parser.add_argument('-n', '--newline', action = 'store_true', help = 'Break line after printing version')
args = parser.parse_args() args = parser.parse_args()
end = None if args.newline else '' if args.newline:
end = None
else:
end = ''
version = None version = None
with open('CMakeLists.txt', 'r') as file: with open('CMakeLists.txt', 'r') as file: