mirror of
https://github.com/shadcn-ui/ui.git
synced 2026-07-01 00:24:20 +00:00
* chore(shadcn): implement registries poc * feat(shadcn): refactor our initial implementation * feat(shadcn): properly resolve namespaced registryDependencies * feat(shadcn): resolve namespaced registries recursively * fix * feat(shadcn): implement dotenv support * test(shadcn): mock shadcn registry * fix * fix * fix * refactor(shadcn): update functions and tests * refactor(shadcn): add fetchFromRegistry (#7937) * fix * feat(shadcn): add shadcn as a built-in registry * fix * feat(shadcn): update no framework and shadcn
18 lines
376 B
TypeScript
18 lines
376 B
TypeScript
import path from "path"
|
|
import fs from "fs-extra"
|
|
import { rimraf } from "rimraf"
|
|
|
|
export const TEMP_DIR = path.join(__dirname, "../../temp")
|
|
|
|
export default async function setup() {
|
|
await fs.ensureDir(TEMP_DIR)
|
|
|
|
return async () => {
|
|
try {
|
|
await rimraf(TEMP_DIR)
|
|
} catch (error) {
|
|
console.error("Failed to clean up temp directory:", error)
|
|
}
|
|
}
|
|
}
|