<opt
  name="sgdbulk"
  relid="7"
  make_current="1"
  >
  
  <!-- 07oct: test bulkfiles v1.1  with no_csomesplit -->
  <no_csomesplit>1</no_csomesplit>
  
  <about id="sgdbulk"><![CDATA[
   See bulkfiles_template.xml for further documentation. 
   See site_defaults for included configurations.
  ]]></about>
  
  <include>site_defaults</include>
  
  <title>SGD Lite</title>
  
  <doc id="Release.txt"><![CDATA[
  Bulk output for Chado genome databases
  Database: ${title} 
  Species:  ${species}
  Release:  ${release_id}, dated ${release_date} as ${relfull}
  
  See release notes at <a href="${release_url}"> ${release_url}</a>
  ]]></doc>
  
  <doc id="Example.txt"><![CDATA[
  Bulkfiles Example:
  # get software
  curl -O http://eugenes.org/gmod/GMODTools/GMODTools-1.0.zip
  unzip GMODTools*.zip

  # load a genome chado db to Postgres database
  curl -O http://sgdlite.princeton.edu/download/sgdlite/sgdlite.sql.gz
  createdb sgdlite
  (gunzip -c sgdlite.sql.gz | psql -d sgdlite -f - ) >& log.load 

  # extract bulk files from database
  cd GMODTools 
  perl -Ilib bin/bulkfiles.pl -conf sgdbulk -make 

  # if failed
  perl -Ilib bin/bulkfiles.pl -conf sgdbulk -make -debug \
    |& mail -s gmodtools-debug gilbertd@indiana.edu 

  Find worked examples from Bulkfiles SQL use now at
    http://www.gmod.org/Sample_Chado_SQL

  ]]></doc>
  
  
  <release id="7" dbname="sgdlite" date="20070531"/>
  <release id="5" dbname="sgdlite_2005" date="20050823"/>
  <release id="1" dbname="sgdlite_2004" date="20040519"/>

  <relfull>${org}_${release_date}</relfull> 
  <release_url>/genome/${species}/release-${release_id}.html</release_url>

  <org>scer</org>
  <species>Saccharomyces_cerevisiae</species>
  <taxon>4932</taxon> <!-- 0710: for go_association table ; add to org.table -->

  <!-- see chadofeatsql ENV_default -->
  <golden_path>'chromosome'</golden_path>
  <featureprops>'Note','orf_classification'</featureprops>
  <GFF_source>SGD</GFF_source>

  <!-- default seq_ontology now is sequence -->
  <seq_ontology>Sequence Ontology Feature Annotation</seq_ontology>

  <about id="species_variables">
  The  golden_path, seq_ontology and species variables are critical.
  See bulkfiles_template.xml for further documentation.
  </about>
  
  <valid>0</valid> <!-- set 1 to skip db checks of above variables -->
  
  <fileset_override
    name="fff"
    path="fff/.+\.fff"
    input="feature_table"
    title="Genome features"
    config="sgdfeatconf"
    handler="FeatureWriter"
    dogzip="0"
    />
  <fileset_override id="dummy" title="placeholder for xmlsimple"/>

    <!--  
    0710: add go_association option
      need to add new outformat, see site_defaults
      need handler to recognize go_association target/format
      fileset go_association now in filesets.xml
    -->

  <featdump
    path="tmp/featdump/\w+.tsv"
    config="chadofeatsql"
    tag="feature_sql"
    type="feature_table"
    splitname="chadofeat"
    >
    <target>chromosomes</target>
    <target>features</target>
    <target>matches</target> <!--  //none in sgdlite1//  -->
    <target>analysis</target> <!--  //none in sgdlite1//  -->
  </featdump>
  
  <!-- feature sets to make fasta bulk files ; see sgdfeatconf -->
  <featset>chromosome</featset>
  <featset>gene</featset>
  <featset>CDS_translation</featset>
  <featset>ncRNA</featset>
  <featset>transposon</featset>
  <featset>gene_extended2000</featset>
  <featset>intergenic</featset>

  <featmap id="CDS_translation"
    types="CDS gene"
    typelabel="protein protein"
    dotranslate="1"
    fromdb="0"
    />
  <featmap id="gene"
    types="gene"
    />
  <featmap id="chromosome"
    types="${golden_path}"
    fromdb="1"
    onlydb="1"
    />
  <featmap id="transposon"
    types="transposable_element"
    typelabel="transposable_element"
    />
  <featmap name="ncRNA"
    types="ncRNA snRNA snoRNA rRNA tRNA"
    />
  <featmap id="gene_extended2000"
    types="gene"
    typelabel="gene_ex2000"
    subrange="-2000..2000"
    />
  <featmap id="intergenic"
    types="gene"
    typelabel="intergenic"
    method="between"
    />

  <!-- feature sets to make blast indices -->
  <blastset>chromosome</blastset>
  <blastset>gene</blastset>
  <blastset>CDS_translation</blastset>
  <blastset>ncRNA</blastset>
  <blastset>intergenic</blastset>

</opt>
