Daniel,<div><br></div><div>In Bash, ** follows symlinks and I have kept this behavior.</div><div>FWIW, nested single * follows symlinks in both Bash and Erlang as well.</div><div><br></div><span style="font-family:arial,sans-serif;font-size:13px;border-collapse:collapse"><b><span style="border-collapse:separate;font-family:arial;font-weight:normal"><div>

<span style="font-family:arial,sans-serif;font-size:13px;border-collapse:collapse"><b>José Valim</b></span></div><div><span style="font-family:arial,sans-serif;font-size:13px;border-collapse:collapse"><div><span style="font-family:verdana,sans-serif;font-size:x-small"><a href="http://www.plataformatec.com.br/" style="color:rgb(42,93,176)" target="_blank">www.plataformatec.com.br</a></span></div>

<div><span style="font-family:verdana,sans-serif;font-size:x-small">Founder and Lead Developer</span></div></span></div></span></b></span><div><br><br><div class="gmail_quote">2012/3/14 Daniel Luna <span dir="ltr"><<a href="mailto:daniel@lunas.se">daniel@lunas.se</a>></span><br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Just a comment, without reading the patch.<br>
<br>
I don't know how this is done in bash, but in zsh there is also ***<br>
expansion.  While ** expands to any level of directories, *** will<br>
also include symbolic links in its expansion.  This is of course<br>
"unsafe" in the sense that symlinked directories outside of the tree<br>
you are working on will be included if there are links to the outside.<br>
 It can also quite easily expand to an infinite size if there are<br>
symlinks that point to any of their ancestors.<br>
<br>
Not yet a suggestion for adding this feature to the patch, but at this<br>
stage only a comment on the caveat of expanding symbolic links.<br>
<br>
/Daniel<br>
<br>
<br>
2012/3/14 José Valim <<a href="mailto:jose.valim@gmail.com">jose.valim@gmail.com</a>>:<br>
<div class="HOEnZb"><div class="h5">> Here is an updated patch for ** support in filelib:wildcard().<br>
><br>
> git fetch git://<a href="http://github.com/josevalim/otp.git" target="_blank">github.com/josevalim/otp.git</a> fixed_double_star<br>
><br>
> <a href="https://github.com/josevalim/otp/compare/fixed_double_star" target="_blank">https://github.com/josevalim/otp/compare/fixed_double_star</a><br>
> <a href="https://github.com/josevalim/otp/compare/fixed_double_star.patch" target="_blank">https://github.com/josevalim/otp/compare/fixed_double_star.patch</a><br>
><br>
> Quoting from bash documentation:<br>
><br>
> Two adjacent *'s used as a single pattern will match all files and zero or<br>
> more directories and subdirectories.<br>
><br>
> I have tested this against Bash 4.2 implementation (previously I was using<br>
> Ruby's implementation as basis). Since I didn't know there was a difference<br>
> between Ruby and Bash, I removed any reference to Ruby in the commit<br>
> message.<br>
><br>
> I have also kept the current filelib:wildcard() behavior of returning files<br>
> that start with dot ".". Bash by default does not return files starting with<br>
> "." in wildcards.<br>
><br>
> I have also improved the test coverage, documentation and added some<br>
> examples.<br>
><br>
</div></div><div class="HOEnZb"><div class="h5">> _______________________________________________<br>
> erlang-patches mailing list<br>
> <a href="mailto:erlang-patches@erlang.org">erlang-patches@erlang.org</a><br>
> <a href="http://erlang.org/mailman/listinfo/erlang-patches" target="_blank">http://erlang.org/mailman/listinfo/erlang-patches</a><br>
><br>
</div></div></blockquote></div><br></div>