Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move color settings from taskrc to default.theme #3669

Open
d2718nis opened this issue Nov 5, 2024 · 2 comments · May be fixed by #3775
Open

Move color settings from taskrc to default.theme #3669

d2718nis opened this issue Nov 5, 2024 · 2 comments · May be fixed by #3775
Assignees
Labels
good first issue Good for newcomers topic:themes Issues related to color themes or colorized output

Comments

@d2718nis
Copy link
Contributor

d2718nis commented Nov 5, 2024

Issue

As previously discussed, it would be beneficial to separate the default color theme from other configuration settings in taskrc. This change would ensure that new color settings don’t unintentionally bypass no-color.theme in case it omits them by mistake. Separating color settings would also improve the organization of configuration files.

Solution

Relocate all color. related settings from the default taskrc template to a new default.theme file. Use include default.theme to apply these color settings, like here.

@djmitche djmitche moved this from Backlog to Ready in Taskwarrior Development Nov 6, 2024
@djmitche djmitche added the topic:themes Issues related to color themes or colorized output label Nov 20, 2024
@djmitche djmitche added the good first issue Good for newcomers label Jan 8, 2025
@linsaraj
Copy link

linsaraj commented Feb 5, 2025

Hi! This is my first time contributing and I would like to contribute/be assigned this good first issue if possible! Just so I understand, do you just want to move the .color settings into a newly created file named "default.theme" and then include that file using "#include" into the Context.cpp file? Does the .color settings include any lines that have .color in them (lines 210-280 in the Context.cpp file)?

@djmitche
Copy link
Collaborator

djmitche commented Feb 5, 2025

Hi @linsaraj! Yes, that's the idea! I think the #include would be added to

taskwarrior/src/Context.cpp

Lines 1182 to 1197 in fdb7e5e

<< "\n# Color theme (uncomment one to use)\n"
<< "#include light-16.theme\n"
<< "#include light-256.theme\n"
<< "#include bubblegum-256.theme\n"
<< "#include dark-16.theme\n"
<< "#include dark-256.theme\n"
<< "#include dark-red-256.theme\n"
<< "#include dark-green-256.theme\n"
<< "#include dark-blue-256.theme\n"
<< "#include dark-violets-256.theme\n"
<< "#include dark-yellow-green.theme\n"
<< "#include dark-gray-256.theme\n"
<< "#include dark-gray-blue-256.theme\n"
<< "#include solarized-dark-256.theme\n"
<< "#include solarized-light-256.theme\n"
<< "#include no-color.theme\n"

@djmitche djmitche moved this from Ready to In progress in Taskwarrior Development Feb 5, 2025
@djmitche djmitche linked a pull request Feb 7, 2025 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers topic:themes Issues related to color themes or colorized output
Projects
Status: In progress
Development

Successfully merging a pull request may close this issue.

3 participants