Skip to content

Commit

Permalink
set fetch depth
Browse files Browse the repository at this point in the history
  • Loading branch information
ahmad-el-sayed committed Oct 8, 2024
1 parent 0a948d0 commit 76588e2
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions scripts/manage_docker_image.sh
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,9 @@ function docker_pull() {

function get_default_branch_name() {
local repo_path="$1"
git -C ${repo_path} fetch --unshallow
#git -C ${repo_path} fetch --unshallow
git -C ${repo_path} fetch --depth=10000
git -C ${repo_path} fetch --all
git -C ${repo_path} remote set-head origin --auto
echo $(
git -C "${repo_path}" symbolic-ref refs/remotes/origin/HEAD |
Expand All @@ -212,7 +214,9 @@ function get_default_branch_name() {

function get_parent_branch_name() {
local repo_path="$1"
git -C ${repo_path} fetch --unshallow
#git -C ${repo_path} fetch --unshallow
git -C ${repo_path} fetch --depth=10000
git -C ${repo_path} fetch --all
git -C ${repo_path} remote set-head origin --auto
echo $(
git -C ${repo_path} show-branch |
Expand Down

0 comments on commit 76588e2

Please sign in to comment.