瀏覽代碼

Clean up return value file

Alois Mahdal 11 年之前
父節點
當前提交
b2850b307b
共有 1 個檔案被更改,包括 3 行新增1 行删除
  1. 3
    1
      dotfiles/bash/post.bashrc

+ 3
- 1
dotfiles/bash/post.bashrc 查看文件

9
 ### '''' ###
9
 ### '''' ###
10
 
10
 
11
 __make_ps1d() {
11
 __make_ps1d() {
12
-    lastrv=$(cat /var/tmp/bash-rv/$$.lastrv)
12
+    rvfile="/var/tmp/bash-rv/$$.lastrv"
13
+    lastrv=$(cat $rvfile)
13
     if [ $lastrv -gt 0 ];
14
     if [ $lastrv -gt 0 ];
14
     then
15
     then
15
         echo "$lastrv"
16
         echo "$lastrv"
16
     else
17
     else
17
         echo ""
18
         echo ""
18
     fi
19
     fi
20
+    rm $rvfile
19
 }
21
 }
20
 
22
 
21
 __save_rv() {
23
 __save_rv() {