Using gitea:latest docker image cant change theme? #4288

Closed
opened 2025-11-02 05:44:53 -06:00 by GiteaMirror · 6 comments
Owner

Originally created by @thepenguinthatwants on GitHub (Nov 12, 2019).

Hi!
Using docker-compose and traefik
postgres:9.6 and gitea/gitea:latest

I changed the registration settings on app.ini and it worked but adding this

[ui]
THEMES = arc-green
DEFAULT_THEME = arc-green
THEME_COLOR_META_TAG = #6cc644

didnt change the default theme.

Originally created by @thepenguinthatwants on GitHub (Nov 12, 2019). Hi! Using docker-compose and traefik postgres:9.6 and gitea/gitea:latest I changed the registration settings on app.ini and it worked but adding this [ui] THEMES = arc-green DEFAULT_THEME = arc-green THEME_COLOR_META_TAG = `#6cc644` didnt change the default theme.
GiteaMirror added the issue/stale label 2025-11-02 05:44:53 -06:00
Author
Owner

@thepenguinthatwants commented on GitHub (Nov 12, 2019):

It did change the gloabl theme, but didnt change the users theme? Oh it was the user account settings.

@thepenguinthatwants commented on GitHub (Nov 12, 2019): It did change the gloabl theme, but didnt change the users theme? Oh it was the user account settings.
Author
Owner

@sapk commented on GitHub (Nov 12, 2019):

Currently, if the user as the default theme (not arc-green) set before it will keep the default theme currently but will not be able to set it again if it change from the settings.

An easy fix should be to check available themes here: 01a4a7cb14/models/user.go (L196)
with a func similar to 171b359877/modules/auth/user_form.go (L253) which check if theme exist.

@sapk commented on GitHub (Nov 12, 2019): Currently, if the user as the default theme (not arc-green) set before it will keep the default theme currently but will not be able to set it again if it change from the settings. An easy fix should be to check available themes here: https://github.com/go-gitea/gitea/blob/01a4a7cb14b3a48f9e8115d5bc93af7ae17f1275/models/user.go#L196 with a func similar to https://github.com/go-gitea/gitea/blob/171b3598778a1ecd0a921c71ed6755bfef68f7f0/modules/auth/user_form.go#L253 which check if theme exist.
Author
Owner

@thepenguinthatwants commented on GitHub (Nov 12, 2019):

Hi!

Thanks for the explanation.

@thepenguinthatwants commented on GitHub (Nov 12, 2019): Hi! Thanks for the explanation.
Author
Owner

@fractalf commented on GitHub (Dec 8, 2019):

You can change the theme of an existing user by editing the database

sqlite> select id,name,theme from user;
1|foobar|gitea
sqlite> update user set theme='arc-green' where id=1;
sqlite> select id,name,theme from user;
1|foobar|arc-green
@fractalf commented on GitHub (Dec 8, 2019): You can change the theme of an existing user by editing the database ``` sqlite> select id,name,theme from user; 1|foobar|gitea sqlite> update user set theme='arc-green' where id=1; sqlite> select id,name,theme from user; 1|foobar|arc-green ```
Author
Owner

@stale[bot] commented on GitHub (Feb 6, 2020):

This issue has been automatically marked as stale because it has not had recent activity. I am here to help clear issues left open even if solved or waiting for more insight. This issue will be closed if no further activity occurs during the next 2 weeks. If the issue is still valid just add a comment to keep it alive. Thank you for your contributions.

@stale[bot] commented on GitHub (Feb 6, 2020): This issue has been automatically marked as stale because it has not had recent activity. I am here to help clear issues left open even if solved or waiting for more insight. This issue will be closed if no further activity occurs during the next 2 weeks. If the issue is still valid just add a comment to keep it alive. Thank you for your contributions.
Author
Owner

@stale[bot] commented on GitHub (Feb 20, 2020):

This issue has been automatically closed because of inactivity. You can re-open it if needed.

@stale[bot] commented on GitHub (Feb 20, 2020): This issue has been automatically closed because of inactivity. You can re-open it if needed.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#4288