1
0
Fork 0

add post checkout to run git gc

This commit is contained in:
Mikhail Goncharov 2021-09-30 12:46:36 +02:00
parent fc8bf86cbb
commit 3b7d720763
3 changed files with 21 additions and 1 deletions

View file

@ -7,4 +7,5 @@ FROM gcr.io/llvm-premerge-checks/agent-windows-vs2019:${agent_windows_version}
RUN choco install -y handle --checksum 524E61547C8E26608CDA1B11B6E9471616CCCC48530F6E7EC9131EABF839357E RUN choco install -y handle --checksum 524E61547C8E26608CDA1B11B6E9471616CCCC48530F6E7EC9131EABF839357E
COPY start_agent.ps1 C:\scripts\ COPY start_agent.ps1 C:\scripts\
COPY pre-checkout.bat c:\buildkite-agent\hooks\ COPY pre-checkout.bat c:\buildkite-agent\hooks\
CMD "powershell C:\scripts\start_agent.ps1" COPY post-checkout.bat c:\buildkite-agent\hooks\
CMD "powershell C:\scripts\start_agent.ps1"

View file

@ -0,0 +1,2 @@
echo "post-checkout"
powershell c:\llvm-premerge-checks\scripts\windows\post-checkout.ps1

View file

@ -0,0 +1,17 @@
# Copyright 2021 Google LLC
# Licensed under the the Apache License v2.0 with LLVM Exceptions (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
# https://llvm.org/LICENSE.txt
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
echo "running git gc"
pwd
git gc