Skip to content
This repository has been archived by the owner on Mar 22, 2023. It is now read-only.

Update versions of catch and rapidcheck #90

Merged
merged 1 commit into from Oct 1, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion cmake/findCatch.cmake
Expand Up @@ -70,7 +70,7 @@ if ("${catch_INCLUDE_DIR}" STREQUAL "catch_INCLUDE_DIR-NOTFOUND")
ExternalProject_Add(catchFromGit
PREFIX "${PROJECT_BINARY_DIR}/external/catch"
GIT_REPOSITORY "https://github.com/philsquared/Catch"
GIT_TAG "v1.6.0" # TODO Latest version known to work
GIT_TAG "v1.9.7"
#
# No configure or build neccessary
CONFIGURE_COMMAND ""
Expand Down
18 changes: 16 additions & 2 deletions external/get.lib.sh
Expand Up @@ -135,10 +135,16 @@ checkout_repo () {
I_WHAT="$2"
# the file to check after checkout
I_CHECKFILE="$3"
# which branch to checkout
# which branch or commit to checkout
I_BRANCH="$4"

# No branch specified
# Check whether the branch is actually a commit
if echo "$I_BRANCH" | grep -qE '[0-9a-f]{40}'; then
I_COMMIT="$I_BRANCH"
I_BRANCH=""
fi

# Branch specified
if [ "$I_BRANCH" ]; then
I_EXTRA=" (branch: $I_BRANCH)"
I_ARGS="--branch $I_BRANCH"
Expand All @@ -150,7 +156,15 @@ checkout_repo () {
return 1
fi

# Clone and switch to commit if needed
git clone $I_ARGS --recursive "$I_FROM" "$I_WHAT" || return 1
if [ "$I_COMMIT" ]; then
OPWD="$PWD"
cd "$I_WHAT"
echo "-- Switching to commit $I_COMMIT"
git checkout --detach "$I_COMMIT" || return 1
cd "$OPWD"
fi
if [ -f "$I_WHAT/$I_CHECKFILE" ]; then
mark_update_done "$I_WHAT" || return 1
return 0
Expand Down
2 changes: 1 addition & 1 deletion external/get_rapidcheck.sh
Expand Up @@ -40,7 +40,7 @@ INTERVAL="3600"
CHECKFILE="CMakeLists.txt"

# Branch to checkout (empty for default)
BRANCH=""
BRANCH="9eb1e620cf84aa6bec638ef7bb1ed6e4989f43a2"

if [ ! -f "$PWD/get.lib.sh" ]; then
echo "PWD needs to be the location of the get.lib.sh file."
Expand Down