We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
refresh-cache
1 parent 986c6ec commit cbda936Copy full SHA for cbda936
package.json
@@ -57,7 +57,11 @@
57
"devPlugins": [
58
"@oclif/plugin-help"
59
],
60
- "flexibleTaxonomy": true
+ "flexibleTaxonomy": true,
61
+ "hooks": {
62
+ "plugins:postinstall": "./lib/hooks/refresh-cache.js",
63
+ "plugins:postuninstall": "./lib/hooks/refresh-cache.js"
64
+ }
65
},
66
"repository": "oclif/plugin-autocomplete",
67
"scripts": {
src/hooks/refresh-cache.ts
@@ -0,0 +1,8 @@
1
+import {Hook} from '@oclif/core'
2
+
3
+const hook: Hook<'refresh'> = async function (opts) {
4
+ // this `config` instance already have installed/uninstalled plugins loaded
5
+ await opts.config.runCommand('autocomplete:create')
6
+}
7
8
+export default hook
0 commit comments