@pikku/cli 0.7.3 → 0.7.4

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/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # @pikku/cli
2
2
 
3
+ ## 0.7.4
4
+
5
+ ### Patch Changes
6
+
7
+ - 6af8a19: fix: always write functions meta data
8
+ - Updated dependencies [6af8a19]
9
+ - @pikku/core@0.7.7
10
+
3
11
  ## 0.7.3
4
12
 
5
13
  ### Patch Changes
@@ -3,16 +3,14 @@ import { InspectorState } from '@pikku/inspector'
3
3
  import { logCommandInfoAndTime, writeFileInDir } from '../src/utils/utils.js'
4
4
 
5
5
  export const pikkuFunctions = async (
6
- cliConfig: PikkuCLIConfig,
7
- visitState: InspectorState
6
+ { functionsMetaFile }: PikkuCLIConfig,
7
+ { functions }: InspectorState
8
8
  ) => {
9
9
  return await logCommandInfoAndTime(
10
- 'Finding Pikku functions',
11
- 'Found Pikku functions',
12
- [true],
10
+ 'Serializing Pikku functions',
11
+ 'Serialized Pikku functions',
12
+ [false],
13
13
  async () => {
14
- const { functionsMetaFile } = cliConfig
15
- const { functions } = visitState
16
14
  await writeFileInDir(
17
15
  functionsMetaFile,
18
16
  `import { pikkuState } from '@pikku/core'\npikkuState('function', 'meta', ${JSON.stringify(functions.meta, null, 2)})`
@@ -1,3 +1,3 @@
1
1
  import { PikkuCLIConfig } from '../src/pikku-cli-config.js';
2
2
  import { InspectorState } from '@pikku/inspector';
3
- export declare const pikkuFunctions: (cliConfig: PikkuCLIConfig, visitState: InspectorState) => Promise<boolean>;
3
+ export declare const pikkuFunctions: ({ functionsMetaFile }: PikkuCLIConfig, { functions }: InspectorState) => Promise<boolean>;
@@ -1,8 +1,6 @@
1
1
  import { logCommandInfoAndTime, writeFileInDir } from '../src/utils/utils.js';
2
- export const pikkuFunctions = async (cliConfig, visitState) => {
3
- return await logCommandInfoAndTime('Finding Pikku functions', 'Found Pikku functions', [true], async () => {
4
- const { functionsMetaFile } = cliConfig;
5
- const { functions } = visitState;
2
+ export const pikkuFunctions = async ({ functionsMetaFile }, { functions }) => {
3
+ return await logCommandInfoAndTime('Serializing Pikku functions', 'Serialized Pikku functions', [false], async () => {
6
4
  await writeFileInDir(functionsMetaFile, `import { pikkuState } from '@pikku/core'\npikkuState('function', 'meta', ${JSON.stringify(functions.meta, null, 2)})`);
7
5
  });
8
6
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pikku/cli",
3
- "version": "0.7.3",
3
+ "version": "0.7.4",
4
4
  "author": "yasser.fadl@gmail.com",
5
5
  "license": "MIT",
6
6
  "bin": {
@@ -22,7 +22,7 @@
22
22
  },
23
23
  "dependencies": {
24
24
  "@openapi-contrib/json-schema-to-openapi-schema": "^3.0.2",
25
- "@pikku/core": "^0.7.5",
25
+ "@pikku/core": "^0.7.7",
26
26
  "@pikku/inspector": "^0.7.4",
27
27
  "@types/cookie": "^0.6.0",
28
28
  "@types/uuid": "^10.0.0",