nushell/crates
Leonhard Kipp eb3c2c9e76
Add comments to next LiteCommand (#2846)
This commit applied adds comments preceding a command to the LiteCommands new
field `comments`.

This can be usefull for example when defining a function with `def`. Nushell
could pick up the comments and display them when the user types `help my_def_func`.

Example
```shell
def my_echo [arg] { echo $arg }
```
The LiteCommand def will now contain the comments `My echo` and `It's much
better :)`.

The comment is not associated with the next command if there is a (or multiple) newline
between them.
Example
```shell

echo 42
```

This new functionality is similar to DocStrings. One might introduce a special
notation for such DocStrings, so that the parser can differentiate better
between discardable comments and usefull documentation.
2021-01-08 06:14:51 +13:00
..
nu_plugin_binaryview Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu_plugin_chart Update dependency rust-embed now that issue with its use of syn has been fixed. (#2880) 2021-01-07 14:33:39 +13:00
nu_plugin_fetch updated dependencies (#2857) 2021-01-07 13:38:22 +13:00
nu_plugin_from_bson Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu_plugin_from_sqlite Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu_plugin_inc Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu_plugin_match Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu_plugin_post Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu_plugin_ps Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu_plugin_s3 Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu_plugin_selector Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu_plugin_start Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu_plugin_sys Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu_plugin_textview updated dependencies (#2857) 2021-01-07 13:38:22 +13:00
nu_plugin_to_bson Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu_plugin_to_sqlite Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu_plugin_tree Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu_plugin_xpath Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu-cli Add comments to next LiteCommand (#2846) 2021-01-08 06:14:51 +13:00
nu-data Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu-errors Document lexer (#2865) 2021-01-07 16:03:00 +13:00
nu-json updated dependencies (#2857) 2021-01-07 13:38:22 +13:00
nu-parser Add comments to next LiteCommand (#2846) 2021-01-08 06:14:51 +13:00
nu-plugin Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu-protocol Document lexer (#2865) 2021-01-07 16:03:00 +13:00
nu-source Document lexer (#2865) 2021-01-07 16:03:00 +13:00
nu-stream Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu-table Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu-test-support Bump to 0.25.1 for the hotfix release (#2870) 2021-01-06 15:16:08 +13:00
nu-value-ext updated dependencies (#2857) 2021-01-07 13:38:22 +13:00