@@ -55,7 +55,7 @@ def execute(command: list[str], ignore: bool = False, log: bool = False, dry_run
5555 :return: command output
5656 """
5757 if log or dry_run :
58- print ("{}execute: {}" . format ( " would " if dry_run else "" , " " .join (quote (c ) for c in command )) )
58+ print (f" { ' would ' if dry_run else '' } execute: { ' ' .join (quote (c ) for c in command )} " )
5959 if dry_run :
6060 return ""
6161 env = os .environ .copy ()
@@ -254,7 +254,7 @@ def input_new_version(current: Version) -> Version:
254254 try :
255255 new_version = Version (new_version_str )
256256 except InvalidVersion as ex :
257- print ("{ }; Should be PEP 440-compatible (for instance in the form: 1.2.3)". format ( ex ) )
257+ print (f" { ex } ; Should be PEP 440-compatible (for instance in the form: 1.2.3)" )
258258 else :
259259 new_version = default_new_version
260260 return new_version
@@ -325,10 +325,11 @@ def main():
325325 release_tag (new_version , changes , dry_run )
326326
327327 # push package to pypi
328- step ("Generate and push package to {}" . format ( args .repository or args .repository_url or " pypi" ) )
329- execute (["python" , "-m" , "build" , "--wheel" ], log = True )
328+ step (f "Generate and push package to { args .repository or args .repository_url or ' pypi' } " )
329+ execute (["python" , "-m" , "build" ], log = True )
330330 wheel = f"dist/simpleflow-{ new_version } -py3-none-any.whl"
331- cmd = ["twine" , "upload" , wheel ]
331+ tar_gz = f"dist/simpleflow-{ new_version } .tar.gz"
332+ cmd = ["twine" , "upload" , wheel , tar_gz ]
332333 if args .repository :
333334 cmd += ["--repository" , args .repository ]
334335 elif args .repository_url :
0 commit comments