From 5e97c8f67f279148ba475fe6a0a7a8650449a603 Mon Sep 17 00:00:00 2001 From: Azure SDK Bot <53356347+azure-sdk@users.noreply.github.com> Date: Fri, 19 Feb 2021 12:02:01 -0800 Subject: [PATCH] Sync eng/common directory with azure-sdk-tools for PR 1425 (#1698) * Trim off the target branch * Update eng/common/scripts/get-markdown-files-from-changed-files.ps1 Co-authored-by: Wes Haggard * Update get-markdown-files-from-changed-files.ps1 * Update get-markdown-files-from-changed-files.ps1 * Trim the slash Co-authored-by: Sima Zhu Co-authored-by: Sima Zhu <48036328+sima-zhu@users.noreply.github.com> Co-authored-by: Wes Haggard --- eng/common/scripts/get-markdown-files-from-changed-files.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eng/common/scripts/get-markdown-files-from-changed-files.ps1 b/eng/common/scripts/get-markdown-files-from-changed-files.ps1 index 6316fd1ce..4e0d48bb8 100644 --- a/eng/common/scripts/get-markdown-files-from-changed-files.ps1 +++ b/eng/common/scripts/get-markdown-files-from-changed-files.ps1 @@ -2,7 +2,7 @@ param ( # The root repo we scaned with. [string] $RootRepo = '$PSScriptRoot/../../..', # The target branch to compare with. - [string] $targetBranch = "origin/${env:SYSTEM_PULLREQUEST_TARGETBRANCH}" + [string] $targetBranch = ("origin/${env:SYSTEM_PULLREQUEST_TARGETBRANCH}" -replace "/refs/heads/") ) $deletedFiles = (git diff $targetBranch HEAD --name-only --diff-filter=D) $renamedFiles = (git diff $targetBranch HEAD --diff-filter=R)