From c98e6d20fc234e1f4b0047cd43af2a37f8f38f44 Mon Sep 17 00:00:00 2001 From: Tonye Jack Date: Fri, 22 Sep 2023 10:00:57 -0600 Subject: [PATCH] Removed unused code --- src/utils.ts | 30 ------------------------------ 1 file changed, 30 deletions(-) diff --git a/src/utils.ts b/src/utils.ts index f330cd92..2e01a4ee 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -233,36 +233,6 @@ export const updateGitGlobalConfig = async ({ } } -/** - * Get tracked git directories - * @param cwd - working directory - */ -export const getGitTrackedDirectories = async ({ - cwd -}: { - cwd: string -}): Promise => { - const {exitCode, stdout, stderr} = await exec.getExecOutput( - 'git', - ['ls-tree', '-d', '-r', '--name-only', 'HEAD'], - { - cwd, - ignoreReturnCode: true, - silent: !core.isDebug() - } - ) - - if (exitCode !== 0) { - core.warning(stderr || "Couldn't list tracked directories") - return [] - } - - return stdout - .trim() - .split('\n') - .map((line: string) => normalizeSeparators(line.trim())) -} - /** * Checks if a git repository is shallow * @param cwd - working directory