ソースを参照

Merge pull request #2 from lbonanomi/who

test if the current user is sudo-su'd into this session
pull/39/head
lbonanomi 5年前
committed by GitHub
コミット
2e28c6c0da
この署名に対応する既知のキーがデータベースに存在しません GPGキーID: 4AEE18F83AFDEB23
1個のファイルの変更6行の追加0行の削除
  1. +6
    -0
      README.md

+ 6
- 0
README.md ファイルの表示

@@ -1227,6 +1227,12 @@ ___
who -b
```

###### Detect a user sudo-su'd into the current shell

```
[[ $(who -m | awk '{ print $1 }') == $(whoami) ]] || echo "You are su-ed to $(whoami)"
```

___

##### Tool: [screen](https://en.wikipedia.org/wiki/GNU_Screen)


読み込み中…
キャンセル
保存