tests/test-merge-types
changeset 12279 28e2e3804f2e
parent 12278 c4c2ba553401
child 12280 6ee719f56f01
equal deleted inserted replaced
12278:c4c2ba553401 12279:28e2e3804f2e
     1 #!/bin/sh
       
     2 
       
     3 hg init
       
     4 echo a > a
       
     5 hg ci -Amadd       # 0
       
     6 
       
     7 chmod +x a
       
     8 hg ci -mexecutable # 1
       
     9 
       
    10 hg up 0
       
    11 rm a
       
    12 ln -s symlink a
       
    13 hg ci -msymlink    # 2
       
    14 hg merge --debug
       
    15 
       
    16 echo % symlink is local parent, executable is other
       
    17 
       
    18 if [ -h a ]; then
       
    19     echo a is a symlink
       
    20     $TESTDIR/readlink.py a
       
    21 elif [ -x a ]; then
       
    22     echo a is executable
       
    23 else
       
    24     echo "a has no flags (default for conflicts)"
       
    25 fi
       
    26 
       
    27 hg update -C 1
       
    28 hg merge --debug
       
    29 
       
    30 echo % symlink is other parent, executable is local
       
    31 
       
    32 if [ -h a ]; then
       
    33     echo a is a symlink
       
    34     $TESTDIR/readlink.py a
       
    35 elif [ -x a ]; then
       
    36     echo a is executable
       
    37 else
       
    38     echo "a has no flags (default for conflicts)"
       
    39 fi