# HG changeset patch # User Anton Shestakov # Date 1527764008 -28800 # Node ID 273ce823ba5c657623441bcde526e54811c90fb1 # Parent 9ed3527019b5f214558aae2a37e507674ac08bfa spartan: don't show '[up]' in file view when in root directory already diff -r 9ed3527019b5 -r 273ce823ba5c mercurial/templates/spartan/manifest.tmpl --- a/mercurial/templates/spartan/manifest.tmpl Thu May 31 18:39:35 2018 +0800 +++ b/mercurial/templates/spartan/manifest.tmpl Thu May 31 18:53:28 2018 +0800 @@ -17,12 +17,7 @@

Mercurial {pathdef%breadcrumb} / files for changeset {node|short}: {path|escape}

- - +{ifeq(path, up, '', updirentry)} {dentries%direntry} {fentries%fileentry}
drwxr-xr-x  -   -   - [up] -
diff -r 9ed3527019b5 -r 273ce823ba5c mercurial/templates/spartan/map --- a/mercurial/templates/spartan/map Thu May 31 18:39:35 2018 +0800 +++ b/mercurial/templates/spartan/map Thu May 31 18:53:28 2018 +0800 @@ -25,6 +25,16 @@ navgraph = '{before%navgraphentry}{after%navgraphentry}' filenav = '{before%filenaventry}{after%filenaventry}' +updirentry = ' + + drwxr-xr-x  +   +   + + [up] + + ' + direntry = ' drwxr-xr-x  diff -r 9ed3527019b5 -r 273ce823ba5c tests/test-hgweb-descend-empties.t --- a/tests/test-hgweb-descend-empties.t Thu May 31 18:39:35 2018 +0800 +++ b/tests/test-hgweb-descend-empties.t Thu May 31 18:53:28 2018 +0800 @@ -504,12 +504,7 @@

Mercurial / files for changeset c9f45f7a1659: /

- - + diff -r 9ed3527019b5 -r 273ce823ba5c tests/test-hgweb-symrev.t --- a/tests/test-hgweb-symrev.t Thu May 31 18:39:35 2018 +0800 +++ b/tests/test-hgweb-symrev.t Thu May 31 18:53:28 2018 +0800 @@ -956,7 +956,6 @@ changesetzip

Mercurial / files for changeset 9d8c40cba617: /

- @@ -1029,7 +1028,6 @@ changesetzip

Mercurial / files for changeset a7c1559b7bba: /

- diff -r 9ed3527019b5 -r 273ce823ba5c tests/test-hgweb.t --- a/tests/test-hgweb.t Thu May 31 18:39:35 2018 +0800 +++ b/tests/test-hgweb.t Thu May 31 18:53:28 2018 +0800 @@ -816,6 +816,10 @@ [1] $ get-with-headers.py localhost:$HGPORT 'file/tip/da?style=monoblue' | grep -F '[up]' [up] + $ get-with-headers.py localhost:$HGPORT 'file/tip?style=spartan' | grep -F '[up]' + [1] + $ get-with-headers.py localhost:$HGPORT 'file/tip/da?style=spartan' | grep -F '[up]' + [up] no style can be loaded from directories other than the specified paths
drwxr-xr-x  -   -   - [up] -
drwxr-xr-x  [up] dir/ foo [up] dir/ foo