Skip to content

Commit

Permalink
update rm to use FreeBSD flags
Browse files Browse the repository at this point in the history
  • Loading branch information
diegomarquezp committed Oct 29, 2024
1 parent 89bd3c5 commit b1e61eb
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions hermetic_build/library_generation/generate_library.sh
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ temp_destination_path="${output_folder}/temp_preprocessed"
mkdir -p "${output_folder}/${destination_path}"
if [ -d "${temp_destination_path}" ]; then
# we don't want the preprocessed sources of a previous run
rm -rd "${temp_destination_path}"
rm -r "${temp_destination_path}"
fi
mkdir -p "${temp_destination_path}"
##################### Section 0 #####################
Expand Down Expand Up @@ -274,5 +274,5 @@ rm -rf java_gapic_srcjar java_gapic_srcjar_raw.srcjar.zip java_grpc.jar java_pro
popd # destination path

cp -r ${temp_destination_path}/* "${output_folder}/${destination_path}"
rm -rdf "${temp_destination_path}"
rm -rf "${temp_destination_path}"
exit 0
2 changes: 1 addition & 1 deletion hermetic_build/library_generation/owlbot/bin/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ library_version=$5

if [[ "${is_monorepo}" == "true" ]]; then
mv owl-bot-staging/* temp
rm -rd owl-bot-staging/
rm -rf owl-bot-staging/
mv temp owl-bot-staging
fi

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ def setUp(self):
bash_call(f"mkdir {self.output_folder}")

def tearDown(self):
bash_call(f"rm -rdf {self.simulated_home}")
bash_call(f"rm -rf {self.simulated_home}")

def _run_command(self, command, **kwargs):
env = os.environ.copy()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ download_tools_succeed_with_baked_protoc() {
download_tools "99.99" "${test_grpc_version}" "linux-x86_64"
assertEquals "${protoc_bin_folder}" "${protoc_path}"

rm -rdf "${output_folder}"
rm -rf "${output_folder}"
unset DOCKER_PROTOC_LOCATION
unset DOCKER_PROTOC_VERSION
unset output_folder
Expand All @@ -159,7 +159,7 @@ download_tools_succeed_with_baked_grpc() {
download_tools "${test_protoc_version}" "99.99" "linux-x86_64"
assertEquals "${DOCKER_GRPC_LOCATION}" "${grpc_path}"

rm -rdf "${output_folder}"
rm -rf "${output_folder}"
unset DOCKER_GRPC_LOCATION
unset DOCKER_GRPC_VERSION
unset output_folder
Expand Down Expand Up @@ -243,7 +243,7 @@ copy_directory_if_exists_valid_folder_succeeds() {
mkdir -p "${destination}"
copy_directory_if_exists "${source_folder}" "gapic" "${destination}/copied-folder"
n_matching_folders=$(ls "${destination}" | grep -e 'copied-folder' | wc -l)
rm -rdf "${destination}"
rm -rf "${destination}"
assertEquals 1 ${n_matching_folders}
}

Expand All @@ -253,7 +253,7 @@ copy_directory_if_exists_invalid_folder_does_not_copy() {
mkdir -p "${destination}"
copy_directory_if_exists "${source_folder}" "gapic" "${destination}/copied-folder"
n_matching_folders=$(ls "${destination}" | grep -e 'copied-folder' | wc -l) || res=$?
rm -rdf "${destination}"
rm -rf "${destination}"
assertEquals 0 ${n_matching_folders}
}

Expand Down

0 comments on commit b1e61eb

Please sign in to comment.