cli: organize file structure

This commit is contained in:
Aman Varshney
2025-05-26 00:13:08 +05:30
parent b9c9690e61
commit 1e9c6b2210
40 changed files with 900 additions and 928 deletions

View File

@@ -1,4 +1,4 @@
import type { ProjectPackageManager } from "../types";
import type { PackageManager } from "../types";
/**
* Returns the appropriate command for running a package without installing it globally,
@@ -9,7 +9,7 @@ import type { ProjectPackageManager } from "../types";
* @returns The full command string (e.g., "npx prisma generate --schema=./prisma/schema.prisma").
*/
export function getPackageExecutionCommand(
packageManager: ProjectPackageManager | null | undefined,
packageManager: PackageManager | null | undefined,
commandWithArgs: string,
): string {
switch (packageManager) {

View File

@@ -1,6 +1,6 @@
import type { ProjectPackageManager } from "../types";
import type { PackageManager } from "../types";
export const getUserPkgManager: () => ProjectPackageManager = () => {
export const getUserPkgManager: () => PackageManager = () => {
const userAgent = process.env.npm_config_user_agent;
if (userAgent?.startsWith("pnpm")) {