summaryrefslogtreecommitdiff
path: root/awesome/helper.sh
diff options
context:
space:
mode:
authorzachir <zachir@librem.one>2023-02-10 12:47:42 -0600
committerzachir <zachir@librem.one>2023-02-10 12:47:42 -0600
commit069c4ff5fe6ed8150de9aebe1d484d74ad049b58 (patch)
treee18dde62b2a6b39618f31fbf38e3eb916f396a36 /awesome/helper.sh
parenteab2bc558cf79124f2c71b8424aa97834a29c677 (diff)
add awesome as part of dotfiles, not separate repo
Diffstat (limited to 'awesome/helper.sh')
-rwxr-xr-xawesome/helper.sh13
1 files changed, 13 insertions, 0 deletions
diff --git a/awesome/helper.sh b/awesome/helper.sh
new file mode 100755
index 0000000..d51fbab
--- /dev/null
+++ b/awesome/helper.sh
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+ppid() {
+ printf "$(ps -o ppid= -p $1)" | xargs
+}
+
+gppid() {
+ PARENT=$(ps -o ppid= -p $1)
+ GRANDPARENT=$(ps -o ppid= -p $PARENT)
+ printf "$GRANDPARENT" | xargs
+}
+
+$@