Silly NuShell plugin to read Minecraft NBT
at main 50 lines 838 B view raw view rendered
1 2# nu_plugin_nbt 3 4Read Minecraft nbt in Nushell. 5 6## Installation 7 8### Shell 9 10Build / download the plugin and run `plugin add`. 11 12```nu 13plugin add path/to/nu_plugin_nbt 14``` 15 16Then to use it in your shell, run `plugin use`. 17 18```nu 19plugin use nu_plugin_nbt 20``` 21 22### Script 23 24Build / download the plugin binary. When invoking your script pass its path with `--plugin`. 25 26```nu 27nu --plugin path/to/nu_plugin_nbt my_script.nu 28``` 29 30## Usage 31 32If your file ends in .nbt, nushell will pick nu_plugin_nbt to open it. 33 34```nu 35open data.nbt 36``` 37 38Otherwise, open it raw and pipe it to `from nbt`. 39 40```nu 41open --raw data.dat | from nbt 42``` 43 44### Preserve Data Types 45 46Passing `--with-tags` to `from nbt` will tag data with NBT types. 47 48This is useful if you need to convert back into NBT at some point. Note that this plugin does not handle writing (yet). 49 50