<html>
<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
</head>
<body text="#333333" bgcolor="#FFFFFF">
On 8/29/20 5:52 , Ryan Schmidt wrote:<br>
<blockquote
cite="mid:3783B817-51D3-4DFA-9605-3D8D9C280487@macports.org"
type="cite">
<pre wrap="">On Aug 28, 2020, at 21:52, Eric F wrote:
</pre>
<blockquote type="cite">
<pre wrap="">When downloading/fetching a single (script) file from a Git repo. If I use:
// ...
That works, and I can verify against the checksums, etc. But is that an ok method? …or is there a better &/or preferred way?
</pre>
</blockquote>
<pre wrap="">No, that's not ok. Let MacPorts fetch the files for you. Set master_sites and distfiles as needed. For unversioned distfiles, set dist_subdir; consult PortfileRecipes wiki page.
Don't populate the worksrcpath in the checksum phase. That's what the extract phase is for.</pre>
</blockquote>
Thanks! Yes, I had a feeling that it wasn't, so that's why I wanted
to ask. It is a versioned file (last commit of the file) - otherwise
I can't use a checksum to verify it against. I do grep the rolling
file though, for the version number to use with livecheck.<br>
<br>
<br>
On 8/29/20 5:53 , Ryan Schmidt wrote:<br>
<blockquote type="cite">
<pre wrap="">On Aug 28, 2020, at 22:24, Jason Liu wrote:
</pre>
<blockquote type="cite" style="color: #666666;">
<pre wrap="">If you're fetching a single script file from a Git repo, then can't you simply use the built-in fetch keywords, set 'fetch.type git', and then set the extract phase to be empty?
</pre>
</blockquote>
<pre wrap="">Don't use fetch.type git unless fetching a distfile would not work.
</pre>
</blockquote>
I tried using this (earlier), but I think it wanted the full repo,
or at least an archive.<br>
<br>
<br>
On 8/29/20 5:24 , Jason Liu wrote:<br>
<blockquote type="cite">
<div>If you're fetching a single script file from a Git repo, then
can't you simply use the built-in fetch keywords, set
'fetch.type git', and then set the extract phase to be empty?</div>
<div><br>
</div>
<div>-- </div>
Jason Liu</blockquote>
Thanks Jason. I've been using `fetch.type none` now, but I will
explore that empty extract phase.<br>
<br>
<br>
- - -<br>
<br>
· Eric<br>
</body>
</html>