Difference between revisions of "Documentation/Nightly/Developers/Extensions/DescriptionFile"

From Slicer Wiki
Jump to: navigation, search
(Created page with 'An extension description file is a text file with <code>s4ext</code> extension allowing to specify metadata associated with an [extension][]. * A metadata is specified using a k…')
 
(13 intermediate revisions by 4 users not shown)
Line 1: Line 1:
An extension description file is a text file with <code>s4ext</code> extension allowing to specify metadata associated with an [extension][].
+
<noinclude>{{documentation/versioncheck}}</noinclude>
 +
<noinclude>
 +
__TOC__
 +
= Extension description file =</noinclude>
 +
 
 +
An extension description file is a text file with <code>s4ext</code> extension allowing to specify metadata associated with an [[Documentation/{{documentation/version}}/Extensions/Description|extension]].
  
 
* A metadata is specified using a keyword followed by at least one spaces and the associated value.
 
* A metadata is specified using a keyword followed by at least one spaces and the associated value.
Line 5: Line 10:
 
* Empty line are ignored
 
* Empty line are ignored
 
* Line starting with a <code>#</code> will be considered as comment.
 
* Line starting with a <code>#</code> will be considered as comment.
 +
 +
This file is generated by the build system in the extension build tree. It can also be generated by the [[Documentation/{{documentation/version}}/Developers/ExtensionWizard|ExtensionWizard]] using the extension metadata reported in the extension <code>CMakeLists.txt</code>.
 +
 +
Note that the Extension manager ignores many fields of the extension description file and instead uses information specified in <code>CMakeLists.txt</code>. Therefore, when making any changes to the extension description, it has to be done in the <code>CMakeLists.txt</code> file as well.
 +
 +
For the superbuild-based extensions, it is critical that the build_subdirectory is initialized to the inner build location in s4ext. The value of this variable in <code>CMakeLists.txt</code> is not used in all places by the dashboard scripts.
  
 
The following code block illustrates how comments, metadata and associated value can be specified:
 
The following code block illustrates how comments, metadata and associated value can be specified:
Line 16: Line 27:
 
</pre>
 
</pre>
  
== The list of supported metadata ==
+
== Supported metadata ==
  
<table>
+
<table class="alternate">
 
   <tr>
 
   <tr>
 
     <th>Name</th>
 
     <th>Name</th>
Line 51: Line 62:
 
   <tr>
 
   <tr>
 
     <td><code>depends</code></td>
 
     <td><code>depends</code></td>
     <td>List of extensions required to build this extension. Specify <code>"NA"</code> if there are no dependency.</td>
+
     <td>List of extensions required to build this extension. Specify <code>"NA"</code> if there are no dependency.<br>Extension names should be separated by a single space. For example: <code>extensionA extensionB</code></td>
 
     <td></td>
 
     <td></td>
 
   </tr>
 
   </tr>
Line 96: Line 107:
 
</table>
 
</table>
  
[1] Parameter like <code>&foo=bar</code> are not supported. Use an url shortener.
+
[1] Parameter like <code>&foo=bar</code> are not supported. Use a url shortener.
  
== The list of partially supported metadata ==
+
== Partially supported metadata ==
  
<table>
+
<table class="alternate">
 
   <tr>
 
   <tr>
 
     <th>Name</th>
 
     <th>Name</th>

Revision as of 15:32, 28 September 2017

Home < Documentation < Nightly < Developers < Extensions < DescriptionFile


For the latest Slicer documentation, visit the read-the-docs.


Extension description file

An extension description file is a text file with s4ext extension allowing to specify metadata associated with an extension.

  • A metadata is specified using a keyword followed by at least one spaces and the associated value.
  • Multiline value are not supported.
  • Empty line are ignored
  • Line starting with a # will be considered as comment.

This file is generated by the build system in the extension build tree. It can also be generated by the ExtensionWizard using the extension metadata reported in the extension CMakeLists.txt.

Note that the Extension manager ignores many fields of the extension description file and instead uses information specified in CMakeLists.txt. Therefore, when making any changes to the extension description, it has to be done in the CMakeLists.txt file as well.

For the superbuild-based extensions, it is critical that the build_subdirectory is initialized to the inner build location in s4ext. The value of this variable in CMakeLists.txt is not used in all places by the dashboard scripts.

The following code block illustrates how comments, metadata and associated value can be specified:

# This is a comment
metadataname This is the value associated with 'metadataname'

# This is an other comment
anothermetadata This is the value associated with 'anothermetadata'

Supported metadata

Name Description Mandatory
scm Source code management system: git or svn Yes check.png
scmurl Read-only url used to checkout the extension source code Yes check.png
svnusername Allow to specify username associated with svn checkout
svnpassword Allow to specify password associated with svn checkout
scmrevision Revision allowing to checkout the expected source code Yes check.png
depends List of extensions required to build this extension. Specify "NA" if there are no dependency.
Extension names should be separated by a single space. For example: extensionA extensionB
build_subdirectory Name of the inner build directory in case of superbuild based extension. Default to .
homepage Url of the web page describing the extension. See note [1] reported below. Yes check.png
contributors Extension contributor specified as
Firstname1 Lastname1 ([SubOrg1, ]Org1), Firstname2 Lastname2 ([SubOrg2, ]Org2)
category Extension category Yes check.png
iconurl Url to an icon (png, size 128x128 pixels). See note [1] reported below.
description One line describing what is the purpose of the extension
screenshoturls Space separated list of urls to images. See note [1] reported below.
enabled 1 or 0 - Specify if the extension should be enabled after its installation. Default is 1

[1] Parameter like &foo=bar are not supported. Use a url shortener.

Partially supported metadata

Name Description
status Give people an idea what to expect from this code