Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ echo "Created working directory: ${WORKDIR}"
pushd "${WORKDIR}" # cd into workdir

echo "Cloning source repository: ${SOURCE_REPO}"
git clone --recurse-submodules --recurse-submodules "git@github.com:${SOURCE_REPO}.git" source-repo
git clone --recurse-submodules "git@github.com:${SOURCE_REPO}.git" source-repo

pushd source-repo

Expand Down Expand Up @@ -124,7 +124,7 @@ git filter-branch \
--force \
--prune-empty \
--tree-filter \
"git submodule update --init --recursive; find . -mindepth 2 -name .git -exec rm -rf {} +; git submodule update --init --recursive; find . -mindepth 2 -name .git -exec rm -rf {} +; shopt -s dotglob; mkdir -p ${WORKDIR}/migrated-source; mv * ${WORKDIR}/migrated-source; mkdir -p ${TARGET_PATH}; { mv ${WORKDIR}/migrated-source/* ${TARGET_PATH} || echo 'No files to move' ; }"
"git submodule update --init --recursive; find . -mindepth 2 -name .git -exec rm -rf {} +; shopt -s dotglob; mkdir -p ${WORKDIR}/migrated-source; mv * ${WORKDIR}/migrated-source; mkdir -p ${TARGET_PATH}; { mv ${WORKDIR}/migrated-source/* ${TARGET_PATH} || echo 'No files to move' ; }"

# back to workdir
popd
Expand All @@ -142,7 +142,7 @@ echo "Success"
popd # back to workdir

# Do a diff between source code split repo and migrated code.
git clone --recurse-submodules --recurse-submodules "git@github.com:${SOURCE_REPO}.git" source-repo-validation # Not ideal to clone again.
git clone --recurse-submodules "git@github.com:${SOURCE_REPO}.git" source-repo-validation # Not ideal to clone again.
find source-repo-validation -name .git -exec rm -rf {} + # That folder is not needed for validation.

DIFF_FILE="${WORKDIR}/diff.txt"
Expand Down
Loading