OpenIDE-Module-Build-Version's timestamp value uses a wrong format
------------------------------------------------------------------
Key: MNBMODULE-84
URL: http://jira.codehaus.org/browse/MNBMODULE-84
Project: Maven 2.x Netbeans Module Plugin
Issue Type: Bug
Affects Versions: 3.2
Reporter: Mykola Nikishov
Assignee: Milos Kleint
Current implementation creates a timestamp for OpenIDE-Module-Build-Version
manifest's field with hours in 'am/pm' format like:
OpenIDE-Module-Build-Version: 201007010848
when run on
LANG=C date --utc
Thu Jul 1 17:48:13 UTC 2010
I've fixed this, see
http://github.com/manandbytes/nbm-maven-plugin/commits/build-version-timestamp
for details.
What was changed:
Pattern was changed to represent hours in a 24h format.
java.text.SimpleDateFormat uses an instance of java.util.Calendar initialized
with a default timezone provided by java.util.TimeZone.getDefault(). Configure
date formatter with UTC
time-zone explicitly to prevent possible locale-dependent side-effects.
And as a final step code to create and format timestamp was extracted to a
private method createTimestamp().
Now the timestamp will be created in a 24h format and independent from the
local timezone:
OpenIDE-Module-Build-Version: 201007011745
when invoked on
LANG=C date --utc
Thu Jul 1 17:45:36 UTC 2010
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email