Skip to content

Commit

Permalink
Merge pull request #20 from slaanesh/curl-nolocale
Browse files Browse the repository at this point in the history
[build-emacs-from-ftp] curl must not use locale to prevent from date parsing failures
  • Loading branch information
caldwell committed Jun 11, 2013
2 parents 5be4a21 + dced39e commit 288a672
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion build-emacs-from-ftp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ FTP_DIR_URL=${1:?"1st arg should be an ftp url"}
LABEL=$2-
LABEL=${LABEL#-}

eval `curl -s "$FTP_DIR_URL/" | perl -MSort::Versions -ne 'push @v, { s=>$1, d=>$2, p=>$3, v=>$4 } if /(\d+) (\w+ \d+ (?: \d+|\d+:\d+)) (emacs-([\d.]+(?:-rc\d*|[a-z])?).tar.[xg]z)/; END { %r = %{${[sort { versioncmp $b->{v}, $a->{v} } @v]}[0]}; print "SIZE=$r{s}\nLATEST=$r{p}\nVERSION=$r{v}\nDATE=\"$r{d}\"\n" }'`
eval `env LC_ALL=C curl -s "$FTP_DIR_URL/" | perl -MSort::Versions -ne 'push @v, { s=>$1, d=>$2, p=>$3, v=>$4 } if /(\d+) (\w+ \d+ (?: \d+|\d+:\d+)) (emacs-([\d.]+(?:-rc\d*|[a-z])?).tar.[xg]z)/; END { %r = %{${[sort { versioncmp $b->{v}, $a->{v} } @v]}[0]}; print "SIZE=$r{s}\nLATEST=$r{p}\nVERSION=$r{v}\nDATE=\"$r{d}\"\n" }'`

# Prevent clean() from removing the whole directory when the above regular expression fails. Grrrrr.
if [ x$LATEST = x ]; then
Expand Down

0 comments on commit 288a672

Please sign in to comment.