[26471] in Source-Commits
Re: /svn/athena r25578 - trunk/debathena/scripts
daemon@ATHENA.MIT.EDU (Benjamin Kaduk)
Thu Jun 14 09:45:24 2012
Date: Thu, 14 Jun 2012 09:45:20 -0400 (EDT)
From: Benjamin Kaduk <kaduk@MIT.EDU>
To: Jonathan D Reed <jdreed@MIT.EDU>
cc: Geoffrey Thomas <geofft@MIT.EDU>, source-commits@MIT.EDU
In-Reply-To: <alpine.DEB.2.00.1206061418410.9393@dr-wily.mit.edu>
Message-ID: <alpine.GSO.1.10.1206140944180.18441@multics.mit.edu>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed
On Wed, 6 Jun 2012, Geoffrey Thomas wrote:
> Oh, clever. ACK
>
> --
> Geoffrey Thomas
> geofft@mit.edu
>
> On Wed, 6 Jun 2012, Jonathan D Reed wrote:
>
>> Author: jdreed
>> Date: 2012-06-06 17:05:56 -0400 (Wed, 06 Jun 2012)
>> New Revision: 25578
>>
>> Modified:
>> trunk/debathena/scripts/dasource
>> Log:
>> Don't build UNRELEASED packages
>>
>> Modified: trunk/debathena/scripts/dasource
>> ===================================================================
>> --- trunk/debathena/scripts/dasource 2012-06-06 20:50:27 UTC (rev 25577)
>> +++ trunk/debathena/scripts/dasource 2012-06-06 21:05:56 UTC (rev 25578)
>> @@ -73,6 +73,13 @@
>> svn co $repo/$pkgpath $dir
>> fi
>>
>> + # Ensure that we're not trying to do something stupid
>> + distribution=$(cd $dir && dpkg-parsechangelog | sed -n 's/Distribution:
>> //p')
>> + if [ "$distribution" = "UNRELEASED" ]; then
>> + echo "You can't/shouldn't build a package marked as UNRELEASED."
>> + exit 1
>> + fi
It might be more robust to use a case statement (to get shell globs)
instead of a strict string comparison.
This is still a vast improvement over the previous situation, though --
thanks.
-Ben
>> +
>> # Extract the changelog version and strip off the epoch and Debian
>> component.
>> changever=$(cd $dir && dpkg-parsechangelog | sed -n 's/Version: //p')
>> sver=$(echo $changever | sed -re 's/^[0-9]+://p')
>>
>>
>