From 40e3586f5f60ff621e44ec1a96d9f8e61694d9b4 Mon Sep 17 00:00:00 2001 From: Bevan Kay Date: Fri, 27 May 2022 13:16:25 +1000 Subject: [PATCH] `cask-pr-inspect-download`: update command (#124374) * cask-pr-inspect-download: update command * cask-pr-local-check: update command --- developer/bin/cask-pr-inspect-download | 2 +- developer/bin/cask-pr-local-check | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/developer/bin/cask-pr-inspect-download b/developer/bin/cask-pr-inspect-download index b7b61a65ab..63187fcc9a 100755 --- a/developer/bin/cask-pr-inspect-download +++ b/developer/bin/cask-pr-inspect-download @@ -39,7 +39,7 @@ pr_json = JSON.parse(URI(pr_api).read) abort "PR needs to have a single file" if pr_json.count != 1 -file_raw_url = pr_json[0]["raw_url"] +file_raw_url = pr_json[0]["raw_url"].gsub("%2F", "/") file_name = File.basename(file_raw_url) local_file = File.join(Dir.mktmpdir, file_name) tmp_cache_dir = Dir.mktmpdir diff --git a/developer/bin/cask-pr-local-check b/developer/bin/cask-pr-local-check index ac44bed150..bebc902f89 100755 --- a/developer/bin/cask-pr-local-check +++ b/developer/bin/cask-pr-local-check @@ -38,7 +38,7 @@ pr_json = JSON.parse(URI(pr_api).read) abort "PR needs to have a single file" if pr_json.count != 1 -file_raw_url = pr_json[0]["raw_url"] +file_raw_url = pr_json[0]["raw_url"].gsub("%2F", "/") file_name = File.basename(file_raw_url) local_file = File.join(Dir.mktmpdir, file_name)