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

Added new twindow #112

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@ tsearch: ${CONFIG_FOLDER} ${BIN_FOLDER} tyaml
install tsearch/params.yaml ${CONFIG_FOLDER}
@echo "done!"

twindow: ${BIN_FOLDER} tyaml
@echo "Installing twindow..."
install -m 555 twindow/dmenu_twindow ${BIN_FOLDER}
@echo "done!"

tpomodoro: ${CONFIG_FOLDER} ${BIN_FOLDER}
@echo "Installing tpomodoro..."
install -m 555 tpomodoro/tpomodoro ${BIN_FOLDER}
Expand Down Expand Up @@ -78,9 +83,10 @@ uninstall:
rm -f ${BIN_FOLDER}/tgoeswall
rm -fr ${CONFIG_FOLDER}
rm -f ${BIN_FOLDER}/tprogbar
rm -f ${BIN_FOLDER}/dmenu_twindow
@echo "done!"

install: tsearch ttodo tmenu tyaml tnotes tgoeswall tpomodoro tprogbar
install: tsearch ttodo tmenu tyaml tnotes tgoeswall tpomodoro tprogbar twindow
@echo "tinytools installed successfully!"

.PHONY: install tsearch tpomodoro ttodo tmenu tyaml tnotes tgoeswall uninstall tprogbar
12 changes: 12 additions & 0 deletions twindow/dmenu_twindow
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#!/bin/bash

twindow="wmctrl -l"

window=$(echo "$($twindow)" | awk '{$1="";$2="";$3=""; print $0}' | dmenu -i -p Windows:)
echo "$window"

[[ -n $window ]] || exit

prompt="$window"

wmctrl -a $window