Code Search for Developers
 
 
  

book_list.sh from SME Web Application Framework at Krugle


Show book_list.sh syntax highlighted

#!/bin/bash

### Refresh the content of books/book_list with the books
### that are already in the system.

### go to this dir
cd $(dirname $0)

### empty the book_list file
echo "" > books/book_list

### add lines for all the books and languages
books=$(ls books/xml/)
for book_id in $books  #for each book
do
  # get a list of languages in which the book is available
  langs=$(ls books/xml/$book_id/)

  for lng in $langs  #for each language
  do
    # get the title of the book
    xslt=../xsl_transform/explode
    xml_file="books/xml/$book_id/$lng/content.xml"
    book_title=$(xsltproc $xslt/get_title.xsl $xml_file)

    # add a line for the book in the book_list
    echo "$book_id:$lng:$book_title" >> books/book_list

  done #langs
done #books




See more files for this project here

SME Web Application Framework

smewebapp intends to simplify the construction of web applications for informatization of the work of SME-s (small and medium enterprises), institutions, organizations etc.

Project homepage: http://sourceforge.net/projects/smewebapp
Programming language(s): JavaScript,PHP,Shell Script,XML
License: other

  SVN/
    README
    book_list.sh
    commit-email.pl
    commit.sh
    commit_all.sh
    get_url.sh
    init.sh
    post-commit.tmpl
    sync.sh
    sync_all.sh
    txt_diff.sh
    update.sh
    update_all.sh
  books_media/
  cache/
    cache.sh
    html2xhtml.php
  downloads/
    test/
      kurani_1.tex
      kurani_1.xml
      test.sh
    checkout_xml_sources.sh
    make-all-downloads.sh
    make-downloads.sh
    sgml_dsssl.sh
    xml2latex.xsl
    xml_xsl.sh
  explode/
    explode.sh
    post_process.php
    pre_process.php
  implode/
    implode.sh
    post_process.php
    pre_process.php
    section2sect.sh
  initial_xml/
    GNU-FDL.xml
    article_template_en.xml
    book_template_en.xml
    docbookwiki_guide_en.xml
    menushpk_manual_en.xml
    menushpk_manual_sq_AL.xml
    smewebapp_manual_en.xml
    transform.xsl
    transform_template.xsl
  test/
    get_id.sh
    get_lang.sh
    sect2section.sh
    section2sect.sh
  book_list.sh
  clean.sh
  import.sh
  make-content.sh
  svn_relocate.sh