commit ad91baf60341a91a68fbc937a0584657f5cd8f8f
parent 8701ee1132b0214ede89e2af031fa11bf81b6157
Author: Ed van Bruggen <edvb54@gmail.com>
Date: Mon, 4 Apr 2016 10:08:53 -0700
Rename files
Diffstat:
8 files changed, 30 insertions(+), 30 deletions(-)
diff --git a/calc.sh b/calc.sh
@@ -0,0 +1,12 @@
+#!/usr/bin/env bash
+# Calculator using dmenu as an interface
+
+# run dmenu calculator while the result is not empty
+while : ; do
+ # use contents of clipboard as option, pass into bc to be calculated
+ result=$(xsel -o -b | dmenu -p Calc | xargs echo | bc 2>&1)
+ if [[ $result ]]; then # if result is empty (the last one), don't copy it to clipboard
+ printf "$result" | xsel -b
+ fi
+ [[ $result ]] || break # if result is empty, break from while loop
+done
diff --git a/dmenu-calc.sh b/dmenu-calc.sh
@@ -1,12 +0,0 @@
-#!/usr/bin/env bash
-# Calculator using dmenu as an interface
-
-# run dmenu calculator while the result is not empty
-while : ; do
- # use contents of clipboard as option, pass into bc to be calculated
- result=$(xsel -o -b | dmenu -p Calc | xargs echo | bc 2>&1)
- if [[ $result ]]; then # if result is empty (the last one), don't copy it to clipboard
- printf "$result" | xsel -b
- fi
- [[ $result ]] || break # if result is empty, break from while loop
-done
diff --git a/dmenu-prog++.sh b/dmenu-prog++.sh
@@ -1,11 +0,0 @@
-#!/bin/bash
-
-padding=100
-
-screenw=$(xrandr | fgrep '*' | sed s/x/\ / | awk '{print $1}' | tail -1)
-screenh=$(xrandr | fgrep '*' | sed s/x/\ / | awk '{print $2}' | tail -1)
-
-let "bar_width = screenw - (padding * 2)"
-let "height = screenh/2 - (padding * 2)"
-
-dmenu_run -x $padding -y $height -w $bar_width -p ">>>" -l 10
diff --git a/dmenu-prog.sh b/dmenu-prog.sh
@@ -1,2 +0,0 @@
-#!/usr/bin/env bash
-dmenu_path | dmenu | ${SHELL:-"/bin/sh"}
diff --git a/dmenu-win.sh b/dmenu-win.sh
@@ -1,5 +0,0 @@
-#!/usr/bin/env bash
-# Use dmenu to focus on an open window
-
-win="$(wmctrl -l | dmenu -l 10 "$@" | cut -d ' ' -f 1)"
-[ "$win" ] && wmctrl -ia "$win" &
diff --git a/prog++.sh b/prog++.sh
@@ -0,0 +1,11 @@
+#!/bin/bash
+
+padding=100
+
+screenw=$(xrandr | fgrep '*' | sed s/x/\ / | awk '{print $1}' | tail -1)
+screenh=$(xrandr | fgrep '*' | sed s/x/\ / | awk '{print $2}' | tail -1)
+
+let "bar_width = screenw - (padding * 2)"
+let "height = screenh/2 - (padding * 2)"
+
+dmenu_run -x $padding -y $height -w $bar_width -p ">>>" -l 10
diff --git a/prog.sh b/prog.sh
@@ -0,0 +1,2 @@
+#!/usr/bin/env bash
+dmenu_path | dmenu | ${SHELL:-"/bin/sh"}
diff --git a/win.sh b/win.sh
@@ -0,0 +1,5 @@
+#!/usr/bin/env bash
+# Use dmenu to focus on an open window
+
+win="$(wmctrl -l | dmenu -l 10 "$@" | cut -d ' ' -f 1)"
+[ "$win" ] && wmctrl -ia "$win" &