@oclif/plugin-update 4.6.46 → 4.6.47

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -56,7 +56,7 @@ EXAMPLES
56
56
  $ oclif-example update --available
57
57
  ```
58
58
 
59
- _See code: [src/commands/update.ts](https://github.com/oclif/plugin-update/blob/v4.6.46/src/commands/update.ts)_
59
+ _See code: [src/commands/update.ts](https://github.com/oclif/plugin-update/blob/v4.6.47/src/commands/update.ts)_
60
60
  <!-- commandsstop -->
61
61
 
62
62
  # Contributing
@@ -1,7 +1,7 @@
1
1
  import makeDebug from 'debug';
2
2
  import { spawn } from 'node:child_process';
3
3
  import { existsSync } from 'node:fs';
4
- import { open, stat, writeFile } from 'node:fs/promises';
4
+ import { mkdir, open, stat, writeFile } from 'node:fs/promises';
5
5
  import { join } from 'node:path';
6
6
  import { touch } from '../util.js';
7
7
  const debug = makeDebug('cli:updater');
@@ -28,6 +28,8 @@ export const init = async function (opts) {
28
28
  [config.scopedEnvVarKey('SKIP_ANALYTICS')]: '1',
29
29
  [config.scopedEnvVarKey('TIMESTAMPS')]: '1',
30
30
  };
31
+ // Ensure the cache directory exists
32
+ await mkdir(config.cacheDir, { recursive: true });
31
33
  async function autoupdateNeeded() {
32
34
  try {
33
35
  const m = await mtime(autoupdatefile);
@@ -106,5 +106,5 @@
106
106
  ]
107
107
  }
108
108
  },
109
- "version": "4.6.46"
109
+ "version": "4.6.47"
110
110
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@oclif/plugin-update",
3
- "version": "4.6.46",
3
+ "version": "4.6.47",
4
4
  "author": "Salesforce",
5
5
  "bugs": "https://github.com/oclif/plugin-update/issues",
6
6
  "dependencies": {