gitbutler/crates/gitbutler-branch-actions/tests/fixtures/for-workspace-migration.sh
2024-09-02 20:53:19 +03:00

19 lines
502 B
Bash

#!/usr/bin/env bash
set -eu -o pipefail
CLI=${1:?The first argument is the GitButler CLI}
git init remote
(cd remote
echo first > file
git add . && git commit -m "init"
)
export GITBUTLER_CLI_DATA_DIR=../user/gitbutler/app-data
git clone remote workspace-migration
(cd workspace-migration
$CLI project add --switch-to-workspace "$(git rev-parse --symbolic-full-name @{u})"
$CLI branch create virtual
# Start the test on the old integration branch.
git checkout -b gitbutler/integration
)