Redo branch redirect

This version of BranchRedirect isn't a BranchRedirectFilter. Instead
this carries just redirects and is applied when a ViewFilter is created,
i.e. the very first step in the process.

The older implementation returned a redirect with a new URL. While this
does the redirect in-place. User does not know if the gitiles command
they requested is transformed to use a new branch. This transformation
is only valid on requests that are not from automation (i.e. HTTP only).

This will also help when the source branch is deleted. Older
implementation didn't work since ViewFilter wasn't created on deleted
or non-existent branch.

PiperOrigin-RevId: 411156730
Change-Id: I4193a86d36e3d46cb19abf9c7b52a94b1feef5c1
11 files changed
tree: 1fbca76ce613f6fe63225a3d4df4e227016698d3
  1. .settings/
  2. Documentation/
  3. java/
  4. javatests/
  5. lib/
  6. resources/
  7. tools/
  8. .bazelrc
  9. .bazelversion
  10. .gitignore
  11. .mailmap
  12. BUILD
  13. COPYING
  14. README.md
  15. WORKSPACE
  16. fake_pom_deploy.xml
  17. navbar.md
  18. version.bzl
README.md

Gitiles - A simple JGit repository browser

Gitiles is a simple repository browser for Git repositories, built on JGit. Its guiding principle is simplicity: it has no formal access controls, no write access, no fancy Javascript, etc.

Gitiles automatically renders *.md Markdown files into HTML for simplified documentation. Refer to the Markdown documentation for details.

Configuration

Gitiles is configurable in a git-style configuration file named gitiles.config. Refer to the configuration documentation for details.

Bugs

Use the issue tracker at github to file bugs.

Contributing to Gitiles

Please refer to the Developer Guide.