From nobody Wed Jul 12 14:19:25 2023 X-Original-To: dev-commits-ports-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4R1KcY48smz4h49h; Wed, 12 Jul 2023 14:19:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4R1KcY3VCZz3QXs; Wed, 12 Jul 2023 14:19:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1689171565; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=bc5j7F4XrWw6rMW4OIWDTsK9hv6rI8/vpECvBeYsa/k=; b=oQzi5VrnLocqoNUMdHjUjLRmp8DQLauPzH+bAviF7IC+aLsp1Mh4DoRSjcWgbq5vppXLvI TEzpYgmHcyVulSwwrc8a/SroqhL8IDN8+g7CQGbPCZJUOLMj2uIkfGTD6WEjSRovQ470GH DNeWsgYXIzTP2e5Je4Ve4q0w1j19bI5BR8/X9NTagYRPzGEvHDHFSy2RRe8QF+P9FhczgJ 1LLhdiHcnvYzzgIgBFHEzfW4D/qMAUZmHvg2f4EWzI1HcyfxCJASFJqsTCzddQl1uLI7L1 4jshGwHhBadSSqH7kq5glSDupGCH50dGIuAb8kBdBP8Wr5ARRGjy03l1cyeGbw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1689171565; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=bc5j7F4XrWw6rMW4OIWDTsK9hv6rI8/vpECvBeYsa/k=; b=lNO5EMHxI39NQ00X0uYmrFSNj7LKvXlpSBD5UqdxNPGTXEwRxgKKAtPIBScWReIhhA49T8 FeSc7L9hsJnEt1VCKnzgEE9TRxgBLI5oiBEz71rYuBAwPekvJNVgtzFcm/3Bw3B07VUg32 dY1AUG1oq6AyK0Nep4LGDdo2x6lIbPP+NUlylzRGmbaahbfCxNgJWGoE8LoZdb1Ph4xHFP sAdUle3YPd2yaGrQYGaVy/k2Nit7CUzzWM03W8Wx/EeU3K/ngrAIr6Srwl1CTqyhy5Smb3 GBfvP7DPsUsk5qyeVe93U9dvx6HdaD/QCd8cuSfuv1sVC6rc7l1oBM3pHLt5hg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1689171565; a=rsa-sha256; cv=none; b=b2rnAtRFa062tULlEa5i/Edoj/szXvSvzzcXWgx25elgUh2pNF3Q6kAivt8nKScYXo10he FPLHLuawk7lBPA03PoWYbImKXATDKGKcWm4K4JLQahttC0UroYpY56C7fJfsCbv2fhZ9ww 3mLjJ3osb3UVW2paHhpVY6iqAcHgOHhQ39b1gO72KYaWF7R8PHK5D4qw5hqoibmvxuc9a3 +LqsdtpFFVBHWfILEmMGs4n6ob8U3OSzArstGb8lN9QFhHBRloLjvhPEU5jTTCoMItd1or DI/NgO8Kaygk0/XnffPfhYaWX2FU1QH10OYoLrzxYod3hCKl6yRB5ucvdJzRUA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4R1KcY2S3nz1Bx9; Wed, 12 Jul 2023 14:19:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 36CEJPQx010845; Wed, 12 Jul 2023 14:19:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 36CEJPpI010844; Wed, 12 Jul 2023 14:19:25 GMT (envelope-from git) Date: Wed, 12 Jul 2023 14:19:25 GMT Message-Id: <202307121419.36CEJPpI010844@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 5457f710e8b8 - main - framework: Fix fetch-url-list and fetch-urlall-list List-Id: Commit messages for all branches of the ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-all@freebsd.org X-BeenThere: dev-commits-ports-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 5457f710e8b827281d83bbba17db0868389205b4 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by 0mp: URL: https://cgit.FreeBSD.org/ports/commit/?id=5457f710e8b827281d83bbba17db0868389205b4 commit 5457f710e8b827281d83bbba17db0868389205b4 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2023-06-30 09:58:48 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-07-12 14:18:21 +0000 framework: Fix fetch-url-list and fetch-urlall-list The fetch-url-list and fetch-urlall-list targets are meant to produce a list of URLs from which a port fetches its distfiles and patches. Currently, those targets were not working as expected as they print parts of the output meant for other targets like the fetch-list target. For example: mateusz.piotrowski@server /ports/x11-servers/xwayland-devel$ make fetch-urlall-list [...] mkdir -p "xorg" && -o xorg/proto-xorgproto-824001c947cb1962209c6a8f2c63c2637877220d_GL0.tar.gz [...] This patch prevents do-fetch.sh from printing the "mkdir" line and the "-o" line. While here: - Remove the outdated comment about escaping. There is no excessive escaping happening there anymore. - Indent cases in the case statement to match the style of the rest of the file. Reviewed by: pizzamig Approved by: portmgr (pizzamig) Sponsored by: Klara Inc. Differential Revision: https://reviews.freebsd.org/D40808 --- Mk/Scripts/do-fetch.sh | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/Mk/Scripts/do-fetch.sh b/Mk/Scripts/do-fetch.sh index 707337928989..da42191cf533 100644 --- a/Mk/Scripts/do-fetch.sh +++ b/Mk/Scripts/do-fetch.sh @@ -123,23 +123,24 @@ for _file in "${@}"; do for site in ${sites}; do sites_remaining=$((sites_remaining - 1)) CKSIZE=$(distinfo_data SIZE "${full_file}") - # There is a lot of escaping, but the " needs to survive echo/eval. + early_args="" case ${file} in */*) case ${dp_TARGET} in - fetch-list|fetch-url-list-int) - echo "mkdir -p \"${file%/*}\" && " - ;; - *) - mkdir -p "${file%/*}" - ;; + fetch-list) + echo "mkdir -p \"${file%/*}\" && " + early_args="-o ${file}" + ;; + fetch-url-list-int) + ;; + *) + mkdir -p "${file%/*}" + early_args="-o ${file}" + ;; esac - args="-o ${file} ${site}${file}" - ;; - *) - args="${site}${file}" - ;; + ;; esac + args="${early_args:+${early_args} }${site}${file}" _fetch_cmd="${dp_FETCH_CMD} ${dp_FETCH_BEFORE_ARGS}" if [ -z "${dp_DISABLE_SIZE}" -a -n "${CKSIZE}" ]; then _fetch_cmd="${_fetch_cmd} -S ${CKSIZE}"