Gitea: head.tmpl cannot be customized - crashes

Created on 9 Aug 2018  路  4Comments  路  Source: go-gitea/gitea

  • Gitea version (or commit ref): 1.5
  • Git version: 2.18
  • Operating system: CentOS
  • Database (use [x]):

    • [ ] PostgreSQL

    • [x] MySQL

    • [ ] MSSQL

    • [ ] SQLite

  • Can you reproduce the bug at https://try.gitea.io:

    • [ ] Yes (provide example URL)

    • [ ] No

    • [x] Not relevant

  • Log gist:

Description

Please excuse the fact that I鈥檓 on mobile and cannot fully complete this form.

The issue is simple: creating [gitea root dir]/custom/templates/base/head.tmpl and importing the default head.tmpl will not allow Gitea to run.

Putting a simple head.tmpl with just html allows it to run but this prevents making simple modifications (like removing buttons) a real pain.

I鈥檝e worked around it by making a custom .../custom/templates/header.tmpl (not a typo) and importing JS to remove the elements I don鈥檛 want.

If there is a better way to modify the navigation links than replacing the head.tmpl with my own, slightly modified version, I鈥檓 all ears.

Screenshots

kinquestion

All 4 comments

Yes there is custom/templates/custom/... templates that can be used to add css and scripts. See docs section customization for more details

In future please use forum (https://discourse.gitea.io/) for such questions

This isn鈥檛 a question. Please read again.

And you鈥檙e supposed to be able to override existing templates by putting them in /templates/path/like/source.

This is not working.

You closed my issue for the wrong reason.

Please read again.

I put the parts in bold that are important here. You reacted to the wrong statement.

You guys constantly close issues that are actual issues; wondering if you actually read the issue.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

jorise7 picture jorise7  路  3Comments

internalfx picture internalfx  路  3Comments

cookiengineer picture cookiengineer  路  3Comments

BNolet picture BNolet  路  3Comments

adpande picture adpande  路  3Comments