Skip to content

Commit

Permalink
[antmicro#3] Fix usage of temporary file on windows
Browse files Browse the repository at this point in the history
  • Loading branch information
CrustyAuklet authored Jun 28, 2023
1 parent 01ff560 commit 7445b00
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion renode_run/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -281,9 +281,10 @@ def demo_command(args):

script = generate_script(args.binary, args.board, args.generate_repl)

with tempfile.NamedTemporaryFile() as temp:
with tempfile.NamedTemporaryFile(delete=False) as temp:
temp.write(script.encode("utf-8"))
temp.flush()
temp.close()
ret = subprocess.run([renode_path, temp.name] + args.renode_arguments)
sys.exit(ret.returncode)

Expand Down

0 comments on commit 7445b00

Please sign in to comment.