fp-wiki>ImportUser (Imported from MoinMoin) |
(→Wrong unnumbered commit macro used for short tags: new section) |
||
(6 intermediate revisions by 6 users not shown) | |||
Line 5: | Line 5: | ||
* : within this srpm. | * : within this srpm. | ||
== File downloads with GET data == | |||
There should be something here about what to do when a file's URL has GET data at the end of it after the file name. Here's an example, and how I'm handling it: | |||
# To download directly, use this URL: | |||
# Source0: http://trac.bjourne.webfactional.com/attachment/wiki/WikiStart/Gtk2-ImageView-0.04.tar.gz?format=raw | |||
Source0: http://trac.bjourne.webfactional.com/attachment/wiki/WikiStart/Gtk2-ImageView-0.04.tar.gz | |||
(except with %{version} in there) I borrowed that from the gtkimageview specfile. Any suggestions otherwise? If not, that should probably be worked into this page somewhere. -- [[User:Jrowens|J. Randall Owens]] 11:55, 2 July 2008 (UTC) | |||
== Wrong category == | |||
This page has wrong category. It belongs to Category:Packaging. | |||
== Sourceforge.net section error == | |||
In the sourceforge.net section, the suggested scheme for a Source0 entry is: | |||
Source0: <nowiki> http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz</nowiki> | |||
However, when put into practice this scheme gives an eternal loop, according to rpmlint: | |||
HTTP Error 302: The HTTP server returned a redirect error that would lead to an infinite loop. | |||
The last 30x error message was: | |||
Found | |||
== Github == | |||
The guideline points to using <code>git rev-parse $TAG</code> to get the commit hash, but in the case of a tag object this will return the hash of the tag object and not the hash of the commit that github will accept in the archive url. | |||
To fully dereference the tag one must use <code>git rev-parse $TAG^{}</code>. | |||
For release tags github also understands the simplified url of https://github.com/$OWNER/$PROJECT/archive/$TAG.tar.gz | |||
== Wrong unnumbered commit macro used for short tags == | |||
<pre> | |||
%global commit0 40-CHARACTER-HASH-VALUE | |||
%global gittag0 GIT-TAG | |||
%global shortcommit0 %(c=%{commit}; echo ${c:0:7}) [GitHub] | |||
%global shortcommit0 %(c=%{commit}; echo ${c:0:11}) [Bitbucket] | |||
%global shortcommit0 %(c=%{commit}; echo ${c:0:7}) [GitLab] | |||
</pre> | |||
It leads to error on spec parsing. | |||
Should be (note commit'''0'''): | |||
<pre> | |||
%global commit0 40-CHARACTER-HASH-VALUE | |||
%global gittag0 GIT-TAG | |||
%global shortcommit0 %(c=%{commit0}; echo ${c:0:7}) [GitHub] | |||
%global shortcommit0 %(c=%{commit0}; echo ${c:0:11}) [Bitbucket] | |||
%global shortcommit0 %(c=%{commit0}; echo ${c:0:7}) [GitLab] | |||
</pre> | |||
[[User:Hubbitus|Hubbitus]] ([[User talk:Hubbitus|talk]]) 08:52, 21 July 2015 (UTC) |
Latest revision as of 08:52, 21 July 2015
The following metadata was found in MoinMoin that could not be converted
to a useful value in MediaWiki:
- : within this srpm.
File downloads with GET data
There should be something here about what to do when a file's URL has GET data at the end of it after the file name. Here's an example, and how I'm handling it:
# To download directly, use this URL: # Source0: http://trac.bjourne.webfactional.com/attachment/wiki/WikiStart/Gtk2-ImageView-0.04.tar.gz?format=raw Source0: http://trac.bjourne.webfactional.com/attachment/wiki/WikiStart/Gtk2-ImageView-0.04.tar.gz
(except with %{version} in there) I borrowed that from the gtkimageview specfile. Any suggestions otherwise? If not, that should probably be worked into this page somewhere. -- J. Randall Owens 11:55, 2 July 2008 (UTC)
Wrong category
This page has wrong category. It belongs to Category:Packaging.
Sourceforge.net section error
In the sourceforge.net section, the suggested scheme for a Source0 entry is:
Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz
However, when put into practice this scheme gives an eternal loop, according to rpmlint:
HTTP Error 302: The HTTP server returned a redirect error that would lead to an infinite loop. The last 30x error message was: Found
Github
The guideline points to using git rev-parse $TAG
to get the commit hash, but in the case of a tag object this will return the hash of the tag object and not the hash of the commit that github will accept in the archive url.
To fully dereference the tag one must use git rev-parse $TAG^{}
.
For release tags github also understands the simplified url of https://github.com/$OWNER/$PROJECT/archive/$TAG.tar.gz
Wrong unnumbered commit macro used for short tags
%global commit0 40-CHARACTER-HASH-VALUE %global gittag0 GIT-TAG %global shortcommit0 %(c=%{commit}; echo ${c:0:7}) [GitHub] %global shortcommit0 %(c=%{commit}; echo ${c:0:11}) [Bitbucket] %global shortcommit0 %(c=%{commit}; echo ${c:0:7}) [GitLab]
It leads to error on spec parsing.
Should be (note commit0):
%global commit0 40-CHARACTER-HASH-VALUE %global gittag0 GIT-TAG %global shortcommit0 %(c=%{commit0}; echo ${c:0:7}) [GitHub] %global shortcommit0 %(c=%{commit0}; echo ${c:0:11}) [Bitbucket] %global shortcommit0 %(c=%{commit0}; echo ${c:0:7}) [GitLab]