Mercurial > bins
view doc/usage_tools.xml @ 3:66beb7e16b22
Added tag 1.1.29-extended for changeset c44d020e5f8a
author | Peter Gervai <grin@grin.hu> |
---|---|
date | Wed, 15 Oct 2008 23:32:04 +0200 |
parents | a84c32f131df |
children |
line wrap: on
line source
<?xml version="1.0" encoding="LATIN1" ?> <!DOCTYPE webpage PUBLIC "-//Norman Walsh//DTD Website V2.2//EN" "http://docbook.sourceforge.net/release/website/2.2/website.dtd" [ <!NOTATION XML SYSTEM "xml"> <!ENTITY usage_desc_xml SYSTEM "usage_desc_xml.xml" NDATA XML> <!ENTITY faq SYSTEM "faq.xml" NDATA XML> ]> <!-- $Id: usage_tools.xml,v 1.2 2005/08/22 23:53:32 jerome Exp $ --> <webpage id="usage_tools"> <config param="rcsdate" value="$Date: 2005/08/22 23:53:32 $"/> <head> <title>Tools</title> <keywords>SAUTRET, BINS, album, gallery, photos, EXIF</keywords> </head> <webtoc/> <para> The BINS archive contains a <filename>tools</filename> directory with some small BINS related utilities. Here is a quick documentation about these tools. </para> <section> <title><command>bins_cleanupgallery</command></title> <para> The <command>bins_cleanupgallery</command> script can be use to remove any unused file in your HTML galleries, for example images you have removed from you source tree. Run it without argument for usage information. Note that this script is still experimental, so if it performs wrong, just re-run bins to recreate erased files. </para> <para> This program was written by Jochen Schaeuble <email>psionic @ psionic.de</email>. </para> </section> <section> <title><command>anti_bins</command></title> <para> This program creates a image files tree for each image size from a BINS generated album. Edit the variables in the configuration section and run it. </para> <para> Note that this program will not work if there is files or directories with space in their name in your tree. </para> </section> <section> <title><command>remove_num_prefix</command></title> <para> This script remove numeric prefixes added with <command>add_num_prefix</command>. See below. </para> </section> <section> <title><command>add_num_prefix</command></title> <para> <command>add_num_prefix</command> adds incremental numeric prefixes to files. You can use it to order the images in your albums. Note that there is an alternate method to order images and sub-albums, using the <filename>album.list</filename> file (see the <olink localinfo="faq">FAQ</olink>). </para> <programlisting> Usage: add_num_prefix start step files... Add a numeric prefix starting at 'start', incrementing by 'step' on 'files'. </programlisting> <para> For example, say that you have two sets of images, from two digicams. The images are named <filename>IMG_*</filename> for the first one, and <filename>DSC*</filename> for the second one. You want that the first set appears first in the album, and then, you want to change the order of some pictures. You start by adding a prefix on the first set: </para> <programlisting> add_num_prefix 0100 100 IMG_* </programlisting> <para>The images are now named like this: </para> <programlisting> 0100_IMG_5103.JPG 0200_IMG_5104.JPG 0300_IMG_5105.JPG .... 2500_IMG_6144.JPG </programlisting> <para> Then do the same on the second set (note that the last image of the first set in now named <filename>2500_IMG_*</filename>):</para> <programlisting> add_num_prefix 2600 100 DSC* </programlisting> <para> Then, you can reorder some of the pictures by changing their prefix. Just rename them with a file manager or on command line: </para> <programlisting> mv 1400_IMG_3450.JPG 0550_IMG_3450.JPG </programlisting> <para> You can also change the order of several pictures with <command>remove_num_prefix</command> and <command>add_num_prefix</command>. For example, to move all pictures between 1200 (included) to 1600 (not included) after the picture number 0100, use the following commands: </para> <programlisting> remove_num_prefix 1[2-5]*_IMG*.JPG add_num_prefix 0110 10 IMG* </programlisting> <para>This remove the prefix of the pictures you want to move, and add a new one beginning after 0100, with a small step. If you have already some XML files in your album, run also: </para> <programlisting> remove_num_prefix 1[2-5]00_*.xml add_num_prefix 0110 10 IMG* </programlisting> </section> <section> <title><command>bins_addtext</command></title> <para> Adrian Rossiter <email>adrian_r @ teleline.es</email> wrote this program. It can be used to set description fields in an alternate way. Here are the instructions from Adrian: </para> <para> I build a directory tree of image albums as normal, but in each album directory I create an <filename>include_images.txt</filename> file containing a list of the album images in the order I want them. I get bins to only consider the images in the <filename>include_images.txt</filename> files by setting the <literal>excludeFiles</literal> parameter in <filename>binsrc</filename> to exclude all files (<filename>.*</filename>). </para> <para> I then add comment lines to the <filename>include_images.txt</filename> files which I process with a <command>bins_addtext</command> to set up the album. At the beginning I add the album details, then after each image I add the title and description. <command>bins_addtext</command> simply calls the <command>bins_edit</command> program with the various details as arguments. </para> <para> This is working out reasonably well as I can easily change the album, image text, order of images, etc just by editing one text file. Here is an example include_images.txt file for a one image album: </para> <programlisting> <![CDATA[ #Some Album Title (1 line) #Long description of Some Album #(can be many #lines) #|Short description of Some Album (starts after the pipe symbol) #can be many lines, then put another pipe symbol and this is followed #by the sample album image) #|some_image.gif some_image.gif #Some Image Title (1 line) #Description of Some Image #can be many lines #and include html <BR> #but you may have to escape certain symbols for the command line e.g. #<A HREF=\"http://www.somesite.com\">Some Site</A> ]]> </programlisting> <para> I call the script <command>bins_addtext</command>. It just takes a list of directories where it looks for <filename>include_images.txt</filename> and processes it. You can use a different file by passing the name with the <literal>-f</literal> option, e.g process <filename>include_images.txt</filename> in the current directory: </para> <programlisting> bin_addtext ./ </programlisting> <para> Process album_desc.txt in directories some_album1 and some_album2: </para> <programlisting> bin_addtext -f album_desc.txt some_album1 some_album2 </programlisting> </section> <section> <title><command>bins_txt2xml</command></title> <para> This is used to convert the old txt description files used in BINS older than 1.1.0 version to the new XML one. Run it with the directory of your image tree as parameter. </para> </section> </webpage>