On Sun, Feb 10, 2019, 01:59 Sérgio Basto <sergio@serjux.com wrote:
On Sat, 2019-02-09 at 17:50 +0000, Mattia Verga wrote:
> I've been trying to update one of my package using the docs at
> https://docs.fedoraproject.org/en-US/packaging-guidelines/SourceURL/#_commit_revision
> This says to use
> Source0: 
> https://github.com/OWNER/PROJECT/archive/%{commit}/%{name}-%{shortcommit}.tar.gz
> when one needs to reference an archive extracted from a specific
> commit. But it seems that the produced file is using the format
> %{name}-%{commit}.tar.gz

yes is that what happens

>
> Am I doing something wrong?

It is all correct you just need use :

%setup -q -n %{name}-%{commit}


the file %{name}-%{shortcommit}.tar.gz just will have a shorter
filename , nothing else change i.e.
if you download
https://github.com/OWNER/PROJECT/archive/%{commit}/%{name}-%{commit}.tar.gz
 you will see that files are equal , no diffs .

Thanks Sérgio, you're right.

It's also explicitly mentioned in the docs that the "-n" argument to %setup / %autosetup is needed - actually, it's even in the same code block as the URL pattern for git commits.

https://docs.fedoraproject.org/en-US/packaging-guidelines/SourceURL/#_commit_revision

However, if there really are errors, feel free to open issues with the packaging committee on our pagure repository. I updated the SourceURL guidelines myself not so long ago, and I hope to keep them up-to-date and correct.

Fabio






> Mattia
> _______________________________________________
> packaging mailing list -- packaging@lists.fedoraproject.org
> To unsubscribe send an email to
> packaging-leave@lists.fedoraproject.org
> Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html
> List Guidelines:
> https://fedoraproject.org/wiki/Mailing_list_guidelines
> List Archives:
> https://lists.fedoraproject.org/archives/list/packaging@lists.fedoraproject.org
--
Sérgio M. B.
_______________________________________________
packaging mailing list -- packaging@lists.fedoraproject.org
To unsubscribe send an email to packaging-leave@lists.fedoraproject.org
Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/packaging@lists.fedoraproject.org