Skip to content
Browse files

Additional accessors to BuildData to avoid cross-jar inlining.

This closes #101.
  • Loading branch information...
1 parent 395086f commit 96ddf5e1746bc8ce1ddb6f3a17268dbf270d9cff @tsuna tsuna committed Nov 11, 2012
Showing with 35 additions and 0 deletions.
  1. +35 −0 build-aux/gen_build_data.sh
View
35 build-aux/gen_build_data.sh
@@ -99,6 +99,41 @@ public final class $CLASS {
return "Built on $date by $user@$host:$repo";
}
+ // These functions are useful to avoid cross-jar inlining.
+
+ /** Short revision at which this package was built. */
+ public static String shortRevision() {
+ return short_revision;
+ }
+ /** Full revision at which this package was built. */
+ public static String fullRevision() {
+ return full_revision;
+ }
+ /** UTC date at which this package was built. */
+ public static String date() {
+ return date;
+ }
+ /** UNIX timestamp of the time of the build. */
+ public static long timestamp() {
+ return timestamp;
+ }
+ /** Status of the repository at the time of the build. */
+ public static RepoStatus repoStatus() {
+ return repo_status;
+ }
+ /** Username of the user who built this package. */
+ public static String user() {
+ return user;
+ }
+ /** Host on which this package was built. */
+ public static String host() {
+ return host;
+ }
+ /** Path to the repository in which this package was built. */
+ public static String repo() {
+ return repo;
+ }
+
// Can't instantiate.
private $CLASS() {}
}

0 comments on commit 96ddf5e

Please sign in to comment.
Something went wrong with that request. Please try again.