mirror of
https://github.com/dorny/paths-filter.git
synced 2025-03-13 13:59:03 +00:00
Fix logging inside ensureRefAvailable()
This commit is contained in:
parent
0b18612ac3
commit
f1c461fccf
8
dist/index.js
vendored
8
dist/index.js
vendored
@ -4001,13 +4001,7 @@ function isGitSha(ref) {
|
||||
}
|
||||
exports.isGitSha = isGitSha;
|
||||
async function hasCommit(ref) {
|
||||
core.startGroup(`Checking if commit for ${ref} is locally available`);
|
||||
try {
|
||||
return (await exec_1.default('git', ['cat-file', '-e', `${ref}^{commit}`], { ignoreReturnCode: true })).code === 0;
|
||||
}
|
||||
finally {
|
||||
core.endGroup();
|
||||
}
|
||||
return (await exec_1.default('git', ['cat-file', '-e', `${ref}^{commit}`], { ignoreReturnCode: true })).code === 0;
|
||||
}
|
||||
async function getCommitCount() {
|
||||
const output = (await exec_1.default('git', ['rev-list', '--count', '--all'])).stdout;
|
||||
|
@ -198,12 +198,7 @@ export function isGitSha(ref: string): boolean {
|
||||
}
|
||||
|
||||
async function hasCommit(ref: string): Promise<boolean> {
|
||||
core.startGroup(`Checking if commit for ${ref} is locally available`)
|
||||
try {
|
||||
return (await exec('git', ['cat-file', '-e', `${ref}^{commit}`], {ignoreReturnCode: true})).code === 0
|
||||
} finally {
|
||||
core.endGroup()
|
||||
}
|
||||
return (await exec('git', ['cat-file', '-e', `${ref}^{commit}`], {ignoreReturnCode: true})).code === 0
|
||||
}
|
||||
|
||||
async function getCommitCount(): Promise<number> {
|
||||
|
Loading…
Reference in New Issue
Block a user