Skip to content

Commit

Permalink
ci: changed from GH_DEVELOPMENT_PAT env var to KALISIO_GITHUB_URL
Browse files Browse the repository at this point in the history
  • Loading branch information
claustres committed Jul 23, 2024
1 parent 1cd1ee4 commit 83faaac
Showing 1 changed file with 3 additions and 10 deletions.
13 changes: 3 additions & 10 deletions scripts/setup_workspace.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,21 +5,16 @@ set -euo pipefail
THIS_FILE=$(readlink -f "${BASH_SOURCE[0]}")
THIS_DIR=$(dirname "$THIS_FILE")
ROOT_DIR=$(dirname "$THIS_DIR")
WORKSPACE_DIR="$(dirname "$ROOT_DIR")"

. "$THIS_DIR/kash/kash.sh"

## Parse options
##

WORKSPACE_BRANCH=
WORKSPACE_TAG=

begin_group "Setting up workspace ..."

if [ "$CI" = true ]; then
WORKSPACE_DIR="$(dirname "$ROOT_DIR")"
DEVELOPMENT_REPO_URL="https://$GITHUB_DEVELOPMENT_PAT@github.com/kalisio/development.git"
else
if [ "$CI" != true ]; then
while getopts "b:t" option; do
case $option in
b) # defines branch
Expand All @@ -30,14 +25,12 @@ else
;;
esac
done

shift $((OPTIND-1))
WORKSPACE_DIR="$1"

# Clone project in the workspace
git_shallow_clone "$KALISIO_GITHUB_URL/weacast/weacast-app.git" "$WORKSPACE_DIR/weacast-app" "${WORKSPACE_TAG:-${WORKSPACE_BRANCH:-}}"

# unset KALISIO_DEVELOPMENT_DIR because we want kli to clone everyhting in $WORKSPACE_DIR
unset KALISIO_DEVELOPMENT_DIR
fi

setup_lib_workspace "$WORKSPACE_DIR" "$KALISIO_GITHUB_URL/kalisio/development.git"
Expand Down

0 comments on commit 83faaac

Please sign in to comment.