Skip to content

PhilPons/synopsx

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

48 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Synopsx

Full XML corpus publishing system developped at ENS Lyon (http://ahn.ens-lyon.fr) based on BaseX

Installation

    cd <{path_to_basex}>/webapp
    rm -fr *
    git clone https://github.com/ahn-ens-lyon/synopsx.git .

Don't forget to change your admin password an

Configuration

Default syntax

If you use the BaseX Client use the default syntax : http://docs.basex.org/wiki/Commands You can also use the command line syntax : http://docs.basex.org/wiki/REST#Command_Line

(Change the informations between curl-braces with your own informations)

Config database

CREATE DB 'config' create the config database (http://docs.basex.org/wiki/Commands#CREATE_DB)

OPEN DB 'config' open the config database (http://docs.basex.org/wiki/Commands#OPEN_DB)

ADD synopsx.xml add the config file (http://docs.basex.org/wiki/Commands#ADD)

    <configuration name="synopsx">
        <output name="html" value="synopsx_html"/>
        <output name="oai" value="synopsx_oai"/>
    </configuration>

Project database

CREATE DB '{myproject}'

OPEN DB '{myproject}'

ADD {myproject_data.xml} (or ADD TO '{myproject}/' {myproject_data.zip})

OPEN DB 'config'

ADD {myproject.xml}

    <!-- config file for '{myproject}' -->
    <configuration name="{myproject}">
        <!-- The @value attribute gives the parent xqm module namespace -->
        <parent value="synopsx"/>  
        <!-- The @value attribute gives the output xqm module namespace -->
        <output name="html" value="{myproject}"/>  
        <!-- Uncomment this line to overwrite synopx oai default functions -->
        <!--<output name="oai" value="{myproject_oai_namespace}"/>-->
    </configuration>

XQuery syntax

You can also interact with BaseX with the XQuery syntax for the installation process : http://docs.basex.org/wiki/Database_Module

Config database

    <!-- create the config database (http://docs.basex.org/wiki/Database_Module#db:create) -->
    db:create("config")
    <!-- open the config database (http://docs.basex.org/wiki/Database_Module#db:open) -->
    db:open("config")
    <!-- add the XML sequence to the config database (http://docs.basex.org/wiki/Database_Module#db:add) -->
    db:add("config",
    <configuration name="synopsx">
        <output name="html" value="synopsx_html"/>
        <output name="oai" value="synopsx_oai"/>
    </configuration>, "synopsx.xml" )

Project database

    <!-- create the project database (http://docs.basex.org/wiki/Database_Module#db:create) -->
    db:create("{myproject}")
    <!-- open the project database (http://docs.basex.org/wiki/Database_Module#db:open) -->
    db:open("{myproject}")
<!-- Add XML data to the project database -->

    <!-- add the project's config XML sequence to the config database (http://docs.basex.org/wiki/Database_Module#db:add)

    first open the config database (http://docs.basex.org/wiki/Database_Module#db:open) -->

    db:open("config")

    db:add("config",
    <configuration name="{myproject}">
        <!-- The @value attribute gives the parent xqm module namespace -->
        <parent value="synopsx"/>  
        <!-- The @value attribute gives the output xqm module namespace -->
        <output name="html" value="{myproject}"/>  
        <!-- Uncomment this line to overwrite synopx oai default functions -->
        <!--<output name="oai" value="myproject_oai_namespace"/>-->
    </configuration>, "{myproject.xml}" )

About

Full XML corpus publishing system

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 45.7%
  • XSLT 44.3%
  • PHP 6.3%
  • XQuery 2.8%
  • CSS 0.9%