From c01e7c3e42f4710cc57629d489a8236d534aae5e Mon Sep 17 00:00:00 2001 From: Sebastian Karasek Date: Tue, 29 May 2018 20:02:26 +0200 Subject: [PATCH] Fix extraction of folders (#9335) --- scripts/obtain/dotnet-install.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/obtain/dotnet-install.sh b/scripts/obtain/dotnet-install.sh index 27443c397..6d17c58e7 100755 --- a/scripts/obtain/dotnet-install.sh +++ b/scripts/obtain/dotnet-install.sh @@ -628,7 +628,7 @@ extract_dotnet_package() { tar -xzf "$zip_path" -C "$temp_out_path" > /dev/null || failed=true local folders_with_version_regex='^.*/[0-9]+\.[0-9]+[^/]+/' - find "$temp_out_path" -type f | grep -Eo "$folders_with_version_regex" | copy_files_or_dirs_from_list "$temp_out_path" "$out_path" false + find "$temp_out_path" -type f | grep -Eo "$folders_with_version_regex" | sort | copy_files_or_dirs_from_list "$temp_out_path" "$out_path" false find "$temp_out_path" -type f | grep -Ev "$folders_with_version_regex" | copy_files_or_dirs_from_list "$temp_out_path" "$out_path" "$override_non_versioned_files" rm -rf "$temp_out_path"