mirror of
https://github.com/nushell/nushell.git
synced 2024-12-27 17:39:15 +01:00
c9c6bd4836
``` > [ [ msg, labels, span]; ["The message", "Helpful message here", ([[start, end]; [0, 141]])] ] | error make error: The message ┌─ shell:1:1 │ 1 │ ╭ [ 2 │ │ [ msg, labels, span]; 3 │ │ ["The message", "Helpful message here", ([[start, end]; [0, 141]])] │ ╰─────────────────────────────────────────────────────────────────────^ Helpful message here ``` Adding a more flexible approach for creating error values. One use case, for instance is the idea of a test framework. A failed assertion instead of printing to the screen it could create tables with more details of the failed assertion and pass it to this command for making a full fledge error that Nu can show. This can (and should) be extended for capturing error values as well in the pipeline. One could also use it for inspection. For example: `.... | error inspect { # inspection here }` or "error handling" as well, like so: `.... | error capture { fix here }` However, we start here only with `error make` that creates an error value for you with limited support for the time being. |
||
---|---|---|
.. | ||
nu_plugin_binaryview | ||
nu_plugin_chart | ||
nu_plugin_from_bson | ||
nu_plugin_from_mp4 | ||
nu_plugin_from_sqlite | ||
nu_plugin_inc | ||
nu_plugin_match | ||
nu_plugin_query_json | ||
nu_plugin_s3 | ||
nu_plugin_selector | ||
nu_plugin_start | ||
nu_plugin_textview | ||
nu_plugin_to_bson | ||
nu_plugin_to_sqlite | ||
nu_plugin_tree | ||
nu_plugin_xpath | ||
nu-ansi-term | ||
nu-cli | ||
nu-command | ||
nu-completion | ||
nu-data | ||
nu-engine | ||
nu-errors | ||
nu-json | ||
nu-parser | ||
nu-path | ||
nu-plugin | ||
nu-pretty-hex | ||
nu-protocol | ||
nu-serde | ||
nu-source | ||
nu-stream | ||
nu-table | ||
nu-test-support | ||
nu-value-ext | ||
README.md |
Nushell core libraries and plugins
These sub-crates form both the foundation for Nu and a set of plugins which extend Nu with additional functionality.
Foundational libraries are split into two kinds of crates:
- Core crates - those crates that work together to build the Nushell language engine
- Support crates - a set of crates that support the engine with additional features like JSON support, ANSI support, and more.
Plugins are likewise also split into two types:
- Core plugins - plugins that provide part of the default experience of Nu, including access to the system properties, processes, and web-connectivity features.
- Extra plugins - these plugins run a wide range of differnt capabilities like working with different file types, charting, viewing binary data, and more.