[erlang-questions] xref: adding directories dinamically
Oscar Felipe
groovenino@REDACTED
Wed Apr 9 09:58:22 CEST 2014
Hi dear list,
I can successfully import the dependencies I need in my node importing them
manually with -pa as following:
erl -pa ebin deps/*/ebin /path/to/release/*/ebin
Then I start xref and add a release without errors.
Whereas when I start a node and try to add the path in this way :
code:add_patha("ebin"),
Libs = filelib:wildcard("/path/to/release/*/ebin"),
Deps = filelib:wildcard("deps/*/ebin"),
code:add_pathsa(Libs ++ Deps)
This does not work, despite that file:get_cwd() gives the same result as
when I load the libraries manually including the paths with -pa flag.
After that I also tried to add the directories to xref without success:
xref:start(xr),
[xref:add_directory(xr,D) || D <- Libs ++ Deps].
What do I am missing to provide all the paths that xref needs to start?
I really appreciate any help you can provide,
[Oscar]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20140409/fdec41e9/attachment.htm>
More information about the erlang-questions
mailing list