Skip to content

Commit

Permalink
Merge pull request #6 from sleipnir/fix/use-tmp-instead-of-build-path
Browse files Browse the repository at this point in the history
Use temporary directory instead of build_path
  • Loading branch information
drowzy authored Jul 4, 2024
2 parents 116bdad + 5cf4747 commit 671e6cf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/protobuf_generate/protoc.ex
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ defmodule ProtobufGenerate.Protoc do

defp run_protoc(proto_files, args) do
outfile_name = "protobuf_#{random_string()}"
outfile_path = Path.join([Mix.Project.build_path(), outfile_name])
outfile_path = Path.join([System.tmp_dir!(), outfile_name])

cmd_args =
["--include_imports", "--include_source_info", "-o", outfile_path] ++ args ++ proto_files
Expand Down

0 comments on commit 671e6cf

Please sign in to comment.