Blame view

swigra/parser/forest2xml 510 Bytes
Jan Lupa authored
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
#! /bin/bash
#
# Author: Marcin Woliński
# This file is in the public domain.

swigradir=`dirname $0`

if [ $# -eq 0 ]; then
    pliki=*.forest
else
    pliki=$*
fi


for i in $pliki
  do
    dirname=`dirname $i`
    rdzen=`basename $i .forest`
    fullname=$dirname/$rdzen.forest
    outname=$dirname/$rdzen.xml

    echo $fullname ' ==> ' $outname
    swipl -t halt -g "['$fullname','$swigradir/forest2xml'],f2x" >$outname

done

### Local Variables: 
### coding: utf-8
### mode: shell-script
### End: