Skip to content

Commit 5ec3fae

Browse files
committed
add plugin list change
1 parent 69a45b3 commit 5ec3fae

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed

blog/2024-11-12-nushell_0_100_0.md

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ As part of this release, we also publish a set of optional plugins you can insta
2828
- [_Changes_](#changes-toc)
2929
- [_Additions_](#additions-toc)
3030
- [_Breaking changes_](#breaking-changes-toc)
31+
- [_`plugin list`_](#plugin-list-toc)
3132
- [_Deprecations_](#deprecations-toc)
3233
- [_Removals_](#removals-toc)
3334
- [_Bug fixes and other changes_](#bug-fixes-and-other-changes-toc)
@@ -146,6 +147,35 @@ Thanks to [@sgvictorino](https://github.com/sgvictorino) in [#14095](https://git
146147
{ |a $a } # now errors
147148
```
148149

150+
### `plugin list` [[toc](#table-of-content)]
151+
152+
The `plugin list` command has been changed in [#14085](https://github.com/nushell/nushell/pull/14085) to consider both the plugins currently present in the engine state as well as the plugins stored in the registry file. Changes made by `plugin add` and `plugin rm` should now be more obvious.
153+
154+
As part of this change, the `is_running` column has been replaced by a `status` column, which now displays many possible states a plugin can be in:
155+
156+
- `added`: The plugin is present in the plugin registry file, but not in the engine.
157+
- `loaded`: The plugin is present both in the plugin registry file and in the engine, but is not running.
158+
- `running`: The plugin is currently running, and the `pid` column should contain its process ID.
159+
- `modified`: The plugin state present in the plugin registry file is different from the state in the engine.
160+
- `removed`: The plugin is still loaded in the engine, but is not present in the plugin registry file.
161+
- `invalid`: The data in the plugin registry file couldn't be deserialized, and the plugin most likely needs to be added again.
162+
163+
`running` always has high priority as a state, so other statuses won't be visible if a plugin is currently running. This means that
164+
165+
```nushell
166+
# 0.99.0
167+
plugin list | where is_running
168+
```
169+
170+
can now always be replaced by:
171+
172+
```nushell
173+
# 0.100.0
174+
plugin list | where status == running
175+
```
176+
177+
In case you want to avoid loading the plugin registry file (e.g. for performance reasons), you can now use the `--engine` flag to do so. Similarly, the `--registry` flag will only display the contents of the registry, without comparing them against the state of the engine (but all plugins will appear as `added`). The `--plugin-config` flag is now supported to allow use of a separate plugin registry file, identically to the other `plugin` commands.
178+
149179
## Deprecations [[toc](#table-of-content)]
150180

151181
## Removals [[toc](#table-of-content)]

0 commit comments

Comments
 (0)