Add ESLint to all packages and reorganize CLI
ESLint: - Add @macalinao/eslint-config and eslint to all packages/apps - Add lint scripts to all package.json files - Create eslint.config.js for all apps - Add lint task to turbo.json - Add @macalinao/eslint-config and @types/bun to catalog Biome: - Exclude docs/ from biome checks CLI Reorganization: - Restructure CLI to use route maps with one command per file - Move commands to routes/ directory structure - Use func property instead of async loaders - Route maps in _command.ts files for each directory Environment: - Use Bun.env instead of process.env for env vars - Add DATABASE_URL and PORT to turbo.json globalEnv Lint Fixes: - Fix nullish coalescing operator usage - Update deprecated Zod API (z.email() instead of .string().email()) - Fix import sorting Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
25
apps/cli/src/routes/bootstrap.ts
Normal file
25
apps/cli/src/routes/bootstrap.ts
Normal file
@@ -0,0 +1,25 @@
|
||||
import type { LocalContext } from "../context.js";
|
||||
import { buildCommand } from "@stricli/core";
|
||||
|
||||
function bootstrap(this: LocalContext): void {
|
||||
console.log("RevIQ Bootstrap - Create Superuser");
|
||||
console.log("===================================\n");
|
||||
|
||||
console.log("TODO: Implement bootstrap command");
|
||||
console.log("\nThis command will:");
|
||||
console.log(" 1. Prompt for email address");
|
||||
console.log(" 2. Prompt for password (with confirmation)");
|
||||
console.log(" 3. Hash password using scrypt (@noble/hashes)");
|
||||
console.log(" 4. Create user in database with is_superuser=true");
|
||||
console.log("\nRequirements:");
|
||||
console.log(" - Database must be migrated (run 'dbmate up' first)");
|
||||
console.log(" - DATABASE_URL environment variable must be set");
|
||||
}
|
||||
|
||||
export const bootstrapCommand = buildCommand({
|
||||
func: bootstrap,
|
||||
parameters: {},
|
||||
docs: {
|
||||
brief: "Create a superuser account",
|
||||
},
|
||||
});
|
||||
Reference in New Issue
Block a user