The jars are obtained from the <em>embedded</em> directory within the
<a href="http://dist.codehaus.org/groovy/distributions">groovy
distribution</a>. The easiest way of adding them to the Jalview classpath
The jars are obtained from the <em>embedded</em> directory within the
<a href="http://dist.codehaus.org/groovy/distributions">groovy
distribution</a>. The easiest way of adding them to the Jalview classpath
then add the groovy-all-*.jar to the lib directory whose path is given
in the java.ext.dirs property.
</p>
then add the groovy-all-*.jar to the lib directory whose path is given
in the java.ext.dirs property.
</p>
Jalview command line</a> will execute the contents of <script>.
<script> may be a file, a URL, or alternatively if it is
"STDIN" then the standard input will be used.<br>
<em>Note: The groovy script will be executed <strong>after</strong>
any data is loaded, and <strong>before</strong> images or any output
Jalview command line</a> will execute the contents of <script>.
<script> may be a file, a URL, or alternatively if it is
"STDIN" then the standard input will be used.<br>
<em>Note: The groovy script will be executed <strong>after</strong>
any data is loaded, and <strong>before</strong> images or any output
object defined in the groovy environent which corresponds to the
<pre>jalview.gui.Desktop</pre>
object which manages all the Jalview windows.
object defined in the groovy environent which corresponds to the
<pre>jalview.gui.Desktop</pre>
object which manages all the Jalview windows.
Here's an example to get you started:
<br>
<ul>
<li>Getting the title, alignment and first sequence from the
current alignFrame<br> <pre>
Here's an example to get you started:
<br>
<ul>
<li>Getting the title, alignment and first sequence from the
current alignFrame<br> <pre>
<li>When running a groovy script from the command line, the alignment that was just loaded can be referred to like so:<br><pre>
print currentAlFrame.getTitle();</pre>
</ul>
<li>When running a groovy script from the command line, the alignment that was just loaded can be referred to like so:<br><pre>
print currentAlFrame.getTitle();</pre>
</ul>