From a692b003491ef33beea75e4473c349a7fe3ef676 Mon Sep 17 00:00:00 2001 From: "mergify[bot]" <37929162+mergify[bot]@users.noreply.github.com> Date: Fri, 12 Jul 2024 13:23:43 +0300 Subject: [PATCH] deleted pre-exit (#40166) (#40216) Deleted pre-exit hook since it's not relevant for Buildkite (cherry picked from commit ad0d14c1b67ae85f4d220610f766db94c4027008) Co-authored-by: Olga Naydyonock --- .buildkite/hooks/pre-exit | 25 ------------------------- 1 file changed, 25 deletions(-) delete mode 100644 .buildkite/hooks/pre-exit diff --git a/.buildkite/hooks/pre-exit b/.buildkite/hooks/pre-exit deleted file mode 100644 index 0d6d60d4b7a3..000000000000 --- a/.buildkite/hooks/pre-exit +++ /dev/null @@ -1,25 +0,0 @@ -#!/usr/bin/env bash - -set -euo pipefail - -unset_secrets () { - for var in $(printenv | sed 's;=.*;;' | sort); do - if [[ "$var" == *_SECRET || "$var" == *_TOKEN ]]; then - unset "$var" - fi - done -} - -cleanup() { - if [[ "$BUILDKITE_COMMAND" != *"buildkite-agent pipeline upload"* ]]; then - echo "Deleting temporary files..." - if [[ -n "${BIN:-}" ]]; then - rm -rf "${BIN}" - fi - echo "Done." - fi -} - -unset_secrets -cleanup -