🌳
pt0/deployF/libF/gitF/getDeployGitShaAI.mts
1import { getHeadGitSha } from './gitRepoF.mts'
6type GetDeployGitShaOpts = {
7 importMetaUrl: string
8 appSourcePaths?: string[]
9}
11export const getDeployGitSha = async ({importMetaUrl, appSourcePaths = []}: GetDeployGitShaOpts) => {
12 const deployEpPath = absPathToPtPath(getImportMetaUrlPath(importMetaUrl) as any)
13 const deployPathsA = await epsToPathsGitCached({epPtPathsA: [deployEpPath]})
14 const filterPathList = [...deployPathsA, ...appSourcePaths]
15 return getHeadGitSha({filterPathList})