diff --git a/mercurial/templates/paper/manifest.tmpl b/mercurial/templates/paper/manifest.tmpl --- a/mercurial/templates/paper/manifest.tmpl +++ b/mercurial/templates/paper/manifest.tmpl @@ -46,11 +46,7 @@ - - [up] - - drwxr-xr-x - +{ifeq(path, up, '', updirentry)} {dentries%direntry} {fentries%fileentry} diff --git a/mercurial/templates/paper/map b/mercurial/templates/paper/map --- a/mercurial/templates/paper/map +++ b/mercurial/templates/paper/map @@ -41,6 +41,15 @@ navshort = '{before%navshortentry}{after navgraph = '{before%navgraphentry}{after%navgraphentry}' filenav = '{before%filenaventry}{after%filenaventry}' +updirentry = ' + + + [up] + + + drwxr-xr-x + ' + direntry = ' diff --git a/tests/test-hgweb-descend-empties.t b/tests/test-hgweb-descend-empties.t --- a/tests/test-hgweb-descend-empties.t +++ b/tests/test-hgweb-descend-empties.t @@ -93,11 +93,7 @@ manifest with descending (paper) - - [up] - - drwxr-xr-x - + @@ -213,11 +209,7 @@ manifest with descending (coal) - - [up] - - drwxr-xr-x - + diff --git a/tests/test-hgweb-empty.t b/tests/test-hgweb-empty.t --- a/tests/test-hgweb-empty.t +++ b/tests/test-hgweb-empty.t @@ -396,11 +396,7 @@ Some tests for hgweb in an empty reposit - - [up] - - drwxr-xr-x - + diff --git a/tests/test-hgweb-symrev.t b/tests/test-hgweb-symrev.t --- a/tests/test-hgweb-symrev.t +++ b/tests/test-hgweb-symrev.t @@ -72,7 +72,6 @@ Set up the repo
  • changeset
  • zip directory / @ 2:9d8c40cba617 - [up] @@ -138,7 +137,6 @@ Set up the repo
  • changeset
  • zip directory / @ 1:a7c1559b7bba - [up] @@ -272,7 +270,6 @@ Set up the repo
  • changeset
  • zip directory / @ 2:9d8c40cba617 - [up] @@ -338,7 +335,6 @@ Set up the repo
  • changeset
  • zip directory / @ 1:a7c1559b7bba - [up] diff --git a/tests/test-hgweb.t b/tests/test-hgweb.t --- a/tests/test-hgweb.t +++ b/tests/test-hgweb.t @@ -287,11 +287,7 @@ try bad style - - [up] - - drwxr-xr-x - + @@ -802,6 +798,17 @@ access bookmarks 200 Script output follows changeset 0:2ef0ac749a14 +no '[up]' entry in file view when in root directory + + $ get-with-headers.py localhost:$HGPORT 'file/tip?style=paper' | grep -F '[up]' + [1] + $ get-with-headers.py localhost:$HGPORT 'file/tip/da?style=paper' | grep -F '[up]' + [up] + $ get-with-headers.py localhost:$HGPORT 'file/tip?style=coal' | grep -F '[up]' + [1] + $ get-with-headers.py localhost:$HGPORT 'file/tip/da?style=coal' | grep -F '[up]' + [up] + no style can be loaded from directories other than the specified paths $ mkdir -p x/templates/fallback