Revert "Creating orphan branch"

This commit is contained in:
Stefan Zweifel 2020-09-11 11:18:24 +02:00 committed by GitHub
parent d51384f592
commit b3fc6f8a17
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,7 +1,6 @@
#!/bin/bash
set -eu
set -x
_main() {
_switch_to_repository
@ -40,13 +39,8 @@ _git_is_dirty() {
_switch_to_branch() {
echo "INPUT_BRANCH value: $INPUT_BRANCH";
if git show-ref --verify --quiet refs/heads/$INPUT_BRANCH; then
# Switch to branch from current Workflow run
git checkout $INPUT_BRANCH;
else
git checkout --orphan $INPUT_BRANCH
git rm -rf .
fi
# Switch to branch from current Workflow run
git checkout $INPUT_BRANCH;
}
_add_files() {