More server changes and generalization of the waybar

This commit is contained in:
Jimbo 2024-12-12 06:37:05 -05:00
parent 7540a2156a
commit ba65a9a177
36 changed files with 213 additions and 402 deletions

View file

@ -125,37 +125,23 @@
};
home.packages = with pkgs; [
(pkgs.writeScriptBin "rofiscripts" ''
# Scratchpad function
scratchpads() {
SCRATCHPADS=$(echo -e "Btop\nMusic\nSound\nEasyEffects" | rofi -dmenu -i -p "Scratchpads")
case $SCRATCHPADS in
Btop) foot -a btop -T Btop btop;;
Music) foot -a music -T Music ncmpcpp;;
Sound) foot -a sound -T Sound pulsemixer;;
esac
}
# Lock menu
power() {
POWER=$(echo -e "Shutdown\nReboot\nSleep\nLock\nKill" | rofi -dmenu -i -p "Power")
case $POWER in
Shutdown) poweroff;;
Reboot) reboot;;
Sleep) sleep-$XDG_CURRENT_DESKTOP &;;
Lock) swaylock &;;
Kill) pkill -9 $XDG_CURRENT_DESKTOP;;
esac
}
# Check for command-line arguments
if [ "$1" == "--scratchpads" ]; then
scratchpads
elif [ "$1" == "--power" ]; then
power
else
echo "Please --scratchpads or --power."
fi
(pkgs.writeScriptBin "rofiscratch" ''
SCRATCHPADS=$(echo -e "Btop\nMusic\nSound\nEasyEffects" | rofi -dmenu -i -p "Scratchpads")
case $SCRATCHPADS in
Btop) foot -a btop -T Btop btop;;
Music) foot -a music -T Music ncmpcpp;;
Sound) foot -a sound -T Sound pulsemixer;;
esac
'')
(pkgs.writeScriptBin "rofipower" ''
POWER=$(echo -e "Shutdown\nReboot\nSleep\nLock\nKill" | rofi -dmenu -i -p "Power")
case $POWER in
Shutdown) poweroff;;
Reboot) reboot;;
Sleep) sleep-$XDG_CURRENT_DESKTOP &;;
Lock) swaylock &;;
Kill) pkill -9 $XDG_CURRENT_DESKTOP;;
esac
'')
rofi-bluetooth
bemoji

View file

@ -1,5 +1,7 @@
{ pkgs, ... }:
{
home.packages = with pkgs; [ spotdl ];
programs.zsh.shellAliases.spotdl = "spotdl --m3u --format opus";
home = {
packages = with pkgs; [ spotdl ];
shellAliases.spotdl = "spotdl --m3u --format opus";
};
}

View file

@ -1,20 +1,19 @@
{ ... }:
{
programs = {
yt-dlp = {
enable = true;
settings = {
add-metadata = true;
embed-thumbnail = true;
convert-thumbnails = "jpg";
audio-format = "opus";
output = ''"%(artist)s - %(title)s.%(ext)s"'';
};
};
zsh.shellAliases = {
ytm3u = "yt-dlp -gS proto:m3u8";
opusdl = ''yt-dlp -f ba -x --audio-quality 0'';
spotdl = "spotdl --m3u --format opus";
programs.yt-dlp = {
enable = true;
settings = {
add-metadata = true;
embed-thumbnail = true;
convert-thumbnails = "jpg";
audio-format = "opus";
output = ''"%(artist)s - %(title)s.%(ext)s"'';
};
};
home.shellAliases = {
ytm3u = "yt-dlp -gS proto:m3u8";
opusdl = ''yt-dlp -f ba -x --audio-quality 0'';
spotdl = "spotdl --m3u --format opus";
};
}

View file

@ -2,7 +2,6 @@
{
imports = [
./launchers
./games
./emulators
];
}

View file

@ -1,4 +0,0 @@
{ pkgs, ... }:
{
home.packages = with pkgs; [ xash3d ];
}