Skip to content
Source
Sign inSign up
pingdotgg/t3code
Open History to see the last commit

isRepo.ts

6 lines171 Bytes

1import { existsSync } from "node:fs";
2import { join } from "node:path";
3​
4export function isGitRepository(cwd: string): boolean {
5 return existsSync(join(cwd, ".git"));
6}