[112098] trunk/dports/_resources/port1.0/group/github-1.0.tcl
michaelld at macports.org
michaelld at macports.org
Fri Oct 11 16:06:45 PDT 2013
Revision: 112098
https://trac.macports.org/changeset/112098
Author: michaelld at macports.org
Date: 2013-10-11 16:06:45 -0700 (Fri, 11 Oct 2013)
Log Message:
-----------
gitub-1.0 PortGroup:
* compare strings using 'eq';
* add commend on what the regexp is doing.
Modified Paths:
--------------
trunk/dports/_resources/port1.0/group/github-1.0.tcl
Modified: trunk/dports/_resources/port1.0/group/github-1.0.tcl
===================================================================
--- trunk/dports/_resources/port1.0/group/github-1.0.tcl 2013-10-11 22:08:03 UTC (rev 112097)
+++ trunk/dports/_resources/port1.0/group/github-1.0.tcl 2013-10-11 23:06:45 UTC (rev 112098)
@@ -56,7 +56,7 @@
# keeping the default at tags like many portfiles already do
# the port writer can set github.tarball_from to "downloads" and have the URI path accordingly changed
- if {[string equal ${action} "set"] && $args == "downloads"} {
+ if {${action} eq "set" && $args eq "downloads"} {
github.tarball_from ${args}
github.master_sites https://github.com/downloads/${github.author}/${github.project}
}
@@ -79,20 +79,27 @@
fetch.ignore_sslcert yes
post-extract {
- if {![file exists ${worksrcpath}] && "standard" == ${fetch.type} && \
- ${master_sites} == ${github.master_sites} && [llength ${distfiles}] > 0 && \
- [llength [glob -nocomplain ${workpath}/*]] > 0} {
+ if {![file exists ${worksrcpath}] && \
+ ${fetch.type} eq "standard" && \
+ ${master_sites} eq ${github.master_sites} && \
+ [llength ${distfiles}] > 0 && \
+ [llength [glob -nocomplain ${workpath}/*]] > 0} {
move [glob ${workpath}/*] ${worksrcpath}
}
}
- if {[join ${github.tag_prefix}] == "" && [regexp "^\[0-9a-f\]{9,}\$" ${github.version}]} {
+ # If the "commit" string from start to end is in [0-9a-f] to at
+ # least 9 characters, and no tag is provided, then assume doing
+ # commits type livecheck; else tags type.
+
+ if {[join ${github.tag_prefix}] eq "" && \
+ [regexp "^\[0-9a-f\]{9,}\$" ${github.version}]} {
github.livecheck_type commits
} else {
github.livecheck_type tags
}
- if {[string equal ${github.livecheck_type} "commits"]} {
+ if {${github.livecheck_type} eq "commits"} {
livecheck.type regexm
livecheck.url ${github.homepage}/commits/master.atom
livecheck.version ${github.version}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20131011/2b156462/attachment.html>
More information about the macports-changes
mailing list