tests: store ETag when using --headeronly
Previously, --headeronly would prevent --twice from working
because the ETag wasn't stored when --headeronly was used.
This feels like a bug. That feeling is reaffirmed by the fact
that this change doesn't regress any tests.
hgweb: extract path traversal checking into standalone function
A common exploit in web applications that access paths is to insert
path separator strings like ".." to try to get the server to serve up
files it shouldn't.
We have code for detecting this in staticfile(). A subsequent commit
will need to perform this test as well. Since this is security code,
let's factor the check so we don't have to reinvent the wheel.
tags: rename "head" to "node" where we don't care
Followup to
5eb4d206202b (tags: extract fnode retrieval into its own
function, 2017-03-28) in which the "for head in head" became "for head
in nodes".
manifest: update comment to be about bytearray
Looks like a leftover from
2a18e9e6ca43 (py3: use bytearray() instead
of array('c', ...) constructions, 2017-03-12).
hgweb: rename linerangelog.js as followlines.js
So that the file name matches both the feature name and user facing vocabulary
(e.g. the revset function).
hgweb: rely on a specific class to change cursor type in followlines UI
The previous CSS rule would also apply in pages where followlines UI was not
available (e.g. "changeset" view at /rev/<node>/). We insert a
"followlines-select" class in JavaScript on actually selectable lines and
restrict the CSS selector to use it.