@cimplify/cli 0.13.4 → 0.13.5

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.
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import { gitDetectRoot, gitCurrentBranch, gitCurrentSha, gitStatusPorcelain } from './chunk-MLVBE5V2.mjs';
3
3
  import { parseEnvFile } from './chunk-RU53TQLZ.mjs';
4
- import { package_default } from './chunk-7NUSJVN3.mjs';
4
+ import { package_default } from './chunk-5YVMA7A5.mjs';
5
5
  import { parseArgs } from './chunk-5KYR6WJB.mjs';
6
6
  import { readAuthOrNull, readProjectLinkOrNull, readProjectState } from './chunk-6CHBU7O4.mjs';
7
7
  import { bold, dim, yellow, green, info, result, red } from './chunk-4O4G2CDE.mjs';
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
- import { TEMPLATES } from './chunk-VCDGYXFU.mjs';
3
- import { package_default } from './chunk-7NUSJVN3.mjs';
2
+ import { TEMPLATES } from './chunk-BDC7XQIL.mjs';
3
+ import { package_default } from './chunk-5YVMA7A5.mjs';
4
4
 
5
5
  // src/dispatcher.ts
6
6
  var VERSION = package_default.version ?? "unknown";
@@ -149,17 +149,17 @@ var COMMANDS = {
149
149
  status: () => import('./status-52HG63FE.mjs'),
150
150
  dev: () => import('./dev-L3W6UXYN.mjs'),
151
151
  mock: () => import('./mock-CAWNXSGC.mjs'),
152
- introspect: () => import('./introspect-SDHD3PVX.mjs'),
152
+ introspect: () => import('./introspect-3OYRCVUF.mjs'),
153
153
  inspect: () => import('./inspect-MGVG4Z44.mjs'),
154
- doctor: () => import('./doctor-E6JH4VSN.mjs'),
155
- lint: () => import('./lint-NM3APP7L.mjs'),
156
- explain: () => import('./explain-SZPLL5MP.mjs'),
154
+ doctor: () => import('./doctor-6NI2XNTD.mjs'),
155
+ lint: () => import('./lint-EYKIQ6RO.mjs'),
156
+ explain: () => import('./explain-HPRJBFHS.mjs'),
157
157
  assets: () => import('./assets-OEY6FHHZ.mjs'),
158
158
  repo: () => import('./repo-IE5IOLR5.mjs'),
159
- list: () => import('./list-W5JABY7B.mjs'),
160
- add: () => import('./add-542NLKYG.mjs'),
161
- update: () => import('./update-447FR363.mjs'),
162
- upgrade: () => import('./update-447FR363.mjs'),
159
+ list: () => import('./list-QNEUCCP5.mjs'),
160
+ add: () => import('./add-NZ47GUMD.mjs'),
161
+ update: () => import('./update-47HG7LN7.mjs'),
162
+ upgrade: () => import('./update-47HG7LN7.mjs'),
163
163
  "auth-step-up": () => import('./auth-step-up-ALEUQUCE.mjs')
164
164
  };
165
165
  var COMMAND_PREFIXES = {
@@ -1,8 +1,8 @@
1
1
  #!/usr/bin/env node
2
- import { gatherIntrospection } from './chunk-HJQ6PF5N.mjs';
2
+ import { gatherIntrospection } from './chunk-GOTWRZVM.mjs';
3
3
  import './chunk-MLVBE5V2.mjs';
4
4
  import './chunk-RU53TQLZ.mjs';
5
- import './chunk-7NUSJVN3.mjs';
5
+ import './chunk-5YVMA7A5.mjs';
6
6
  import { parseArgs, flagBool } from './chunk-5KYR6WJB.mjs';
7
7
  import { SDK_ENV_API_URL, DEFAULT_API_BASE_URL, ApiClient, ENV_API_BASE_URL } from './chunk-TOQGLBWF.mjs';
8
8
  import { readAuthOrNull } from './chunk-6CHBU7O4.mjs';
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { package_default } from './chunk-7NUSJVN3.mjs';
2
+ import { package_default } from './chunk-5YVMA7A5.mjs';
3
3
  import { parseArgs } from './chunk-5KYR6WJB.mjs';
4
4
  import { bold, dim, info, result, CliError, CLI_ERROR_CODE } from './chunk-4O4G2CDE.mjs';
5
5
 
@@ -1,8 +1,8 @@
1
1
  #!/usr/bin/env node
2
- export { run as default, extractMockSeed, gatherIntrospection, renderIntrospection } from './chunk-HJQ6PF5N.mjs';
2
+ export { run as default, extractMockSeed, gatherIntrospection, renderIntrospection } from './chunk-GOTWRZVM.mjs';
3
3
  import './chunk-MLVBE5V2.mjs';
4
4
  import './chunk-RU53TQLZ.mjs';
5
- import './chunk-7NUSJVN3.mjs';
5
+ import './chunk-5YVMA7A5.mjs';
6
6
  import './chunk-5KYR6WJB.mjs';
7
7
  import './chunk-6CHBU7O4.mjs';
8
8
  import './chunk-4O4G2CDE.mjs';
@@ -473,6 +473,13 @@ function subjectName(node) {
473
473
  }
474
474
  return null;
475
475
  }
476
+ function normalizedSubjectName(name) {
477
+ return name.replace(/([A-Z]+)([A-Z][a-z])/g, "$1_$2").replace(/([a-z\d])([A-Z])/g, "$1_$2").replace(/[^A-Za-z\d]+/g, "_").toLowerCase();
478
+ }
479
+ function subjectMatches(node, pattern) {
480
+ const name = subjectName(node);
481
+ return name !== null && pattern !== void 0 && (pattern.test(name) || pattern.test(normalizedSubjectName(name)));
482
+ }
476
483
  function sourceMatches(source, primitive) {
477
484
  return primitive.sources.some((pattern) => sourcePatternMatches(source, pattern));
478
485
  }
@@ -784,11 +791,9 @@ function analyzeSource(source, file, compiledRules, maxDiagnostics) {
784
791
  if (!path4.parentPath.isJSXElement() && !path4.parentPath.isJSXFragment()) return;
785
792
  const expression = unwrapExpression(path4.node.expression);
786
793
  if (!expression || !t.isExpression(expression)) return;
787
- const name = subjectName(expression);
788
- if (!name) return;
789
794
  for (const compiled of compiledRules) {
790
795
  const primitive = compiled.rule.primitive;
791
- if (primitive.kind !== "required-wrapper-call" || primitive.context !== "jsx-child" || !hasActivatingImport(importSources, primitive.activationImports) || !compiled.subjectPattern?.test(name)) {
796
+ if (primitive.kind !== "required-wrapper-call" || primitive.context !== "jsx-child" || !hasActivatingImport(importSources, primitive.activationImports) || !subjectMatches(expression, compiled.subjectPattern)) {
792
797
  continue;
793
798
  }
794
799
  const fix = compiled.rule.fix ? jsxWrapperFix(ast, source, path4.node, expression, primitive, imports, path4) : void 0;
@@ -808,8 +813,7 @@ function analyzeSource(source, file, compiledRules, maxDiagnostics) {
808
813
  if (t.isCallExpression(value) && t.isIdentifier(value.callee) && primitive.wrapper.syntax === "call" && bindingMatches(value.callee.name, primitive.wrapper.imports, imports)) {
809
814
  continue;
810
815
  }
811
- const name = subjectName(value);
812
- if (name && compiled.subjectPattern?.test(name)) {
816
+ if (subjectMatches(value, compiled.subjectPattern)) {
813
817
  emit(diagnostic(file, compiled.rule, value));
814
818
  }
815
819
  }
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { REGISTRY_INDEX } from './chunk-VCDGYXFU.mjs';
2
+ import { REGISTRY_INDEX } from './chunk-BDC7XQIL.mjs';
3
3
  import { parseArgs, flagBool } from './chunk-5KYR6WJB.mjs';
4
4
  import { CliError, CLI_ERROR_CODE, info, bold, dim, green, result } from './chunk-4O4G2CDE.mjs';
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { package_default } from './chunk-7NUSJVN3.mjs';
2
+ import { package_default } from './chunk-5YVMA7A5.mjs';
3
3
  import { promptYesNo } from './chunk-5ZQURRIM.mjs';
4
4
  import { parseArgs, flagBool, flagString } from './chunk-5KYR6WJB.mjs';
5
5
  import { success, bold, info, dim, result, failure, CliError, CLI_ERROR_CODE, step, isJsonMode } from './chunk-4O4G2CDE.mjs';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cimplify/cli",
3
- "version": "0.13.4",
3
+ "version": "0.13.5",
4
4
  "description": "Cimplify CLI — deploy, manage env vars, link projects, and scaffold storefronts",
5
5
  "keywords": [
6
6
  "cimplify",
@@ -41,7 +41,7 @@
41
41
  "@babel/parser": "^8.0.4",
42
42
  "@babel/traverse": "^8.0.4",
43
43
  "@babel/types": "^8.0.4",
44
- "@cimplify/sdk": "^0.100.4",
44
+ "@cimplify/sdk": "^0.100.5",
45
45
  "re2js": "^1.4.0"
46
46
  },
47
47
  "devDependencies": {
@@ -17,7 +17,7 @@
17
17
  "check": "bun run typecheck && bun run test:run"
18
18
  },
19
19
  "dependencies": {
20
- "@cimplify/sdk": "^0.100.4",
20
+ "@cimplify/sdk": "^0.100.5",
21
21
  "next": "^16.2.6",
22
22
  "react": "^19.0.0",
23
23
  "react-dom": "^19.0.0"
@@ -17,7 +17,7 @@
17
17
  "check": "bun run typecheck && bun run test:run"
18
18
  },
19
19
  "dependencies": {
20
- "@cimplify/sdk": "^0.100.4",
20
+ "@cimplify/sdk": "^0.100.5",
21
21
  "next": "^16.2.6",
22
22
  "react": "^19.0.0",
23
23
  "react-dom": "^19.0.0"
@@ -19,7 +19,7 @@
19
19
  "check": "bun run typecheck && bun run test:run"
20
20
  },
21
21
  "dependencies": {
22
- "@cimplify/sdk": "^0.100.4",
22
+ "@cimplify/sdk": "^0.100.5",
23
23
  "next": "^16.2.6",
24
24
  "react": "^19.0.0",
25
25
  "react-dom": "^19.0.0"
@@ -17,7 +17,7 @@
17
17
  "check": "bun run typecheck && bun run test:run"
18
18
  },
19
19
  "dependencies": {
20
- "@cimplify/sdk": "^0.100.4",
20
+ "@cimplify/sdk": "^0.100.5",
21
21
  "next": "^16.2.6",
22
22
  "react": "^19.0.0",
23
23
  "react-dom": "^19.0.0"
@@ -17,7 +17,7 @@
17
17
  "check": "bun run typecheck && bun run test:run"
18
18
  },
19
19
  "dependencies": {
20
- "@cimplify/sdk": "^0.100.4",
20
+ "@cimplify/sdk": "^0.100.5",
21
21
  "next": "^16.2.6",
22
22
  "react": "^19.0.0",
23
23
  "react-dom": "^19.0.0"
@@ -17,7 +17,7 @@
17
17
  "check": "bun run typecheck && bun run test:run"
18
18
  },
19
19
  "dependencies": {
20
- "@cimplify/sdk": "^0.100.4",
20
+ "@cimplify/sdk": "^0.100.5",
21
21
  "next": "^16.2.6",
22
22
  "react": "^19.0.0",
23
23
  "react-dom": "^19.0.0"
@@ -17,7 +17,7 @@
17
17
  "check": "bun run typecheck && bun run test:run"
18
18
  },
19
19
  "dependencies": {
20
- "@cimplify/sdk": "^0.100.4",
20
+ "@cimplify/sdk": "^0.100.5",
21
21
  "next": "^16.2.6",
22
22
  "react": "^19.0.0",
23
23
  "react-dom": "^19.0.0"
@@ -17,7 +17,7 @@
17
17
  "check": "bun run typecheck && bun run test:run"
18
18
  },
19
19
  "dependencies": {
20
- "@cimplify/sdk": "^0.100.4",
20
+ "@cimplify/sdk": "^0.100.5",
21
21
  "next": "^16.2.6",
22
22
  "react": "^19.0.0",
23
23
  "react-dom": "^19.0.0"