<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Removing files in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/removing-files/m-p/259727#M212857</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Excellent. Glad that worked!&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If you have not already found and installed the &lt;/SPAN&gt;&lt;A href="http://addons.alfresco.com/addons/javascript-console" rel="nofollow noopener noreferrer"&gt;JavaScript Console&lt;/A&gt;&lt;SPAN&gt;, I would encourage you to do so. It gives you a nice interactive way to run JavaScript against Alfresco directly in the Alfresco Share UI.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Another little trick is that you can run an interactive rhino shell on your desktop, like this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="language-none line-numbers"&gt;&lt;CODE&gt;java -classpath /opt/alfresco/4.0d-community/sdk/lib/server/dependencies/rhino-js-1.6R7.jar org.mozilla.javascript.tools.shell.Main&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;&lt;SPAN&gt;I put that in a file called "rhino.sh" and then whenever I can't remember some piece of JavaScript syntax or I just want to try a couple of things, I run that script and type away. Unlike the Share-based JavaScript console referenced above, this shell doesn't have direct access to the Alfresco API, but it is good for playing with straight JavaScript.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Jeff&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 28 Jun 2012 21:46:38 GMT</pubDate>
    <dc:creator>jpotts</dc:creator>
    <dc:date>2012-06-28T21:46:38Z</dc:date>
    <item>
      <title>Removing files</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/removing-files/m-p/259724#M212854</link>
      <description>Hello ppl,I want to write a simple script thats remove all documents thats enter in a folder who doesnt has a extension ".backup".var name = document.name;var splited = name.split(".");var index = splited.length;if(splited[index -1]!="backup"){&amp;nbsp;&amp;nbsp;&amp;nbsp;document.remove();}‍‍‍‍‍‍‍I created a rule to execute</description>
      <pubDate>Tue, 26 Jun 2012 23:50:50 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/removing-files/m-p/259724#M212854</guid>
      <dc:creator>ltardioli</dc:creator>
      <dc:date>2012-06-26T23:50:50Z</dc:date>
    </item>
    <item>
      <title>Re: Removing files</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/removing-files/m-p/259725#M212855</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;My first thought is that you could write this more succinctly by using something like:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;if (name.indexOf('.backup') &amp;lt; 0)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;With that said, what you have seems like it should work. However, there is no need to put the name matching logic in the JavaScript unless you just want to. The rule configuration includes a filter by name which can be negated with a checkbox.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Jeff&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Jun 2012 04:26:51 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/removing-files/m-p/259725#M212855</guid>
      <dc:creator>jpotts</dc:creator>
      <dc:date>2012-06-27T04:26:51Z</dc:date>
    </item>
    <item>
      <title>Re: Removing files</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/removing-files/m-p/259726#M212856</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks for the tip!&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm new in Javascript programming and I'm doing this examples to studying.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;And your example worked fine.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 28 Jun 2012 21:30:41 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/removing-files/m-p/259726#M212856</guid>
      <dc:creator>ltardioli</dc:creator>
      <dc:date>2012-06-28T21:30:41Z</dc:date>
    </item>
    <item>
      <title>Re: Removing files</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/removing-files/m-p/259727#M212857</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Excellent. Glad that worked!&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If you have not already found and installed the &lt;/SPAN&gt;&lt;A href="http://addons.alfresco.com/addons/javascript-console" rel="nofollow noopener noreferrer"&gt;JavaScript Console&lt;/A&gt;&lt;SPAN&gt;, I would encourage you to do so. It gives you a nice interactive way to run JavaScript against Alfresco directly in the Alfresco Share UI.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Another little trick is that you can run an interactive rhino shell on your desktop, like this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="language-none line-numbers"&gt;&lt;CODE&gt;java -classpath /opt/alfresco/4.0d-community/sdk/lib/server/dependencies/rhino-js-1.6R7.jar org.mozilla.javascript.tools.shell.Main&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;&lt;SPAN&gt;I put that in a file called "rhino.sh" and then whenever I can't remember some piece of JavaScript syntax or I just want to try a couple of things, I run that script and type away. Unlike the Share-based JavaScript console referenced above, this shell doesn't have direct access to the Alfresco API, but it is good for playing with straight JavaScript.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Jeff&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 28 Jun 2012 21:46:38 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/removing-files/m-p/259727#M212857</guid>
      <dc:creator>jpotts</dc:creator>
      <dc:date>2012-06-28T21:46:38Z</dc:date>
    </item>
    <item>
      <title>Re: Removing files</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/removing-files/m-p/259728#M212858</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I'm using JavaScript console and it is a great tool! Have helped me alot!&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;That rhino shell I didn't know it, but I'll try here!&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks for the help!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Jul 2012 21:39:20 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/removing-files/m-p/259728#M212858</guid>
      <dc:creator>ltardioli</dc:creator>
      <dc:date>2012-07-02T21:39:20Z</dc:date>
    </item>
  </channel>
</rss>

