feat: enhance error handling for non-git directories (#1885)

Co-authored-by: GitHub Action <action@github.com>
This commit is contained in:
Tonye Jack
2024-01-25 11:46:48 -07:00
committed by GitHub
parent 2cb2c9234e
commit 90a06d6ba9
5 changed files with 45 additions and 5 deletions

View File

@@ -680,6 +680,12 @@ export const isInsideWorkTree = async ({
}
)
if (stdout.trim() !== 'true') {
core.debug(
`The current working directory is not inside a git repository: ${cwd}`
)
}
return stdout.trim() === 'true'
}