Date: Tue, 27 Dec 2022 12:03:04 +0000 From: Nuno Teixeira <eduardo@freebsd.org> To: FreeBSD Mailing List <freebsd-ports@freebsd.org> Subject: MASTER_SITES with DISTVERSION substitution "S:/./-/" Message-ID: <CAFDf7UJ%2BsWG%2BEXj3jBG30E-EkOZ2_KG2De3mF9cmDaq5T3Ku%2BQ@mail.gmail.com>
next in thread | raw e-mail | index | archive | help
--00000000000068e4a005f0ce0916 Content-Type: text/plain; charset="UTF-8" Hello all, I'm working in a port (267717 <https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=267717>) with a source tarball hosted in github: https://github.com/root-project/root/releases/download/v6-26-10/root_v6.26.10.source.tar.gz --- PORTNAME= root DISTVERSION= 6.26.10 CATEGORIES= devel science math parallel python MASTER_SITES= https://github.com/root-project/root/releases/download/v${DISTVERSION:S/./-/:S/./-/}/ DISTNAME= ${PORTNAME}_v${DISTVERSION}.source --- Is there a better way of replacing "." with "-" without using "S:///" 2 times: ${DISTVERSION:S/./-/:S/./-/}/ Using only one :S/./-/ will substitute the first match "6-26.10" Thanks, -- Nuno Teixeira FreeBSD Committer (ports) --00000000000068e4a005f0ce0916 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable <div dir=3D"ltr"><div>Hello all,</div><div><br></div><div>I'm working i= n a port (<span id=3D"gmail-title"><a href=3D"https://bugs.freebsd.org/bugz= illa/show_bug.cgi?id=3D267717">267717</a>) </span>with a source tarball hos= ted in github:</div><div><br></div><div><a href=3D"https://github.com/root-= project/root/releases/download/v6-26-10/root_v6.26.10.source.tar.gz">https:= //github.com/root-project/root/releases/download/v6-26-10/root_v6.26.10.sou= rce.tar.gz</a></div><div>---<br></div><div>PORTNAME=3D =C2=A0 =C2=A0 =C2=A0= root<br>DISTVERSION=3D =C2=A0 =C2=A06.26.10<br>CATEGORIES=3D =C2=A0 =C2=A0= devel science math parallel python<br>MASTER_SITES=3D =C2=A0 <a href=3D"ht= tps://github.com/root-project/root/releases/download/v${DISTVERSION:S/./-/:= S/./-/}/">https://github.com/root-project/root/releases/download/v${DISTVER= SION:S/./-/:S/./-/}/</a><br>DISTNAME=3D =C2=A0 =C2=A0 =C2=A0 ${PORTNAME}_v$= {DISTVERSION}.source</div><div>---</div><div><br></div><div>Is there a bett= er way of replacing "." with "-" without using "S:= ///" 2 times:</div><div>${DISTVERSION:S/./-/:S/./-/}/</div><div>Using = only one :S/./-/ will substitute the first match "6-26.10"</div><= div><br></div><div>Thanks,<br></div><div><br></div><div><br>-- <br><div dir= =3D"ltr" class=3D"gmail_signature" data-smartmail=3D"gmail_signature"><div = dir=3D"ltr"><span style=3D"color:rgb(102,102,102)">Nuno Teixeira<br>FreeBSD= Committer (ports)</span></div></div></div></div> --00000000000068e4a005f0ce0916--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAFDf7UJ%2BsWG%2BEXj3jBG30E-EkOZ2_KG2De3mF9cmDaq5T3Ku%2BQ>