Merge lp://staging/~jelmer/bzr-builder/revtime into lp://staging/bzr-builder

Proposed by Jelmer Vernooij
Status: Merged
Approved by: James Westby
Approved revision: 134
Merged at revision: 135
Proposed branch: lp://staging/~jelmer/bzr-builder/revtime
Merge into: lp://staging/bzr-builder
Diff against target: 95 lines (+53/-1)
2 files modified
recipe.py (+35/-1)
tests/test_recipe.py (+18/-0)
To merge this branch: bzr merge lp://staging/~jelmer/bzr-builder/revtime
Reviewer Review Type Date Requested Status
James Westby Approve
Review via email: mp+64169@code.staging.launchpad.net

Description of the change

Add {revtime}, {revdate} substitution variables.

To post a comment you must log in.
Revision history for this message
John A Meinel (jameinel) wrote :

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 06/10/2011 02:31 PM, Jelmer Vernooij wrote:
> Jelmer Vernooij has proposed merging lp:~jelmer/bzr-builder/revtime into lp:bzr-builder.
>
> Requested reviews:
> bzr-builder developers (bzr-builder-devs)
> Related bugs:
> Bug #793072 in bzr-builder: "Provide deb-version variables for revision commit time/date"
> https://bugs.launchpad.net/bzr-builder/+bug/793072
>
> For more details, see:
> https://code.launchpad.net/~jelmer/bzr-builder/revtime/+merge/64169
>
> Add {revtime}, {revdate} substitution variables.

It seems like dates are often spelled out as %Y-%m-%d rather than
%Y%m%d. I don't know where this would explicitly matter, but the former
is always obviously a date, while the latter can sometimes just be a
number, or something else.

Just a thought,
John
=:->
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk3yK/4ACgkQJdeBCYSNAAMivwCglVryPsEbWTimiGQL/MlbMkmH
llUAnjyjHa1dAvmfC4pCXKgheporT7NH
=i2bI
-----END PGP SIGNATURE-----

Revision history for this message
Jelmer Vernooij (jelmer) wrote :

On 06/10/2011 04:36 PM, John Arbash Meinel wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> On 06/10/2011 02:31 PM, Jelmer Vernooij wrote:
>> Jelmer Vernooij has proposed merging lp:~jelmer/bzr-builder/revtime into lp:bzr-builder.
>>
>> Requested reviews:
>> bzr-builder developers (bzr-builder-devs)
>> Related bugs:
>> Bug #793072 in bzr-builder: "Provide deb-version variables for revision commit time/date"
>> https://bugs.launchpad.net/bzr-builder/+bug/793072
>>
>> For more details, see:
>> https://code.launchpad.net/~jelmer/bzr-builder/revtime/+merge/64169
>>
>> Add {revtime}, {revdate} substitution variables.
> It seems like dates are often spelled out as %Y-%m-%d rather than
> %Y%m%d. I don't know where this would explicitly matter, but the former
> is always obviously a date, while the latter can sometimes just be a
> number, or something else.
>
"-" has special meaning in Debian versions, so we usually try to avoid
it. %Y%m is consistent with the existing {time} and {date} substitution
variables.

That said, I think timestamps should generally be avoided as they can be
ambiguous (which of the 5 commits that date was built?).

Cheers,

Jelmer

Revision history for this message
James Westby (james-w) wrote :

Hi,

Perhaps a base class would be useful here as the only difference
is the format string?

Thanks,

James

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches