diff options
| author | Hsieh Chin Fan <pham@topo.tw> | 2023-04-07 12:46:42 +0800 |
|---|---|---|
| committer | Hsieh Chin Fan <pham@topo.tw> | 2023-04-07 12:46:42 +0800 |
| commit | 52af58e39af8ac006c62d1788b6672966b2a9f47 (patch) | |
| tree | a07e147eb4d3c2af1e3da5e5fc32ca1f04e9e5b0 /X11/rofi | |
| parent | 204f6a6a7024a2744fe948b1014494ebc2fd3a56 (diff) | |
Update
Diffstat (limited to 'X11/rofi')
| -rwxr-xr-x | X11/rofi/pass.get | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/X11/rofi/pass.get b/X11/rofi/pass.get index 18230fe..425cd62 100755 --- a/X11/rofi/pass.get +++ b/X11/rofi/pass.get | |||
| @@ -40,8 +40,8 @@ set -x | |||
| 40 | if [ -n "$RESULT" ]; then | 40 | if [ -n "$RESULT" ]; then |
| 41 | # Copy the given password into PRIMARY selection and kill it in 30s | 41 | # Copy the given password into PRIMARY selection and kill it in 30s |
| 42 | echo "$RESULT" | sed -n 1p | tr -d '\n' | xsel -i -t 30000 | 42 | echo "$RESULT" | sed -n 1p | tr -d '\n' | xsel -i -t 30000 |
| 43 | # Copy the second line (most of the time, account name) into CLIPBOARD selection | 43 | # Copy the second non-empty line (most of the time, account name) into CLIPBOARD selection |
| 44 | echo "$RESULT" | sed -n 2p | tr -d '\n' | xsel -ib | 44 | echo "$RESULT" | sed -n '1d;/^./{p;q}' | tr -d '\n' | xsel -ib |
| 45 | 45 | ||
| 46 | # And show extra message | 46 | # And show extra message |
| 47 | EXTRA="$(echo; echo; echo "$RESULT" | sed '1d' | sed '1{/^$/d}')" | 47 | EXTRA="$(echo; echo; echo "$RESULT" | sed '1d' | sed '1{/^$/d}')" |