diff --git a/setup/git_post_checkout_hook.py b/setup/git_post_checkout_hook.py index cc0fded419..04c5047a5b 100755 --- a/setup/git_post_checkout_hook.py +++ b/setup/git_post_checkout_hook.py @@ -19,7 +19,7 @@ def get_branch_name(rev): if flags == '1': # A branch checkout prev_branch, cur_branch = list(map(get_branch_name, (prev_rev, current_rev))) - if 'qt6' in (prev_branch, cur_branch): + if {prev_branch, cur_branch} == {'master', 'qt6'}: os.rename('bypy/b/other-b', 'bypy/c') os.rename('bypy/b', 'bypy/c/other-b') os.rename('bypy/c', 'bypy/b')