Skip to content

Commit 67f17c8

Browse files
authored
jjui: init (#2109)
Link: #2109 Link: https://github.com/vic/tinted-jjui Reviewed-by: NAHO <[email protected]> Reviewed-by: 0xda157 <[email protected]> Tested-by: 0xda157 <[email protected]>
1 parent 3da76b6 commit 67f17c8

File tree

4 files changed

+162
-0
lines changed

4 files changed

+162
-0
lines changed

generated/all-maintainers.nix

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,11 @@
4343
matrix = "@mrsom3body:matrix.org";
4444
name = "Karun Sandhu";
4545
};
46+
Noah765 = {
47+
github = "Noah765";
48+
githubId = 99338019;
49+
name = "Noah765";
50+
};
4651
Noodlez1232 = {
4752
email = "[email protected]";
4853
github = "Noodlez1232";

modules/jjui/hm.nix

Lines changed: 132 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,132 @@
1+
{ mkTarget, lib, ... }:
2+
mkTarget {
3+
config =
4+
{ colors, polarity }:
5+
{
6+
programs.jjui.settings.ui.colors = with colors.withHashtag; {
7+
# Original template author: Victor Borja <[email protected]> (https://github.com/vic)
8+
# See https://github.com/vic/tinted-jjui
9+
10+
text.fg = base05;
11+
text.bg = base00;
12+
dimmed.fg = base03;
13+
dimmed.bg = base00;
14+
title.fg = base0D;
15+
title.bold = true;
16+
shortcut.fg = base0E;
17+
matched.fg = base0A;
18+
border.fg = base03;
19+
selected = {
20+
fg = base05;
21+
bg = base01;
22+
bold = true;
23+
};
24+
25+
source_marker = {
26+
fg = base00;
27+
bg = base0C;
28+
bold = true;
29+
};
30+
target_marker = {
31+
fg = base00;
32+
bg = base0B;
33+
bold = true;
34+
};
35+
36+
status.bg = base01;
37+
"status title" = {
38+
fg = base00;
39+
bg = base0D;
40+
bold = true;
41+
};
42+
43+
"revset title" = {
44+
fg = base0D;
45+
bg = lib.mkIf (polarity != "dark") base01;
46+
bold = true;
47+
};
48+
"revset text".fg = base05;
49+
"revset text".bold = true;
50+
"revset completion text".fg = base05;
51+
"revset completion matched".fg = base0A;
52+
"revset completion matched".bold = true;
53+
"revset completion dimmed".fg = base03;
54+
"revset completion selected".bg = if polarity == "dark" then base02 else base06;
55+
"revset completion selected".fg = if polarity == "dark" then base05 else base02;
56+
57+
revisions.fg = base05;
58+
"revisions selected".bg = if polarity == "dark" then base01 else base02;
59+
"revisions dimmed".fg = base03;
60+
"revisions details selected".bg = if polarity == "dark" then base02 else base04;
61+
"oplog selected".bold = true;
62+
63+
evolog.fg = base05;
64+
"evolog selected" = {
65+
fg = if polarity == "dark" then base05 else base01;
66+
bg = if polarity == "dark" then base02 else base06;
67+
bold = true;
68+
};
69+
70+
menu.bg = base00;
71+
"menu title" = {
72+
fg = base00;
73+
bg = base0E;
74+
bold = true;
75+
};
76+
"menu shortcut".fg = base0E;
77+
"menu matched".fg = base0A;
78+
"menu matched".bold = true;
79+
"menu dimmed".fg = base03;
80+
"menu border".fg = base01;
81+
"menu selected".fg = if polarity == "dark" then base05 else base01;
82+
"menu selected".bg = if polarity == "dark" then base02 else base06;
83+
84+
help.bg = base00;
85+
"help title" = {
86+
fg = base0B;
87+
bold = true;
88+
underline = true;
89+
};
90+
"help border".fg = base01;
91+
92+
preview.fg = base05;
93+
"preview border".fg = base01;
94+
95+
confirmation.bg = base00;
96+
"confirmation text".fg = base0D;
97+
"confirmation text".bold = true;
98+
"confirmation dimmed".fg = base03;
99+
"confirmation border".fg = base08;
100+
"confirmation border".bold = true;
101+
"confirmation selected".fg = if polarity == "dark" then base05 else base01;
102+
"confirmation selected".bg = if polarity == "dark" then base02 else base06;
103+
104+
undo.bg = base00;
105+
"undo confirmation dimmed".fg = base03;
106+
"undo confirmation selected".fg = if polarity == "dark" then base05 else base01;
107+
"undo confirmation selected".bg = if polarity == "dark" then base02 else base06;
108+
109+
success.fg = base0B;
110+
success.bold = true;
111+
error.fg = base08;
112+
error.bold = true;
113+
"revisions rebase source_marker".bold = true;
114+
"revisions rebase target_marker".bold = true;
115+
"status shortcut".fg = base0E;
116+
"status dimmed".fg = base03;
117+
118+
details.fg = base05;
119+
"details selected".bold = true;
120+
completion.fg = base05;
121+
"completion selected".bold = true;
122+
rebase.bold = true;
123+
124+
workspace.fg = base0D;
125+
branch.fg = base09;
126+
commit.fg = base0B;
127+
file.fg = base0A;
128+
change.fg = base08;
129+
bookmark.fg = base0E;
130+
};
131+
};
132+
}

modules/jjui/meta.nix

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{ lib, ... }:
2+
{
3+
name = "jjui";
4+
homepage = "https://github.com/idursun/jjui";
5+
maintainers = [ lib.maintainers.Noah765 ];
6+
}

modules/jjui/testbeds/jjui.nix

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
{ lib, ... }:
2+
{
3+
stylix.testbed.ui.command = {
4+
text = ''
5+
cd "$(mktemp --directory)"
6+
7+
jj git init
8+
jjui
9+
'';
10+
useTerminal = true;
11+
};
12+
13+
home-manager.sharedModules = lib.singleton {
14+
programs = {
15+
jujutsu.enable = true;
16+
jjui.enable = true;
17+
};
18+
};
19+
}

0 commit comments

Comments
 (0)