From a3f45c2d1c9393abb94b4d0951cd5edc54a84823 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=81=A3?= <⁣> Date: Sun, 24 May 2020 23:26:40 +0200 Subject: [PATCH] update --- go/tests/entrypoint.sh | 7 ++----- sh/tests/entrypoint.sh | 8 +++----- 2 files changed, 5 insertions(+), 10 deletions(-) diff --git a/go/tests/entrypoint.sh b/go/tests/entrypoint.sh index d66e17a8e..e81328cf0 100755 --- a/go/tests/entrypoint.sh +++ b/go/tests/entrypoint.sh @@ -10,13 +10,10 @@ cd src/student if test "$REPOSITORY"; then password=$(cat) - if ! git clone --depth=1 --shallow-submodules http://root:"${password}"@"$REPOSITORY" . 2>/dev/null; then - echo Could not clone your repository - exit 1 - fi + git clone --quiet --depth=1 --shallow-submodules http://root:"${password}"@"$REPOSITORY" . else first_file=$(echo "$EXPECTED_FILES" | cut -d' ' -f1) - mkdir "$(dirname $first_file)" + mkdir -p "$(dirname $first_file)" cat > "$first_file" fi diff --git a/sh/tests/entrypoint.sh b/sh/tests/entrypoint.sh index 893d8f413..e6de459a8 100755 --- a/sh/tests/entrypoint.sh +++ b/sh/tests/entrypoint.sh @@ -10,14 +10,12 @@ cd student if test "$REPOSITORY"; then password=$(cat) - if ! git clone --depth=1 --shallow-submodules http://root:"${password}"@"$REPOSITORY" . 2>/dev/null; then - echo Could not clone your repository - exit 1 - fi + git clone --quiet --depth=1 --shallow-submodules http://root:"${password}"@"$REPOSITORY" . else first_file=$(echo "$EXPECTED_FILES" | cut -d' ' -f1) - mkdir "$(dirname $first_file)" + mkdir -p "$(dirname $first_file)" cat > "$first_file" + chmod +x "$first_file" fi cd