Commit Graph

14 Commits

Author SHA1 Message Date
sharkdp 7779d9f622 Allow for non-unicode filenames, closes #225 2020-02-13 08:25:04 +01:00
sharkdp 9b1b3dda14 Only print the header for empty files
Instead of printing
```
───────┬─────────────────────────────────────────────────────────
       │ File: some-file
───────┼─────────────────────────────────────────────────────────
───────┴─────────────────────────────────────────────────────────
```
for empty files, bat will now print
```
───────┬─────────────────────────────────────────────────────────
       │ File: some-file   <EMPTY>
───────┴─────────────────────────────────────────────────────────
```
2019-05-15 22:37:03 +02:00
Daniele Esposti a21ae614e6 Migrated to Rust 2018 2019-03-09 07:43:41 +01:00
Reid Wagner 10c5f79640 Revert "Check result of read_until, and return Error if 0, which indicates EOF was found before delimeter."
This reverts commit 61e888de7f.
2019-02-11 20:33:16 +01:00
Reid Wagner 61e888de7f Check result of read_until, and return Error if 0, which indicates EOF was found before delimeter. 2019-02-07 07:32:28 +01:00
ufuji1984 4ff360669f add quotes around filename
and make it more concise by using map_err
2018-12-11 22:24:52 +01:00
ufuji1984 549e5d7355 Report filename if File::open return Err
From issue #441
2018-12-11 22:24:52 +01:00
sharkdp 25d96da4a2 Add support for UTF-16LE and UTF-16BE 2018-10-07 17:49:38 +02:00
sharkdp f98fc5f06a Simplify access to first line 2018-10-07 15:34:37 +02:00
sharkdp 869cf6368c Add possibility to get first line 2018-10-07 15:34:37 +02:00
sharkdp 078228deac Add unit test for InputFileReader 2018-10-07 15:34:37 +02:00
sharkdp 6d1cc8c2c8 Move read_line functionality to inputfile module 2018-10-07 15:34:37 +02:00
sharkdp d5b0502419 Move get_reader into inputfile module 2018-10-07 15:34:37 +02:00
sharkdp 860f3e9006 Move InputFile to separate module 2018-10-07 15:34:37 +02:00