Skip to content

Conversation

@matthias11-21
Copy link

Format everything of the applications instead of just formatting the source directory. This will include formatting of include and test directories.

@tsloughter
Copy link
Owner

Won't this end up going into _build too? It should use the src_dirs and extra_src_dirs lists of configured directories plus the test directory.

If working with an application (instead of a release) the
modification would format files in _build, too.  Prevent
that by formatting the directories src, test, and include
explicitly.

Using rebar3_dir:all_src_dirs/1 is way more trickier as
this function reads the values from the rebar configuration
which does not include sane defaults or is dependent on
profiles.  We just want to format everything.
@matthias11-21
Copy link
Author

After looking at what it needs to use rebar_dir and src_dirs I went the much simpler route mimicking the original approach. Just format src, include, and test. I don't want to format depending on target anyway. I want to format every Erlang source file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants