# HG changeset patch # User Christopher Springer # Date 1467905630 -3600 # Node ID 6cbe6a8597db4860a34717e71c778d1e687c9794 # Parent b3cb5db317a046e9d59a5b5c51e2d5b7e754139f USASR-2244: Attempt to simplify changes to init script by placing hg pull in findSnapshotVersion method diff -r b3cb5db317a0 -r 6cbe6a8597db init20.gradle --- a/init20.gradle Thu Jul 07 16:25:34 2016 +0100 +++ b/init20.gradle Thu Jul 07 16:33:50 2016 +0100 @@ -48,17 +48,11 @@ gradle.ext.buildTimestamp = System.currentTimeMillis().toString().padLeft(14, '0') gradle.ext.hgRepositoryUrl = "" + try { gradle.ext.hgRepositoryUrl = ("hg path".execute().text.split('=') ?: ['', ''])[1].trim() } catch (e) { } -try { - if (gradle.ext.bambooBuild) { - "hg pull".execute() - } -} catch (e) { - logger.error "exception thrown attempting to pull all changesets from mercurial", e -} def springModuleTranslator = [ 'spring-transaction': 'spring-tx', @@ -804,6 +798,7 @@ } private findSnapshotVersion() { + "hg pull".execute() def versions = "hg branches --closed".execute().text.split('\n').findAll { it.startsWith( 'release') || it.startsWith( 'hotfix') }.collect {