Bläddra i källkod

Merge pull request #39 from lbonanomi/master

Test if the current user is sudo-su'd into this session
pull/41/head
@trimstray 5 år sedan
committed by GitHub
förälder
incheckning
aa2adcbee2
Ingen känd nyckel hittad för denna signaturen i databasen GPG-nyckel ID: 4AEE18F83AFDEB23
1 ändrade filer med 6 tillägg och 0 borttagningar
  1. +6
    -0
      README.md

+ 6
- 0
README.md Visa fil

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

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

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

___

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


Laddar…
Avbryt
Spara