Index: pykota/trunk/man/pl/dumpykota.1
===================================================================
--- pykota/trunk/man/pl/dumpykota.1 (revision 3279)
+++ pykota/trunk/man/pl/dumpykota.1 (revision 3485)
@@ -1,110 +1,73 @@
 .\" DO NOT MODIFY THIS FILE!  It was generated by help2man 1.36.
-.TH DUMPYKOTA "1" "janvier 2008" "C@LL - Conseil Internet & Logiciels Libres" "User Commands"
+.TH DUMPYKOTA "1" "janvier 2009" "C@LL - Conseil Internet & Logiciels Libres" "User Commands"
 .SH NOM
-dumpykota \- page de manuel de dumpykota 1.27alpha3_BROKEN_unofficial
+dumpykota \- page de manuel de dumpykota (PyKota) 1.27alpha7_unofficial
+.SH SYNOPSIS
+.B dumpykota
+[\fIoptions\fR] [\fIfilterexpr\fR]
 .SH DESCRIPTION
-dumpykota v1.27alpha3_BROKEN_unofficial (c) 2003, 2004, 2005, 2006, 2007, 2008 Jerome Alet \- alet@librelogiciel.com
-.PP
-Dumps PyKota database's content.
-.PP
-command line usage :
+Data Dumper for PyKota.
+.SH OPTIONS
+.TP
+\fB\-h\fR, \fB\-\-help\fR
+show this help message and exit.
+.TP
+\fB\-v\fR, \fB\-\-version\fR
+show the version number and exit.
+.TP
+\fB\-A\fR ARGUMENTSFILE, \fB\-\-arguments\fR=\fIARGUMENTSFILE\fR
+loads additional options and arguments from a file,
+one per line.
+.TP
+\fB\-d\fR DATA, \fB\-\-data\fR=\fIDATA\fR
+Select the type of datas to dump. This option is
+mandatory. Supported data types are : history,
+payments, billingcodes, users, groups, printers,
+upquotas, gpquotas, umembers, pmembers, and all. The
+\&'all' value forces the output format to XML.
+.TP
+\fB\-f\fR FORMAT, \fB\-\-format\fR=\fIFORMAT\fR
+Select the output format, the default being comma
+separated values. Supported formats are : csv, ssv,
+tsv, xml and cups. The 'cups' output format only works
+when dumping the history, and produces CUPS' page_log
+compatible output.
+.TP
+\fB\-o\fR OUTPUT, \fB\-\-output\fR=\fIOUTPUT\fR
+The name of the file the data dump will be written to.
+The default value is '\-', which tells dumpykota to
+write the dump to stdout.
+.TP
+\fB\-O\fR ORDERBY, \fB\-\-orderby\fR=\fIORDERBY\fR
+Change the ordering of the output based on a comma
+separated list of ordering statements. For example
+\&'\-username,+printername' would sort the output by
+descending order of user names and ascending order of
+printer names. Not all expressions are supported, and
+you should not use this if you don't know the internal
+structure of PyKota's database.
+.TP
+\fB\-s\fR, \fB\-\-sum\fR
+Summarize the output. Only available when dumping the
+printing history or the payments.
+.SS "filtering expressions:"
 .IP
-dumpykota [options] [filterexpr]
-.PP
-options :
-.TP
-\fB\-v\fR | \fB\-\-version\fR
-Prints dumpykota's version number then exits.
-.TP
-\fB\-h\fR | \fB\-\-help\fR
-Prints this message then exits.
-.TP
-\fB\-d\fR | \fB\-\-data\fR type
-Dumps 'type' datas. Allowed types are :
+Use the filtering expressions to extract only parts of the datas. Allowed
+filters are of the form 'key=value'. Wildcards are not expanded as part of
+these filtering expressions, so you can't use them here.
 .IP
-\- history : dumps the jobs history.
-\- users : dumps users.
-\- groups : dumps user groups.
-\- printers : dump printers.
-\- upquotas : dump user quotas.
-\- gpquotas : dump user groups quotas.
-\- payments : dumps user payments.
-\- pmembers : dumps printer groups members.
-\- umembers : dumps user groups members.
-\- billingcodes : dumps billing codes.
-\- all : dumps all PyKota datas. The output format
+allowed keys for now:
 .IP
-is always XML in this case.
+username : User's name
+groupname : Users group's name
+printername : Printer's name
+pgroupname : Printers group's name
+hostname : Host's name
+jobid : Job's id
+billingcode : Job's billing code
+start : Job's date of printing
+end : Job's date of printing
 .IP
-NB : the \fB\-d\fR | \fB\-\-data\fR command line option
-is MANDATORY.
-.TP
-\fB\-f\fR | \fB\-\-format\fR fmt
-Dumps datas in the 'fmt' format. When not specified,
-the format is to dump datas in the csv format (comma
-separated values). All data dumped is between double
-quotes. Allowed formats are :
-.IP
-\- csv : separate datas with commas
-\- ssv : separate datas with semicolons
-\- tsv : separate datas with tabs
-\- xml : dump data as XML
-\- cups : dump datas in CUPS' page_log format :
-.IP
-ONLY AVAILABLE WITH \fB\-\-data\fR history
-.TP
-\fB\-o\fR | \fB\-\-output\fR fname
-All datas will be dumped to the file instead of
-to the standard output. The special '\-' filename
-is the default value and means stdout.
-WARNING : existing files are truncated !
-.TP
-\fB\-O\fR | \fB\-\-orderby\fR exp
-Change the ordering or result. 'exp' is a comma
-separated list of ordering statements, for example
-\&'\-\-orderby +username,\-printername'. Not all expression
-values are meaningful, so using this command line
-switch is not recommanded if you don't know the
-exact layout of PyKota's database schema.
-.TP
-\fB\-s\fR | \fB\-\-sum\fR
-Summarize the selected datas.
-ONLY AVAILABLE WITH \fB\-\-data\fR history or payments
-.IP
-Use the filter expressions to extract only parts of the
-datas. Allowed filters are of the form :
-.IP
-key=value
-.IP
-Allowed keys for now are :
-.TP
-username
-User's name
-.TP
-groupname
-Users group's name
-.TP
-printername
-Printer's name
-.TP
-pgroupname
-Printers group's name
-.TP
-hostname
-Client's hostname
-.TP
-jobid
-Job's Id
-.TP
-billingcode
-Job's billing code
-.TP
-start
-Job's date of printing
-.TP
-end
-Job's date of printing
-.IP
-Dates formatting with 'start' and 'end' filter keys :
+formatting of dates with the 'start' and 'end' filtering keys:
 .IP
 YYYY : year boundaries
@@ -114,53 +77,47 @@
 YYYYMMDDhhmm : minute boundaries
 YYYYMMDDhhmmss : second boundaries
-yesterday[+\-NbDays] : yesterday more or less N days (e.g. : yesterday\-15)
-today[+\-NbDays] : today more or less N days (e.g. : today\-15)
-tomorrow[+\-NbDays] : tomorrow more or less N days (e.g. : tomorrow\-15)
-now[+\-NbDays] : now more or less N days (e.g. now\-15)
+yesterday[+\-N] : yesterday more or less N days (e.g. : yesterday\-15)
+today[+\-N] : today more or less N days (e.g. : today\-15)
+tomorrow[+\-N] : tomorrow more or less N days (e.g. : tomorrow\-15)
+now[+\-N] : now more or less N days (e.g. now\-15)
 .IP
-\&'now' and 'today' are not exactly the same since today represents the first
-or last second of the day depending on if it's used in a start= or end=
-date expression. The utility to be able to specify dates in the future is
-a question which remains to be answered :\-)
+\&'now' and 'today' are not exactly the same since 'today' represents the
+first or last second of the day depending on if it's used in a 'start=' or
+\&'end=' date expression.
 .IP
-Contrary to other PyKota management tools, wildcard characters are not
-expanded, so you can't use them.
+examples:
 .IP
-NB : not all keys are allowed for each data type, so the result may be
-empty if you use a key not available for a particular data type.
-.PP
-Examples :
+dumpykota \fB\-\-unit\fR EURO \fB\-\-output\fR /tmp/invoices.pdf start=now\-30
+This would generate a PDF document containing invoices for all users
+who have spent some credits last month. Amounts would be in EURO and
+not VAT information would be included.
 .IP
-\f(CW$ dumpykota \-\-data history \-\-format csv >myfile.csv\fR
+dumpykota \fB\-\-data\fR history \fB\-\-format\fR csv >myfile.csv
+This would dump the whole printing history to stdout in the CSV
+format, and redirect the output to a file.
 .IP
-This dumps the history in a comma separated values file, for possible
-use in a spreadsheet.
+dumpykota \fB\-\-data\fR users \fB\-\-format\fR xml \fB\-o\fR users.xml
+This would dump all users into the 'users.xml' file in the XML format.
 .IP
-\f(CW$ dumpykota \-\-data users \-\-format xml -o users.xml\fR
+dumpykota \fB\-\-data\fR history printername=HP2100 username=jerome
+This would dump jerome's printing history on printer HP2100.
 .IP
-Dumps all users datas to the users.xml file.
+dumpykota \fB\-\-data\fR history start=200503 end=20050730234615
+This would dump all jobs printer between March 1st 2008 at midnight
+and July 30th 2008 at 23 hours 46 minutes and 15 seconds, included.
 .IP
-\f(CW$ dumpykota \-\-data history printername=HP2100 username=jerome\fR
+licensing terms:
 .IP
-Dumps the job history for user jerome on printer HP2100 only.
-.IP
-\f(CW$ dumpykota \-\-data history start=200503 end=20050730234615\fR
-.IP
-Dumps all jobs printed between March 1st 2005 at midnight and
-July 30th 2005 at 23 hours 46 minutes and 15 secondes included.
-.PP
-(c) 2003, 2004, 2005, 2006, 2007, 2008 Jerome Alet <alet@librelogiciel.com>
+(c) 2003\-2009 Jerome Alet \- alet@librelogiciel.com
 This program is free software: you can redistribute it and/or modify
 it under the terms of the GNU General Public License as published by
-the Free Software Foundation, either version 3 of the License, or
-(at your option) any later version.
-.PP
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-.PP
+the Free Software Foundation, either version 3 of the License, or (at
+your option) any later version.
+.IP
+This program is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+General Public License for more details.
+.IP
 You should have received a copy of the GNU General Public License
 along with this program.  If not, see <http://www.gnu.org/licenses/>.
-.PP
-Please report bugs to : Jerome Alet \- alet@librelogiciel.com
