|
|
|
|
|
|
|
|
|
|
|
|
|
Images, css files for a document directory are copied to their respective locations in the output directory.
while within your document markup/preparation directory, issue the following command
sisu -CC
SiSU can populate PostgreSQL and Sqlite databases and provides a sample search form for querying these databases.
This note provides an example to get you started and will use sqlite
It is necessary to:
(1) make sure the required dependencies have been installed
(2) have a directory with sisu markup samples that is writable
(3) use sisu to create a database
(4) use sisu tp populate a database
(5) use sisu to start the webrick (httpd) server
(6) use sisu to create a search form
(7) copy the search form to the cgi directory
(8) open up the form in your browser
(9) query the database using the search form
(1) make sure the required dependencies have been installed
if you use Debian, the following command will install the required dependencies
aptitude install sisu-sqlite
(2) have a directory with sisu markup samples that is writable
ideally copy the sisu-examples directory to your home directory (because the directory in which you run this example should be writable)
cp -rv /usr/share/doc/sisu/markup-samples/samples .
you are better off installing the package sisu-markup-samples which will make the following available
cp -rv /usr/share/doc/sisu/markup-samples-non-free/samples .
(3) use sisu to create an sqlite database
within the sisu-examples directory
sisu -dv createall
(4) use sisu tp populate a database with some text
within the sisu-examples directory
sisu -div free_*.sst
or
sisu -dv import free_*.sst debian_constitution_v1.2.sst debian_social_contract_v1.1.sst gpl2.fsf.sst
(5) use sisu to start the webrick (httpd) server (if it has not already been started):
sisu -W
(6) use sisu to create a search form (for use with the webrick server, and your sample documents)
within the sisu-examples directory
sisu -F webserv=webrick
and follow the instructions provided
#here i run into a problem, you are working from a read only #directory..., not my usual mode of operation, to complete the example #the following is necessary sudo touch sisu_sqlite.cgi sisu_pgsql.cgi sudo -P chown $USER sisu_sqlite.cgi sisu_pgsql.cgi
#now this should be possible: sisu -F webrick
(7) copy the search form to the cgi directory
sisu -F webserv=webrick
and follow the instructions provided
(8) open up the form in your browser and query it
url:
or as instructed by command sisu -F webrick
(9) query the database using the search form
if there are other options in the dropdown menu select
document_samples_sisu_markup
and search for some text, e.g.:
aim OR project
(10) to start again with a new database
to start from scratch you can drop the database with the command
sisu -dv dropall
and go to step 3
to get to step 3 in one step with a single command
sisu -dv recreate
continue subsequent steps
sisu -uv[and other flags] [filename/wildcard]
sisu -Uv [filename/wildcard]
sisu -cv[and processing flags] [filename/wildcard]
sisu -v[and processing flags] [filename/wildcard]
sisu -V[and processing flags] [filename/wildcard]
sisu -q[and processing flags] [filename/wildcard]
sisu -Mv[and other flags] [filename/wildcard]
sisu -W
configuration is necessary
scp
sisu -vr[and processing flags] [filename/wildcard]
rsync
sisu -vR[and processing flags] [filename/wildcard]