{"thread":{"id":"14373","subject":"[PATCH/RFC] git-request-pull: replace call to deprecated peek-remote","startedAt":"2008-07-08T23:32:15Z","lastAt":"2008-07-08T23:32:15Z","messageCount":1,"participants":["Ramsay Jones"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"82737","messageId":"4873F8FF.70607@ramsay1.demon.co.uk","threadId":"14373","inReplyTo":null,"subject":"[PATCH/RFC] git-request-pull: replace call to deprecated peek-remote","fromName":"Ramsay Jones","fromEmail":"ramsay@ramsay1.demon.co.uk","sentAt":"2008-07-08T23:32:15Z","receivedAt":"2008-07-08T23:32:15Z","isPatch":true,"sender":{"key":"ramsay@ramsayjones.plus.com","avatar":"https://avatars.githubusercontent.com/u/33702710?v=4"},"body":"\nSigned-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk>\n---\n\nI don't even recall how I noticed this ...\n\nOnly very lightly tested, but since git-peek-remote and\ngit-ls-remote are implemented in git.c as synonyms, it should\nbe quite safe ...\n\n\n git-request-pull.sh |    2 +-\n 1 files changed, 1 insertions(+), 1 deletions(-)\n\ndiff --git a/git-request-pull.sh b/git-request-pull.sh\nindex 068f5e0..073a314 100755\n--- a/git-request-pull.sh\n+++ b/git-request-pull.sh\n@@ -26,7 +26,7 @@ merge_base=`git merge-base $baserev $headrev` ||\n die \"fatal: No commits in common between $base and $head\"\n \n url=$(get_remote_url \"$url\")\n-branch=$(git peek-remote \"$url\" \\\n+branch=$(git ls-remote \"$url\" \\\n \t| sed -n -e \"/^$headrev\trefs.heads./{\n \t\ts/^.*\trefs.heads.//\n \t\tp\n-- \n1.5.6\n"}]}