Skip to content

Commit

Permalink
Expand output path when generating files
Browse files Browse the repository at this point in the history
  • Loading branch information
ahamez committed Jan 17, 2021
1 parent f55eeb7 commit 0dfd686
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
* x.x.x
- Allow namespaces through protox.generate (thanks to https://github.com/sdrew)
- Expand output path when generating files

* 1.2.4
- Fix warning when compiling generated code (thanks to https://github.com/xinz)
Expand Down
8 changes: 7 additions & 1 deletion lib/mix/tasks/protox/generate.ex
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,13 @@ defmodule Mix.Tasks.Protox.Generate do
{multiple_files, opts} = Keyword.pop(opts, :multiple_files, false)

files
|> Protox.generate_module_code(output_path, multiple_files, include_path, namespace, opts)
|> Protox.generate_module_code(
Path.expand(output_path),
multiple_files,
include_path,
namespace,
opts
)
|> Enum.each(&generate_file/1)
else
err ->
Expand Down

0 comments on commit 0dfd686

Please sign in to comment.