From 50cba307519e7a627d9fff3b0664b9beea59e0a2 Mon Sep 17 00:00:00 2001 From: Ian Keane Date: Sat, 25 Jun 2022 08:38:11 -0400 Subject: [PATCH] Add missing custom bin scripts --- dotfiles/bin/.local/bin/dmenuunicode | 18 ++++++++++++++++++ dotfiles/bin/.local/bin/lemonlaunch | 9 +++++++++ dotfiles/bin/.local/bin/themepick | 6 ++++++ 3 files changed, 33 insertions(+) create mode 100755 dotfiles/bin/.local/bin/dmenuunicode create mode 100755 dotfiles/bin/.local/bin/lemonlaunch create mode 100755 dotfiles/bin/.local/bin/themepick diff --git a/dotfiles/bin/.local/bin/dmenuunicode b/dotfiles/bin/.local/bin/dmenuunicode new file mode 100755 index 0000000..b25876f --- /dev/null +++ b/dotfiles/bin/.local/bin/dmenuunicode @@ -0,0 +1,18 @@ +#!/bin/sh + +# The famous "get a menu of emojis to copy" script. + +# Get user selection via dmenu from emoji file. +chosen=$(cut -d ';' -f1 ~/.local/share/emoji | dmenu -i -l 30 | sed "s/ .*//") + +# Exit if none chosen. +[ -z "$chosen" ] && exit + +# If you run this command with an argument, it will automatically insert the +# character. Otherwise, show a message that the emoji has been copied. +if [ -n "$1" ]; then + xdotool type "$chosen" +else + printf "$chosen" | xclip -selection clipboard + notify-send "'$chosen' copied to clipboard." & +fi diff --git a/dotfiles/bin/.local/bin/lemonlaunch b/dotfiles/bin/.local/bin/lemonlaunch new file mode 100755 index 0000000..c2ad889 --- /dev/null +++ b/dotfiles/bin/.local/bin/lemonlaunch @@ -0,0 +1,9 @@ +#!/usr/bin/fish +if ps -a | grep lemonbar + pkill lemonbar +end + +sleep .1 && +~/.config/lemonbar/lemonbar.fish | lemonbar -pb -f "BitstreamVeraSansMono:size=12" -B "#343D46" -F "#CDD3DE" & +sleep .1 && +xdo above -t (xdo id -n root) (xdo id -n lemonbar) diff --git a/dotfiles/bin/.local/bin/themepick b/dotfiles/bin/.local/bin/themepick new file mode 100755 index 0000000..35faebc --- /dev/null +++ b/dotfiles/bin/.local/bin/themepick @@ -0,0 +1,6 @@ +#!/usr/bin/fish + +set theme (flavours list | tr ' ' '\n' | dmenu) + +flavours apply $theme && +eval ~/.config/base16-shell/scripts/base16-$theme.sh