mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-09-17 14:21:39 +00:00
REPO-5271 Backport new structure to relaese/6.0.0 (#14)
- Simplify dependencies and standardise order - README updated - Green builds - Changes to make Jars in enterprise war match - Changes to make files in enterprise image match - Added travis_wait 40 to the initial build as it can take 20 minutes to download artifacts - Removed TAS tests from .travis.yml but not the code as TAS tests require Java 11 - Added in an empty test so the build runs on feature branches.
This commit is contained in:
46
scripts/travis/update_downstream.sh
Normal file
46
scripts/travis/update_downstream.sh
Normal file
@@ -0,0 +1,46 @@
|
||||
#!/usr/bin/env bash
|
||||
echo "=========================== Starting Update Downstream Script ==========================="
|
||||
PS4="\[\e[35m\]+ \[\e[m\]"
|
||||
set -vex
|
||||
pushd "$(dirname "${BASH_SOURCE[0]}")/../../"
|
||||
|
||||
source "$(dirname "${BASH_SOURCE[0]}")/build_functions.sh"
|
||||
|
||||
DOWNSTREAM_REPO="github.com/Alfresco/alfresco-enterprise-repo.git"
|
||||
|
||||
cloneRepo "${DOWNSTREAM_REPO}" "${TRAVIS_BRANCH}"
|
||||
|
||||
cd "$(dirname "${BASH_SOURCE[0]}")/../../../$(basename "${DOWNSTREAM_REPO%.git}")"
|
||||
|
||||
# Update parent
|
||||
mvn -B versions:update-parent versions:commit
|
||||
|
||||
VERSION="$(sed -n '/<parent>/,/<\/parent>/p' pom.xml \
|
||||
| sed -n '/<version>/,/<\/version>/p' \
|
||||
| tr -d '\n' \
|
||||
| grep -oP '(?<=<version>).*(?=</version>)' \
|
||||
| xargs)"
|
||||
|
||||
# Update dependency version
|
||||
mvn -B versions:set-property versions:commit \
|
||||
-Dproperty=dependency.alfresco-community-repo.version \
|
||||
"-DnewVersion=${VERSION}"
|
||||
|
||||
# Commit changes
|
||||
git status
|
||||
git --no-pager diff pom.xml
|
||||
git add pom.xml
|
||||
|
||||
if git status --untracked-files=no --porcelain | grep -q '^' ; then
|
||||
git commit -m "Update upstream version to ${VERSION}"
|
||||
git push
|
||||
else
|
||||
echo "Dependencies are already up to date."
|
||||
git status
|
||||
fi
|
||||
|
||||
|
||||
popd
|
||||
set +vex
|
||||
echo "=========================== Finishing Update Downstream Script =========================="
|
||||
|
Reference in New Issue
Block a user