tests/test-hardlinks.t
changeset 40869 f79659e1e50f
parent 40835 a444b7eb4633
child 41964 d121823072b8
equal deleted inserted replaced
40868:109a267acc1e 40869:f79659e1e50f
     1 #require hardlink reporevlogstore
     1 #require hardlink reporevlogstore
     2 
     2 
     3   $ cat > nlinks.py <<EOF
     3   $ cat > nlinks.py <<EOF
     4   > from __future__ import print_function
     4   > from __future__ import print_function
     5   > import sys
     5   > import sys
     6   > from mercurial import util
     6   > from mercurial import pycompat, util
     7   > for f in sorted(sys.stdin.readlines()):
     7   > for f in sorted(sys.stdin.readlines()):
     8   >     f = f[:-1]
     8   >     f = f[:-1]
     9   >     print(util.nlinks(f), f)
     9   >     print(util.nlinks(pycompat.fsencode(f)), f)
    10   > EOF
    10   > EOF
    11 
    11 
    12   $ nlinksdir()
    12   $ nlinksdir()
    13   > {
    13   > {
    14   >     find "$@" -type f | "$PYTHON" $TESTTMP/nlinks.py
    14   >     find "$@" -type f | "$PYTHON" $TESTTMP/nlinks.py