@teispace/next-maker 1.18.0 → 1.19.0

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 +1 @@
1
- {"version":3,"file":"persist.template.d.ts","sourceRoot":"","sources":["../../../../src/generators/templates/persist.template.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,eAAe,GAAI,QAAQ;IACtC,aAAa,EAAE,MAAM,CAAC;IACtB,SAAS,EAAE,MAAM,CAAC;IAClB,eAAe,EAAE,MAAM,CAAC;CACzB,KAAG,MAYH,CAAC"}
1
+ {"version":3,"file":"persist.template.d.ts","sourceRoot":"","sources":["../../../../src/generators/templates/persist.template.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,eAAe,GAAI,QAAQ;IACtC,aAAa,EAAE,MAAM,CAAC;IACtB,SAAS,EAAE,MAAM,CAAC;IAClB,eAAe,EAAE,MAAM,CAAC;CACzB,KAAG,MAwBH,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"injectors.d.ts","sourceRoot":"","sources":["../../../../../src/services/setup/i18n/injectors.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,gBAAgB,GAAU,aAAa,MAAM,KAAG,OAAO,CAAC,IAAI,CAsBxE,CAAC;AAEF,eAAO,MAAM,gBAAgB,GAAU,aAAa,MAAM,KAAG,OAAO,CAAC,IAAI,CASxE,CAAC;AAEF,eAAO,MAAM,iBAAiB,GAAU,aAAa,MAAM,KAAG,OAAO,CAAC,IAAI,CASzE,CAAC;AAEF,eAAO,MAAM,kBAAkB,GAAU,aAAa,MAAM,KAAG,OAAO,CAAC,IAAI,CAiF1E,CAAC;AAEF,eAAO,MAAM,wBAAwB,GAAU,aAAa,MAAM,KAAG,OAAO,CAAC,IAAI,CAwIhF,CAAC"}
1
+ {"version":3,"file":"injectors.d.ts","sourceRoot":"","sources":["../../../../../src/services/setup/i18n/injectors.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,gBAAgB,GAAU,aAAa,MAAM,KAAG,OAAO,CAAC,IAAI,CAsBxE,CAAC;AAEF,eAAO,MAAM,gBAAgB,GAAU,aAAa,MAAM,KAAG,OAAO,CAAC,IAAI,CASxE,CAAC;AAEF,eAAO,MAAM,iBAAiB,GAAU,aAAa,MAAM,KAAG,OAAO,CAAC,IAAI,CASzE,CAAC;AAEF,eAAO,MAAM,kBAAkB,GAAU,aAAa,MAAM,KAAG,OAAO,CAAC,IAAI,CAiF1E,CAAC;AAEF,eAAO,MAAM,wBAAwB,GAAU,aAAa,MAAM,KAAG,OAAO,CAAC,IAAI,CA4IhF,CAAC"}
@@ -7,6 +7,6 @@
7
7
  * during release reviews. If they ever start to differ, switch this module
8
8
  * to a degit fetch — the rest of the service won't need to change.
9
9
  */
10
- export declare const SYNC_ENV_SCRIPT = "import * as fs from 'node:fs';\nimport * as path from 'node:path';\n\nconst envPath = path.join(process.cwd(), '.env');\nconst examplePath = path.join(process.cwd(), '.env.example');\n\nif (!fs.existsSync(envPath)) {\n console.log('\u26A0\uFE0F No .env file found. Skipping sync.');\n process.exit(0);\n}\n\nconst envContent = fs.readFileSync(envPath, 'utf-8');\nconst lines = envContent.split('\\n');\n\nlet isPublicBlock = false;\n\nconst exampleLines = lines.map((line) => {\n const trimmed = line.trim();\n\n // Preserve empty lines and reset public block state\n if (!trimmed) {\n isPublicBlock = false;\n return line;\n }\n\n // Preserve comments\n if (trimmed.startsWith('#')) {\n if (line.toLowerCase().includes('-public')) {\n isPublicBlock = true;\n }\n return line;\n }\n\n // Parse KEY=VALUE\n const match = line.match(/^([^=]+)=(.*)$/);\n\n if (match) {\n const key = match[1];\n\n // Public marker: explicit \"# -public\" comment, or \"KEY=VAL # -public\"\n if (isPublicBlock || line.toLowerCase().includes('-public')) {\n isPublicBlock = false;\n return line;\n }\n\n isPublicBlock = false;\n return `${key}=`;\n }\n\n isPublicBlock = false;\n return line;\n});\n\nconst newExampleContent = exampleLines.join('\\n');\n\nlet currentExampleContent = '';\nif (fs.existsSync(examplePath)) {\n currentExampleContent = fs.readFileSync(examplePath, 'utf-8');\n}\n\nif (currentExampleContent !== newExampleContent) {\n fs.writeFileSync(examplePath, newExampleContent);\n console.log('\u2705 Synchronized .env.example with .env');\n} else {\n console.log('\u2728 .env.example is already up to date');\n}\n";
10
+ export declare const SYNC_ENV_SCRIPT = "import * as fs from 'node:fs';\nimport * as path from 'node:path';\n\nconst checkOnly = process.argv.includes('--check');\n\nconst envPath = path.join(process.cwd(), '.env');\nconst examplePath = path.join(process.cwd(), '.env.example');\n\nif (!fs.existsSync(envPath)) {\n console.log('\u26A0\uFE0F No .env file found. Skipping sync.');\n process.exit(0);\n}\n\nconst envContent = fs.readFileSync(envPath, 'utf-8');\nconst lines = envContent.split('\\n');\n\nlet isPublicBlock = false;\n\nconst exampleLines = lines.map((line) => {\n const trimmed = line.trim();\n\n // Preserve empty lines and reset public block state\n if (!trimmed) {\n isPublicBlock = false;\n return line;\n }\n\n // Preserve comments\n if (trimmed.startsWith('#')) {\n if (line.toLowerCase().includes('-public')) {\n isPublicBlock = true;\n }\n return line;\n }\n\n // Parse KEY=VALUE\n const match = line.match(/^([^=]+)=(.*)$/);\n\n if (match) {\n const key = match[1];\n\n // Public marker: explicit \"# -public\" comment, or \"KEY=VAL # -public\"\n if (isPublicBlock || line.toLowerCase().includes('-public')) {\n isPublicBlock = false;\n return line;\n }\n\n isPublicBlock = false;\n return `${key}=`;\n }\n\n isPublicBlock = false;\n return line;\n});\n\nconst newExampleContent = exampleLines.join('\\n');\n\nlet currentExampleContent = '';\nif (fs.existsSync(examplePath)) {\n currentExampleContent = fs.readFileSync(examplePath, 'utf-8');\n}\n\nif (currentExampleContent === newExampleContent) {\n console.log('\u2728 .env.example is already up to date');\n process.exit(0);\n}\n\nif (checkOnly) {\n console.error('\u274C .env.example is out of sync with .env. Run \"yarn env:sync\" to update.');\n process.exit(1);\n}\n\nfs.writeFileSync(examplePath, newExampleContent);\nconsole.log('\u2705 Synchronized .env.example with .env');\n";
11
11
  export declare const CHECK_DEPRECATED_SCRIPT = "/**\n * Walks every identifier in the project and flags any whose resolved TypeScript\n * symbol carries a `@deprecated` JSDoc tag. Catches deprecated API usage that\n * `tsc --noEmit` does not surface (deprecations are \"suggestion\"-level, not\n * errors) and that Biome does not yet detect.\n *\n * Exits 1 if any deprecated usage is found (so it can gate CI).\n */\nimport path from 'node:path';\nimport ts from 'typescript';\n\nconst cwd = process.cwd();\nconst configPath = ts.findConfigFile(cwd, ts.sys.fileExists, 'tsconfig.json');\n\nif (!configPath) {\n console.error('tsconfig.json not found');\n process.exit(1);\n}\n\nconst raw = ts.readConfigFile(configPath, ts.sys.readFile).config;\nconst parsed = ts.parseJsonConfigFileContent(raw, ts.sys, path.dirname(configPath));\n\nconst program = ts.createProgram({\n rootNames: parsed.fileNames,\n options: parsed.options,\n});\n\nconst checker = program.getTypeChecker();\n\nfunction isDeprecated(sym: ts.Symbol | undefined): boolean {\n if (!sym) return false;\n return sym.getJsDocTags(checker).some((tag) => tag.name === 'deprecated');\n}\n\nlet hits = 0;\n\nfor (const sourceFile of program.getSourceFiles()) {\n if (sourceFile.fileName.includes('node_modules')) continue;\n if (!sourceFile.fileName.startsWith(cwd)) continue;\n\n const visit = (node: ts.Node): void => {\n if (ts.isIdentifier(node)) {\n const sym = checker.getSymbolAtLocation(node);\n if (isDeprecated(sym)) {\n const { line, character } = sourceFile.getLineAndCharacterOfPosition(node.getStart());\n console.log(\n `${path.relative(cwd, sourceFile.fileName)}:${line + 1}:${character + 1} ${node.text} (@deprecated)`,\n );\n hits++;\n }\n }\n ts.forEachChild(node, visit);\n };\n\n visit(sourceFile);\n}\n\nif (hits === 0) {\n console.log('\u2713 No deprecated API usage found.');\n process.exit(0);\n}\n\nconsole.log(`\\n${hits} deprecated symbol use(s) found.`);\nprocess.exit(1);\n";
12
12
  //# sourceMappingURL=scripts.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"scripts.d.ts","sourceRoot":"","sources":["../../../../../src/services/setup/validate-scripts/scripts.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,eAAO,MAAM,eAAe,opDAkE3B,CAAC;AAEF,eAAO,MAAM,uBAAuB,48DAgEnC,CAAC"}
1
+ {"version":3,"file":"scripts.d.ts","sourceRoot":"","sources":["../../../../../src/services/setup/validate-scripts/scripts.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,eAAO,MAAM,eAAe,k2DA0E3B,CAAC;AAEF,eAAO,MAAM,uBAAuB,48DAgEnC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@teispace/next-maker",
3
- "version": "1.18.0",
3
+ "version": "1.19.0",
4
4
  "description": "Create a new Teispace Next.js application with interactive setup.",
5
5
  "keywords": [
6
6
  "nextjs",