瀏覽代碼

Add pp(), like nn() but also pause

Alois Mahdal 5 年之前
父節點
當前提交
b698f29841
共有 1 個檔案被更改,包括 12 行新增0 行删除
  1. 12
    0
      dotfiles/bash/main.bashrc

+ 12
- 0
dotfiles/bash/main.bashrc 查看文件

@@ -32,6 +32,18 @@ nn() {
32 32
     notify-send -a 'nn()' "hey, $msg"
33 33
 }
34 34
 
35
+pp() {
36
+    #
37
+    # Ring the bell and send notification $1 and pause
38
+    #
39
+    local msg=${1:-this is done}
40
+    local junk
41
+    bb
42
+    echo -e "hey, \033[1;31m$msg\033[1;0m!"
43
+    notify-send -a 'pp()' "hey, $msg"
44
+    read -r junk -p "Press Enter to continue"
45
+}
46
+
35 47
 dt() {
36 48
     #
37 49
     # Open $1 new terminals