Skip to content

Commit 2c19779

Browse files
committed
;doc: Document new encoding option
1 parent 0512800 commit 2c19779

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

hledger/hledger.m4.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3210,6 +3210,7 @@ The following kinds of rule can appear in the rules file, in any order.
32103210
| | |
32113211
|-------------------------------------------------|------------------------------------------------------------------------------------------------|
32123212
| [**`source`**](#source) | optionally declare which file to read data from |
3213+
| [**`encoding`**](#encoding) | optionally declare which encoding the data has |
32133214
| [**`separator`**](#separator) | declare the field separator, instead of relying on file extension |
32143215
| [**`skip`**](#skip) | skip one or more header lines at start of file |
32153216
| [**`date-format`**](#date-format) | declare how to parse CSV dates/date-times |
@@ -3256,6 +3257,19 @@ source Checking1*.csv
32563257

32573258
See also ["Working with CSV > Reading files specified by rule"](#reading-files-specified-by-rule).
32583259

3260+
## `encoding`
3261+
3262+
```rules
3263+
encoding ENCODING
3264+
```
3265+
3266+
Specifying `encoding` followed by a valid encoding tells HLedger how to convert a
3267+
csv to be able to make use of it.
3268+
This is most often useful when getting a csv from a bank as they are sometimes
3269+
in an old encoding.
3270+
3271+
If none is given, `utf8` is assumed.
3272+
32593273
## `separator`
32603274

32613275
You can use the `separator` rule to read other kinds of

0 commit comments

Comments
 (0)