motia 0.13.1-beta.162 → 0.13.1-beta.163-584961

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/dist/cjs/cli.d.ts CHANGED
@@ -1,3 +1,3 @@
1
1
  #!/usr/bin/env node
2
- import './cloud';
2
+ export {};
3
3
  //# sourceMappingURL=cli.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../../src/cli.ts"],"names":[],"mappings":";AAIA,OAAO,SAAS,CAAA"}
1
+ {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../../src/cli.ts"],"names":[],"mappings":""}
package/dist/cjs/cli.js CHANGED
@@ -1,20 +1,22 @@
1
1
  #!/usr/bin/env node
2
2
  "use strict";
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
- const core_1 = require("@motiadev/core");
5
4
  const commander_1 = require("commander");
6
- require("./cloud");
7
5
  const config_utils_1 = require("./cloud/config-utils");
8
- const load_motia_config_1 = require("./load-motia-config");
9
6
  const analytics_1 = require("./utils/analytics");
10
7
  const version_1 = require("./version");
11
8
  const defaultPort = 3000;
12
9
  const defaultHost = '0.0.0.0';
13
- require('dotenv/config');
14
- require('ts-node').register({
15
- transpileOnly: true,
16
- compilerOptions: { module: 'commonjs' },
17
- });
10
+ const registerTsNode = () => {
11
+ require('dotenv/config');
12
+ require('ts-node').register({
13
+ transpileOnly: true,
14
+ compilerOptions: { module: 'commonjs' },
15
+ });
16
+ };
17
+ const registerCloudCommands = () => {
18
+ require('./cloud');
19
+ };
18
20
  commander_1.program
19
21
  .command('version')
20
22
  .description('Display detailed version information')
@@ -27,7 +29,7 @@ commander_1.program
27
29
  .description('Create a new motia project')
28
30
  .option('-t, --template <template>', 'The template to use for your project')
29
31
  .option('-p, --plugin', 'Create a plugin project')
30
- .option('-i, --interactive', 'Use interactive prompts to create project') // it's default
32
+ .option('-i, --interactive', 'Use interactive prompts to create project')
31
33
  .action((projectName, options) => {
32
34
  const mergedArgs = { ...options, name: projectName };
33
35
  return (0, config_utils_1.handler)(async (arg, context) => {
@@ -52,6 +54,7 @@ commander_1.program
52
54
  .command('generate-types')
53
55
  .description('Generate types.d.ts file for your project')
54
56
  .action((0, analytics_1.wrapAction)(async () => {
57
+ registerTsNode();
55
58
  const { generateTypes } = require('./generate-types');
56
59
  await generateTypes(process.cwd());
57
60
  process.exit(0);
@@ -74,6 +77,7 @@ commander_1.program
74
77
  .option('-m, --mermaid', 'Enable mermaid diagram generation')
75
78
  .option('--motia-dir <path>', 'Path where .motia folder will be created')
76
79
  .action((0, analytics_1.wrapAction)(async (arg) => {
80
+ registerTsNode();
77
81
  if (arg.debug) {
78
82
  console.log('🔍 Debug logging enabled');
79
83
  process.env.LOG_LEVEL = 'debug';
@@ -92,6 +96,7 @@ commander_1.program
92
96
  .option('-d, --debug', 'Enable debug logging')
93
97
  .option('--motia-dir <path>', 'Path where .motia folder will be created')
94
98
  .action((0, analytics_1.wrapAction)(async (arg) => {
99
+ registerTsNode();
95
100
  if (arg.debug) {
96
101
  console.log('🔍 Debug logging enabled');
97
102
  process.env.LOG_LEVEL = 'debug';
@@ -142,13 +147,16 @@ generate
142
147
  .option('-v, --version <version>', 'Version for the OpenAPI document. Defaults to 1.0.0', '1.0.0')
143
148
  .option('-o, --output <output>', 'Output file for the OpenAPI document. Defaults to openapi.json', 'openapi.json')
144
149
  .action((0, analytics_1.wrapAction)(async (options) => {
150
+ registerTsNode();
151
+ const { MemoryStreamAdapterManager } = require('@motiadev/core');
152
+ const { loadMotiaConfig } = require('./load-motia-config');
145
153
  const { generateLockedData } = require('./generate-locked-data');
146
154
  const { generateOpenApi } = require('./openapi/generate');
147
155
  const baseDir = process.cwd();
148
- const appConfig = await (0, load_motia_config_1.loadMotiaConfig)(baseDir);
156
+ const appConfig = await loadMotiaConfig(baseDir);
149
157
  const lockedData = await generateLockedData({
150
158
  projectDir: baseDir,
151
- streamAdapter: new core_1.MemoryStreamAdapterManager(),
159
+ streamAdapter: new MemoryStreamAdapterManager(),
152
160
  streamAuth: appConfig.streamAuth,
153
161
  });
154
162
  const apiSteps = lockedData.apiSteps();
@@ -184,6 +192,7 @@ docker
184
192
  await build(arg.projectName);
185
193
  process.exit(0);
186
194
  }));
195
+ registerCloudCommands();
187
196
  commander_1.program.version(version_1.version, '-V, --version', 'Output the current version');
188
197
  commander_1.program.parseAsync(process.argv).catch(() => {
189
198
  process.exit(1);
package/dist/esm/cli.d.ts CHANGED
@@ -1,3 +1,3 @@
1
1
  #!/usr/bin/env node
2
- import './cloud';
2
+ export {};
3
3
  //# sourceMappingURL=cli.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../../src/cli.ts"],"names":[],"mappings":";AAIA,OAAO,SAAS,CAAA"}
1
+ {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../../src/cli.ts"],"names":[],"mappings":""}
package/dist/esm/cli.js CHANGED
@@ -1,18 +1,20 @@
1
1
  #!/usr/bin/env node
2
- import { MemoryStreamAdapterManager } from '@motiadev/core';
3
2
  import { program } from 'commander';
4
- import './cloud';
5
3
  import { handler } from './cloud/config-utils';
6
- import { loadMotiaConfig } from './load-motia-config';
7
4
  import { wrapAction } from './utils/analytics';
8
5
  import { version } from './version';
9
6
  const defaultPort = 3000;
10
7
  const defaultHost = '0.0.0.0';
11
- require('dotenv/config');
12
- require('ts-node').register({
13
- transpileOnly: true,
14
- compilerOptions: { module: 'commonjs' },
15
- });
8
+ const registerTsNode = () => {
9
+ require('dotenv/config');
10
+ require('ts-node').register({
11
+ transpileOnly: true,
12
+ compilerOptions: { module: 'commonjs' },
13
+ });
14
+ };
15
+ const registerCloudCommands = () => {
16
+ require('./cloud');
17
+ };
16
18
  program
17
19
  .command('version')
18
20
  .description('Display detailed version information')
@@ -25,7 +27,7 @@ program
25
27
  .description('Create a new motia project')
26
28
  .option('-t, --template <template>', 'The template to use for your project')
27
29
  .option('-p, --plugin', 'Create a plugin project')
28
- .option('-i, --interactive', 'Use interactive prompts to create project') // it's default
30
+ .option('-i, --interactive', 'Use interactive prompts to create project')
29
31
  .action((projectName, options) => {
30
32
  const mergedArgs = { ...options, name: projectName };
31
33
  return handler(async (arg, context) => {
@@ -50,6 +52,7 @@ program
50
52
  .command('generate-types')
51
53
  .description('Generate types.d.ts file for your project')
52
54
  .action(wrapAction(async () => {
55
+ registerTsNode();
53
56
  const { generateTypes } = require('./generate-types');
54
57
  await generateTypes(process.cwd());
55
58
  process.exit(0);
@@ -72,6 +75,7 @@ program
72
75
  .option('-m, --mermaid', 'Enable mermaid diagram generation')
73
76
  .option('--motia-dir <path>', 'Path where .motia folder will be created')
74
77
  .action(wrapAction(async (arg) => {
78
+ registerTsNode();
75
79
  if (arg.debug) {
76
80
  console.log('🔍 Debug logging enabled');
77
81
  process.env.LOG_LEVEL = 'debug';
@@ -90,6 +94,7 @@ program
90
94
  .option('-d, --debug', 'Enable debug logging')
91
95
  .option('--motia-dir <path>', 'Path where .motia folder will be created')
92
96
  .action(wrapAction(async (arg) => {
97
+ registerTsNode();
93
98
  if (arg.debug) {
94
99
  console.log('🔍 Debug logging enabled');
95
100
  process.env.LOG_LEVEL = 'debug';
@@ -140,6 +145,9 @@ generate
140
145
  .option('-v, --version <version>', 'Version for the OpenAPI document. Defaults to 1.0.0', '1.0.0')
141
146
  .option('-o, --output <output>', 'Output file for the OpenAPI document. Defaults to openapi.json', 'openapi.json')
142
147
  .action(wrapAction(async (options) => {
148
+ registerTsNode();
149
+ const { MemoryStreamAdapterManager } = require('@motiadev/core');
150
+ const { loadMotiaConfig } = require('./load-motia-config');
143
151
  const { generateLockedData } = require('./generate-locked-data');
144
152
  const { generateOpenApi } = require('./openapi/generate');
145
153
  const baseDir = process.cwd();
@@ -182,6 +190,7 @@ docker
182
190
  await build(arg.projectName);
183
191
  process.exit(0);
184
192
  }));
193
+ registerCloudCommands();
185
194
  program.version(version, '-V, --version', 'Output the current version');
186
195
  program.parseAsync(process.argv).catch(() => {
187
196
  process.exit(1);
@@ -1,3 +1,3 @@
1
1
  #!/usr/bin/env node
2
- import './cloud';
2
+ export {};
3
3
  //# sourceMappingURL=cli.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../../src/cli.ts"],"names":[],"mappings":";AAIA,OAAO,SAAS,CAAA"}
1
+ {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../../src/cli.ts"],"names":[],"mappings":""}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "motia",
3
3
  "description": "Build production-grade backends with a single primitive. APIs, background jobs, Queues, Workflows, and AI agents - unified in one system with built-in State management, Streaming, and Observability.",
4
- "version": "0.13.1-beta.162",
4
+ "version": "0.13.1-beta.163-584961",
5
5
  "license": "Elastic-2.0",
6
6
  "repository": {
7
7
  "type": "git",
@@ -49,11 +49,11 @@
49
49
  "table": "^6.9.0",
50
50
  "ts-node": "^10.9.2",
51
51
  "zod": "^4.1.12",
52
- "@motiadev/adapter-redis-state": "0.13.1-beta.162",
53
- "@motiadev/core": "0.13.1-beta.162",
54
- "@motiadev/stream-client-node": "0.13.1-beta.162",
55
- "@motiadev/workbench": "0.13.1-beta.162",
56
- "@motiadev/adapter-redis-streams": "0.13.1-beta.162"
52
+ "@motiadev/adapter-redis-state": "0.13.1-beta.163-584961",
53
+ "@motiadev/adapter-redis-streams": "0.13.1-beta.163-584961",
54
+ "@motiadev/core": "0.13.1-beta.163-584961",
55
+ "@motiadev/workbench": "0.13.1-beta.163-584961",
56
+ "@motiadev/stream-client-node": "0.13.1-beta.163-584961"
57
57
  },
58
58
  "devDependencies": {
59
59
  "@amplitude/analytics-types": "^2.9.2",