Skip to content

Commit

Permalink
Filter out deprecated Kap plugins from the plugin list (wulkano#658)
Browse files Browse the repository at this point in the history
Closes wulkano#645 

Co-authored-by: Sindre Sorhus <[email protected]>
  • Loading branch information
dotconnor and sindresorhus committed Apr 19, 2019
1 parent 7d1dd19 commit 8230497
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
8 changes: 8 additions & 0 deletions docs/plugins.md
Original file line number Diff line number Diff line change
Expand Up @@ -122,3 +122,11 @@ config: {
```

[Read more about JSON Schema](https://spacetelescope.github.io/understanding-json-schema/)

## Removing your Kap plugin

Since npm doesn't allow you to remove packages from the registery, Kap filters out deprecated packages in the plugin list.

When you are ready to retire your Kap plugin, simply run `npm deprecate kap-plugin "Deprecated"`.

[Read more about the `npm-deprecate` command](https://docs.npmjs.com/cli/deprecate)
2 changes: 1 addition & 1 deletion main/common/plugins.js
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ class Plugins {
}

async getFromNpm() {
const url = 'https://api.npms.io/v2/search?q=keywords:kap-plugin';
const url = 'https://api.npms.io/v2/search?q=keywords:kap-plugin+not:deprecated';
const response = await got(url, {json: true});
const installed = this._pluginNames();

Expand Down

0 comments on commit 8230497

Please sign in to comment.