nushell/docs/commands/from-ini.md
Bruno Heridet 6826a9aeac
doc: add more from command pages (#1778)
* doc: add from-url command page

* doc: add missing link to existing from-xml page.

* doc: add from-ini command page
2020-05-14 05:23:33 +12:00

756 B

from ini

Converts ini data into table. Use this when nushell cannot determine the input file extension.

Example

Let's say we have the following .txt file :

> open sample.txt
[SectionOne]

key = value
integer = 1234
string1 = 'Case 1'

This file is actually a ini file, but the file extension isn't .ini. That's okay, we can use the from ini command :

> open sample.txt | from ini | get SectionOne
━━━━━━━┯━━━━━━━━━┯━━━━━━━━━━
 key   │ integer │ string1
───────┼─────────┼──────────
 value │ 1234'Case 1'
━━━━━━━┷━━━━━━━━━┷━━━━━━━━━━