PS. Welcome aboard :) You can join us in IRC in the #forge channel if you wish!<br><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Nov 19, 2012 at 10:34 AM, Lincoln Baxter, III <span dir="ltr">&lt;<a href="mailto:lincolnbaxter@gmail.com" target="_blank">lincolnbaxter@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hey Adolfo! <br><br>This is great. I think that in order to resolve this, you&#39;ll probably need to implement your own directory handling in your ZipResource, similar to JavaResource and others using the Resource API to return virtual entries that represent intermediate folders.<br>

<br>so listResources() would return org/, then org/jboss/, then org/jboss/forge/ as you recursively travel down the structure.<br><br>I&#39;m not sure exactly if ZipEntry really supports this kind of directory navigation, so you might need to implement it yourself.<br>

<br>~Lincoln<br><div class="gmail_extra"><br><br><div class="gmail_quote"><div><div class="h5">On Sun, Nov 18, 2012 at 2:19 PM, Adolfo Jr. <span dir="ltr">&lt;<a href="mailto:adolfojunior@gmail.com" target="_blank">adolfojunior@gmail.com</a>&gt;</span> wrote:<br>

</div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5"><div>Hi everyone,</div><div><br></div><div>I am a new Forge entusiast, it&#39;s a great project!</div>
<div>So decided to learn and help, i started to do some code.</div>
<div><br></div><div>I developed a plugin based in issue <a href="https://issues.jboss.org/browse/FORGE-559" target="_blank">https://issues.jboss.org/browse/FORGE-559</a></div>
<div><br></div><div>The implementation suggest a full list of entries in a zip archive.</div><div><br></div><div><div><span style="white-space:pre-wrap">        </span>[plugin-lszip] plugin-lszip.jar $ ls<br></div><div><div>
<span style="white-space:pre-wrap">        </span>META-INF/</div><div><span style="white-space:pre-wrap">        </span>META-INF/beans.xml</div><div><span style="white-space:pre-wrap">        </span>README.TXT</div><div><span style="white-space:pre-wrap">        </span>org/</div>


<div><span style="white-space:pre-wrap">        </span>org/jboss/</div><div><span style="white-space:pre-wrap">        </span>org/jboss/forge/</div><div><span style="white-space:pre-wrap">        </span>org/jboss/forge/dev/</div><div>
<span style="white-space:pre-wrap">        </span>org/jboss/forge/dev/zip/</div><div><span style="white-space:pre-wrap">        </span>org/jboss/forge/dev/zip/LsZipPlugin.class</div><div><span style="white-space:pre-wrap">        </span>org/jboss/forge/resources/</div>


<div><span style="white-space:pre-wrap">        </span>org/jboss/forge/resources/ZipEntryResource$ZipEntryInputStream.class</div><div><span style="white-space:pre-wrap">        </span>org/jboss/forge/resources/ZipEntryResource.class</div>


<div><span style="white-space:pre-wrap">        </span>org/jboss/forge/resources/ZipResource.class</div></div></div><div><br></div><div>Then i sent a pull to github: <a href="https://github.com/forge/core/pull/239" target="_blank">https://github.com/forge/core/pull/239</a></div>


<div><br></div><div>The code works fine for list command.</div><div>But in some other tests with &quot;cat&quot; command to read a ZipEntry content, and &quot;cd&quot; command to change the current resource, the commands didn&#39;t work!</div>


<div><br></div><div>I realised that the name of entries contains slash and the PathspecParser class split the name and navigate recursively.</div><div><br></div><div>I think that implementation like a DirectoryResource hierarquicali could work fine. But will lose the full list of entries.</div>


<div><br></div><div>Some suggestion to resolve the behavior?</div><div><br></div><div>Thank you,</div><div>Adolfo Jr.</div>
<br></div></div>_______________________________________________<br>
forge-dev mailing list<br>
<a href="mailto:forge-dev@lists.jboss.org" target="_blank">forge-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/forge-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/forge-dev</a><br>
<br></blockquote></div><span class="HOEnZb"><font color="#888888"><br><br clear="all"><br>-- <br>Lincoln Baxter, III<br><a href="http://ocpsoft.org" target="_blank">http://ocpsoft.org</a><br>&quot;Simpler is better.&quot;<br>

</font></span></div>
</blockquote></div><br><br clear="all"><br>-- <br>Lincoln Baxter, III<br><a href="http://ocpsoft.org" target="_blank">http://ocpsoft.org</a><br>&quot;Simpler is better.&quot;<br>
</div>