doc: the latest input files doc updates

This commit is contained in:
Simon Michael 2016-11-22 14:20:17 -08:00
parent a1411768e5
commit 2eb5736abb
4 changed files with 404 additions and 447 deletions

View File

@ -423,7 +423,7 @@ $\ hledger\ \-f\ /some/file\ stats
\f[]
.fi
.PP
The file name \f[C]\-\f[] (hyphen) means standard input, as usual:
The file name \f[C]\-\f[] (hyphen) means standard input:
.IP
.nf
\f[C]
@ -431,46 +431,45 @@ $\ cat\ some.journal\ |\ hledger\ \-f\-
\f[]
.fi
.PP
Usually this file is in hledger\[aq]s journal format, but it can also be
one of several other formats, shown below.
hledger tries to identify the format based on the file extension, as
follows:
Usually the data file is in hledger\[aq]s journal format, but it can
also be one of several other formats, listed below.
hledger detects the format automatically based on the file extension, or
if that is not recognised, by trying each built\-in "reader" in turn:
.PP
.TS
tab(@);
l l l.
lw(10.7n) lw(33.2n) lw(26.1n).
T{
Format:
Reader:
T}@T{
Description:
Reads:
T}@T{
File extensions:
Used for file extensions:
T}
_
T{
journal
\f[C]journal\f[]
T}@T{
hledger\[aq]s journal format
hledger\[aq]s journal format, also some Ledger journals
T}@T{
\f[C]\&.journal\f[], \f[C]\&.j\f[], \f[C]\&.hledger\f[],
\f[C]\&.ledger\f[]
\f[C]\&.journal\f[] \f[C]\&.j\f[] \f[C]\&.hledger\f[] \f[C]\&.ledger\f[]
T}
T{
timeclock
\f[C]timeclock\f[]
T}@T{
timeclock files (precise time logging)
T}@T{
\f[C]\&.timeclock\f[]
T}
T{
timedot
\f[C]timedot\f[]
T}@T{
timedot files (approximate time logging)
T}@T{
\f[C]\&.timedot\f[]
T}
T{
CSV
\f[C]csv\f[]
T}@T{
comma\-separated values (data interchange)
T}@T{
@ -478,11 +477,9 @@ T}@T{
T}
.TE
.PP
hledger identifies the format based on the file extension if possible.
If that does not identify a known format, it tries each format in turn.
.PP
If needed, eg to ensure correct error messages, you can force a specific
format by prepending it to the file path with a colon.
If needed (eg to ensure correct error messages when a file has the
"wrong" extension), you can force a specific reader/format by prepending
it to the file path with a colon.
Examples:
.IP
.nf
@ -492,32 +489,10 @@ $\ echo\ \[aq]i\ 2009/13/1\ 08:00:00\[aq]\ |\ hledger\ print\ \-ftimeclock:\-
\f[]
.fi
.PP
Some other experimental formats are available but not yet used by
default:
.PP
.TS
tab(@);
l l l.
T{
Format:
T}@T{
Description:
T}@T{
File extensions:
T}
_
T{
ledger
T}@T{
Ledger\[aq]s journal format (incomplete)
T}@T{
T}
.TE
.PP
You can specify multiple \f[C]\-f\f[] options, to read multiple files as
one big journal.
Directives in one file will not affect subsequent files in this case (if
you need that, use the include directive instead).
You can also specify multiple \f[C]\-f\f[] options, to read multiple
files as one big journal.
(Directives in one file will not affect the other files.
If you need that, use the include directive instead.)
.SS Depth limiting
.PP
With the \f[C]\-\-depth\ N\f[] option, commands like account, balance

View File

@ -337,44 +337,38 @@ $ hledger stats
$ hledger -f /some/file stats
The file name `-' (hyphen) means standard input, as usual:
The file name `-' (hyphen) means standard input:
$ cat some.journal | hledger -f-
Usually this file is in hledger's journal format, but it can also be
one of several other formats, shown below. hledger tries to identify the
format based on the file extension, as follows:
Usually the data file is in hledger's journal format, but it can
also be one of several other formats, listed below. hledger detects the
format automatically based on the file extension, or if that is not
recognised, by trying each built-in "reader" in turn:
Format: Description: File extensions:
--------------------------------------------------------------------------------------------------
journal hledger's journal format `.journal', `.j', `.hledger', `.ledger'
timeclock timeclock files (precise time logging) `.timeclock'
timedot timedot files (approximate time logging) `.timedot'
CSV comma-separated values (data interchange) `.csv'
Reader: Reads: Used for file extensions:
---------------------------------------------------------------------------
`journal' hledger's journal format, also `.journal' `.j' `.hledger'
some Ledger journals `.ledger'
`timeclock' timeclock files (precise time `.timeclock'
logging)
`timedot' timedot files (approximate time `.timedot'
logging)
`csv' comma-separated values (data `.csv'
interchange)
hledger identifies the format based on the file extension if
possible. If that does not identify a known format, it tries each
format in turn.
If needed, eg to ensure correct error messages, you can force a
specific format by prepending it to the file path with a colon.
Examples:
If needed (eg to ensure correct error messages when a file has the
"wrong" extension), you can force a specific reader/format by prepending
it to the file path with a colon. Examples:
$ hledger -f csv:/some/csv-file.dat stats
$ echo 'i 2009/13/1 08:00:00' | hledger print -ftimeclock:-
Some other experimental formats are available but not yet used by
default:
Format: Description: File extensions:
--------------------------------------------------------------------
ledger Ledger's journal format (incomplete)
You can specify multiple `-f' options, to read multiple files as one
big journal. Directives in one file will not affect subsequent files in
this case (if you need that, use the include directive instead).
You can also specify multiple `-f' options, to read multiple files
as one big journal. (Directives in one file will not affect the other
files. If you need that, use the include directive instead.)

File: hledger.1.info, Node: Depth limiting, Next: Smart dates, Prev: Input files, Up: OPTIONS
@ -2175,91 +2169,91 @@ Node: Reporting options7583
Ref: #reporting-options7736
Node: Input files9512
Ref: #input-files9652
Node: Depth limiting11677
Ref: #depth-limiting11817
Node: Smart dates12018
Ref: #smart-dates12157
Node: Report intervals13154
Ref: #report-intervals13307
Node: Period expressions13643
Ref: #period-expressions13808
Node: Regular expressions16143
Ref: #regular-expressions16285
Node: QUERIES17768
Ref: #queries17872
Node: COMMANDS21511
Ref: #commands21625
Node: accounts22298
Ref: #accounts22398
Node: activity23380
Ref: #activity23492
Node: add23851
Ref: #add23952
Node: balance26611
Ref: #balance26724
Node: Flat mode29697
Ref: #flat-mode29824
Node: Depth limited balance reports30243
Ref: #depth-limited-balance-reports30446
Node: Multicolumn balance reports30867
Ref: #multicolumn-balance-reports31069
Node: Market value35718
Ref: #market-value35882
Node: Custom balance output36375
Ref: #custom-balance-output36548
Node: Output destination38652
Ref: #output-destination38817
Node: CSV output39087
Ref: #csv-output39206
Node: balancesheet39603
Ref: #balancesheet39731
Node: cashflow40383
Ref: #cashflow40500
Node: help41190
Ref: #help41302
Node: incomestatement42139
Ref: #incomestatement42269
Node: info42996
Ref: #info43103
Node: man43465
Ref: #man43562
Node: print43965
Ref: #print44070
Node: register45416
Ref: #register45529
Node: Custom register output50021
Ref: #custom-register-output50152
Node: stats51449
Ref: #stats51555
Node: test52431
Ref: #test52518
Node: ADD-ON COMMANDS52885
Ref: #add-on-commands53021
Node: api54309
Ref: #api54401
Node: autosync54435
Ref: #autosync54550
Node: diff56865
Ref: #diff56975
Node: equity57639
Ref: #equity57753
Node: interest59081
Ref: #interest59198
Node: irr62282
Ref: #irr62395
Node: print-unique64770
Ref: #print-unique64900
Node: rewrite65158
Ref: #rewrite65277
Node: ui65806
Ref: #ui65906
Node: web65947
Ref: #web66035
Node: TROUBLESHOOTING66068
Ref: #troubleshooting66187
Node: Run-time problems66241
Ref: #run-time-problems66384
Node: Known limitations68328
Ref: #known-limitations68471
Node: Depth limiting11489
Ref: #depth-limiting11629
Node: Smart dates11830
Ref: #smart-dates11969
Node: Report intervals12966
Ref: #report-intervals13119
Node: Period expressions13455
Ref: #period-expressions13620
Node: Regular expressions15955
Ref: #regular-expressions16097
Node: QUERIES17580
Ref: #queries17684
Node: COMMANDS21323
Ref: #commands21437
Node: accounts22110
Ref: #accounts22210
Node: activity23192
Ref: #activity23304
Node: add23663
Ref: #add23764
Node: balance26423
Ref: #balance26536
Node: Flat mode29509
Ref: #flat-mode29636
Node: Depth limited balance reports30055
Ref: #depth-limited-balance-reports30258
Node: Multicolumn balance reports30679
Ref: #multicolumn-balance-reports30881
Node: Market value35530
Ref: #market-value35694
Node: Custom balance output36187
Ref: #custom-balance-output36360
Node: Output destination38464
Ref: #output-destination38629
Node: CSV output38899
Ref: #csv-output39018
Node: balancesheet39415
Ref: #balancesheet39543
Node: cashflow40195
Ref: #cashflow40312
Node: help41002
Ref: #help41114
Node: incomestatement41951
Ref: #incomestatement42081
Node: info42808
Ref: #info42915
Node: man43277
Ref: #man43374
Node: print43777
Ref: #print43882
Node: register45228
Ref: #register45341
Node: Custom register output49833
Ref: #custom-register-output49964
Node: stats51261
Ref: #stats51367
Node: test52243
Ref: #test52330
Node: ADD-ON COMMANDS52697
Ref: #add-on-commands52833
Node: api54121
Ref: #api54213
Node: autosync54247
Ref: #autosync54362
Node: diff56677
Ref: #diff56787
Node: equity57451
Ref: #equity57565
Node: interest58893
Ref: #interest59010
Node: irr62094
Ref: #irr62207
Node: print-unique64582
Ref: #print-unique64712
Node: rewrite64970
Ref: #rewrite65089
Node: ui65618
Ref: #ui65718
Node: web65759
Ref: #web65847
Node: TROUBLESHOOTING65880
Ref: #troubleshooting65999
Node: Run-time problems66053
Ref: #run-time-problems66196
Node: Known limitations68140
Ref: #known-limitations68283

End Tag Table

File diff suppressed because it is too large Load Diff

View File

@ -87,34 +87,34 @@ or with the `-f/--file` option:
$ hledger -f /some/file stats
```
The file name `-` (hyphen) means standard input, as usual:
The file name `-` (hyphen) means standard input:
```bash
$ cat some.journal | hledger -f-
```
Usually this file is in hledger's journal format,
but it can also be one of several other formats.
Each one is handled by a built-in "reader", as follows:
Usually the data file is in hledger's journal format,
but it can also be one of several other formats, listed below.
hledger detects the format automatically based on the file extension,
or if that is not recognised, by trying each built-in "reader" in turn:
| Reader:  | Reads: | Used for file extensions:
|---------------------|-----------------------------------------------------|-------------------------------------------
| `journal` | hledger's journal format, also some Ledger journals | `.journal` `.j` `.hledger` `.ledger`
| `timeclock` | timeclock files (precise time logging) | `.timeclock`
| `timedot` | timedot files (approximate time logging) | `.timedot`
| `csv` | comma-separated values (data interchange) | `.csv`
| Reader: | Reads: | Used for file extensions:
|-----------------|-------------------------------------------------------|-------------------------------------------
| `journal` | hledger's journal format, also some Ledger journals | `.journal` `.j` `.hledger` `.ledger`
| `timeclock` | timeclock files (precise time logging) | `.timeclock`
| `timedot` | timedot files (approximate time logging) | `.timedot`
| `csv` | comma-separated values (data interchange) | `.csv`
Usually hledger detects the format automatically based on the file extension,
or if that does not work, by trying each reader in turn.
If needed, eg to ensure correct error messages, you can force a specific reader/format
by prepending it to the file path with a colon. Examples:
If needed (eg to ensure correct error messages when a file has the "wrong" extension),
you can force a specific reader/format by prepending it to the file path with a colon.
Examples:
```bash
$ hledger -f csv:/some/csv-file.dat stats
$ echo 'i 2009/13/1 08:00:00' | hledger print -ftimeclock:-
```
You can specify multiple `-f` options, to read multiple files as one big journal.
Directives in one file will not affect the other files - if you need that,
use the [include directive](#including-other-files) instead.
You can also specify multiple `-f` options, to read multiple files as one big journal.
(Directives in one file will not affect the other files. If you need that,
use the [include directive](#including-other-files) instead.)
## Depth limiting