docs/commands: add from.md, update subcommands (#1712)

This adds a top-level document for the new `from` command, with a list of links of all the subcommands.

All the from-* subcommands keep their filename, but the content is updated to use the new subcommand syntax.

Needs matching update for to*

Ref #1709
This commit is contained in:
Jörn Zaefferer
2020-05-04 23:01:31 +02:00
committed by GitHub
parent 3201c90647
commit 8ab2b92405
11 changed files with 111 additions and 59 deletions

View File

@ -1,8 +1,8 @@
# from-json
# from json
Parse text as `.json` and create table. Use this when nushell cannot dertermine the input file extension.
Syntax: `from-json {flags}`
Syntax: `from json {flags}`
### Flags:
@ -16,7 +16,7 @@ Syntax: `from-json {flags}`
> open command_from-json
[
{
title: "from-json",
title: "from json",
type: "command",
flags: true
}
@ -24,10 +24,10 @@ Syntax: `from-json {flags}`
```
```shell
> open command_from-json | from-json
> open command_from-json | from json
━━━━━━━━━━━┯━━━━━━━━━┯━━━━━━━
title │ type │ flags
───────────┼─────────┼───────
from-json │ command │ Yes
from json │ command │ Yes
━━━━━━━━━━━┷━━━━━━━━━┷━━━━━━━
```
```