-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
30 changed files
with
700 additions
and
131 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,6 +25,9 @@ let | |
lieer | ||
moneydance | ||
pointless-xcompose | ||
sf-symbols | ||
sketchybar-font | ||
sketchybar-lua | ||
xcompose; | ||
}; | ||
}; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
{ stdenvNoCC | ||
, sources | ||
, p7zip | ||
}: | ||
|
||
stdenvNoCC.mkDerivation { | ||
pname = "sf-symbols"; | ||
version = "5"; | ||
src = sources.sf-symbols; | ||
dontUnpack = true; | ||
nativeBuildInputs = [ p7zip ]; | ||
installPhase = '' | ||
7z x "$src" | ||
cd SFSymbols | ||
7z x "SF Symbols.pkg" | ||
7z x "Payload~" | ||
mkdir -p "$out/share/fonts/opentype" "$out/share/fonts/truetype" | ||
mv Library/Fonts/*.otf "$out/share/fonts/opentype" | ||
mv Library/Fonts/*.ttf "$out/share/fonts/truetype" | ||
''; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{ stdenvNoCC | ||
, sources | ||
}: | ||
|
||
stdenvNoCC.mkDerivation { | ||
pname = "sketchybar-font"; | ||
version = "1.0.21"; | ||
src = sources.sketchybar-font; | ||
dontUnpack = true; | ||
installPhase = '' | ||
runHook preInstall | ||
install -Dm644 "$src" "$out/share/fonts/truetype/sketchybar-app-font.ttf" | ||
runHook postInstall | ||
''; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
{ stdenv | ||
, sources | ||
, clang | ||
, gcc | ||
, readline | ||
}: | ||
|
||
stdenv.mkDerivation { | ||
pname = "sketchybar-lua"; | ||
version = "0.0.0.0"; | ||
src = sources.sketchybar-lua; | ||
nativeBuildInputs = [ clang gcc ]; | ||
buildInputs = [ readline ]; | ||
installPhase = '' | ||
mv bin "$out" | ||
''; | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
config: pkgs: | ||
|
||
let | ||
|
||
kitty = "${config.programs.kitty.package}/bin/kitty"; | ||
jq = "${pkgs.jq}/bin/jq"; | ||
|
||
format = f: x: pkgs.lib.colors.format "0xff%R%G%B" (f x); | ||
id = x: x; | ||
foregroundFor = config.theme.colors.nominal.foregroundFor; | ||
colors = pkgs.lib.colors.transformColors (format id) config.theme.colors; | ||
foreground = pkgs.lib.colors.transformColors (format foregroundFor) config.theme.colors; | ||
|
||
in { | ||
"sketchybar".source = pkgs.runCommandNoCC "sketchybarrc" {} '' | ||
cp -r "${./sketchybar}" "$out" | ||
substituteInPlace "$out/sketchybarrc" \ | ||
--replace @@LUA@@ "${pkgs.lua5_4}" \ | ||
--replace @@SKETCHYBAR_LUA_SO@@ "${pkgs.sketchybar-lua}" | ||
substituteInPlace "$out/colors.lua" \ | ||
--replace @@COLORS_UNIFYING@@ ${colors.semantic.unifying} \ | ||
--replace @@COLORS_PRIMARY_BG@@ ${colors.semantic.background} \ | ||
--replace @@COLORS_PRIMARY_FG@@ ${colors.semantic.foreground} \ | ||
--replace @@COLORS_SECONDARY_BG@@ ${colors.semantic.background_highlighted} \ | ||
--replace @@COLORS_SECONDARY_FG@@ ${colors.semantic.foreground} \ | ||
--replace @@COLORS_UNSELECTED_BG@@ ${colors.window.unselected.background} \ | ||
--replace @@COLORS_UNSELECTED_FG@@ ${colors.window.unselected.text} \ | ||
--replace @@COLORS_SELECTED_BG@@ ${colors.window.selected.focused.background} \ | ||
--replace @@COLORS_SELECTED_FG@@ ${colors.window.selected.focused.text} | ||
chmod +x "$out/sketchybarrc" | ||
''; | ||
"skhd/skhdrc".text = import skhd/skhdrc.nix kitty jq; | ||
"yabai/yabairc".source = yabai/yabairc; | ||
"yabai/yabairc".executable = true; | ||
} |
17 changes: 17 additions & 0 deletions
17
home/modules/base/gui/darwin/xdg/configFile/sketchybar/bar.lua
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
local colors = require("colors") | ||
|
||
-- Equivalent to the --bar domain | ||
sbar.bar({ | ||
blur_radius=20, | ||
border_color = colors.unifying, | ||
border_width = 4, | ||
color = colors.primary.background, | ||
corner_radius = 9, | ||
height = 36, | ||
margin = 4, | ||
padding_left = 10, | ||
padding_right = 10, | ||
shadow = false, sticky = true, | ||
topmost="window", | ||
y_offset = 4, | ||
}) |
19 changes: 19 additions & 0 deletions
19
home/modules/base/gui/darwin/xdg/configFile/sketchybar/colors.lua
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
return { | ||
unifying = @@COLORS_UNIFYING@@, | ||
primary = { | ||
background = @@COLORS_PRIMARY_BG@@, | ||
foreground = @@COLORS_PRIMARY_FG@@, | ||
}, | ||
secondary = { | ||
background = @@COLORS_SECONDARY_BG@@, | ||
foreground = @@COLORS_SECONDARY_FG@@, | ||
}, | ||
selected = { | ||
background = @@COLORS_SELECTED_BG@@, | ||
foreground = @@COLORS_SELECTED_FG@@, | ||
}, | ||
unselected = { | ||
background = @@COLORS_UNSELECTED_BG@@, | ||
foreground = @@COLORS_UNSELECTED_FG@@, | ||
}, | ||
} |
44 changes: 44 additions & 0 deletions
44
home/modules/base/gui/darwin/xdg/configFile/sketchybar/default.lua
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
local settings = require("settings") | ||
local colors = require("colors") | ||
|
||
-- Equivalent to the --default domain | ||
sbar.default({ | ||
updates = "when_shown", | ||
icon = { | ||
font = { | ||
family = settings.font.family, | ||
style = "Bold", | ||
size = settings.font.size | ||
}, | ||
color = colors.primary.foreground, | ||
padding_left = settings.paddings, | ||
padding_right = settings.paddings, | ||
}, | ||
label = { | ||
font = { | ||
family = settings.font.family, | ||
style = "Semibold", | ||
size = settings.font.size | ||
}, | ||
color = colors.primary.foreground, | ||
padding_left = settings.paddings, | ||
padding_right = settings.paddings, | ||
}, | ||
background = { | ||
height = 26, | ||
border_width = 4, | ||
}, | ||
popup = { | ||
background = { | ||
border_width = 2, | ||
corner_radius = 9, | ||
border_color = colors.unifying, | ||
color = colors.secondary.background, | ||
shadow = { drawing = true }, | ||
}, | ||
blur_radius = 20, | ||
}, | ||
padding_left = 5, | ||
padding_right = 5 | ||
}) | ||
|
14 changes: 14 additions & 0 deletions
14
home/modules/base/gui/darwin/xdg/configFile/sketchybar/emojis.lua
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
return { | ||
[".kitty-wrapped"] = ":terminal:", | ||
["Alacritty"] = ":terminal:", | ||
["Discord"] = ":discord:", | ||
["Emacs"] = ":emacs:", | ||
["Firefox"] = ":firefox:", | ||
["Google Chrome Beta"] = ":google_chrome:", | ||
["Google Chrome"] = ":google_chrome:", | ||
["Microsoft Edge"] = ":microsoft_edge:", | ||
["Terminal"] = ":terminal:", | ||
["iTerm2"] = ":terminal:", | ||
["kitty"] = ":terminal:", | ||
["zoom.us"] = ":zoom:", | ||
} |
21 changes: 21 additions & 0 deletions
21
home/modules/base/gui/darwin/xdg/configFile/sketchybar/icons.lua
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
return { | ||
loading = "", | ||
apple = "", | ||
preferences = "", | ||
|
||
volume = { | ||
_100="", | ||
_66="", | ||
_33="", | ||
_10="", | ||
_0="", | ||
}, | ||
battery = { | ||
_100 = "", | ||
_75 = "", | ||
_50 = "", | ||
_25 = "", | ||
_0 = "", | ||
charging = "" | ||
}, | ||
} |
3 changes: 3 additions & 0 deletions
3
home/modules/base/gui/darwin/xdg/configFile/sketchybar/init.lua
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
require("bar") | ||
require("default") | ||
require("items") |
Oops, something went wrong.