File: test_script_mode_color.sh

package info (click to toggle)
rofi 2.0.0-0.2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 3,472 kB
  • sloc: ansic: 36,245; lex: 957; yacc: 920; xml: 858; sh: 384; makefile: 17
file content (35 lines) | stat: -rwxr-xr-x 738 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#!/usr/bin/env bash

if [ "$*" = "quit" ]
then
    exit 0
fi

if [ "$@" ]
then
    # Override the previously set prompt.
    echo -en "\0theme\x1felement-text { background-color: $@;}\n"
    echo -en "\0keep-selection\x1ftrue\n"
#    echo -en "\0new-selection\x1f2\n"
    echo "red"
    echo "lightgreen"
    echo "lightblue"
    echo "lightyellow"
    echo "quit"
else
    echo -en "\x00prompt\x1ftesting\n"
    echo -en "\0urgent\x1f0,2\n"
    echo -en "\0active\x1f1\n"
    echo -en "\0keep-selection\x1ftrue\n"
    echo -en "\0message\x1fSpecial <b>bold</b>message\n"

    echo "red"
    echo "lightgreen"
    echo "lightblue"
    echo "lightyellow"
    echo "pink"
    echo "green"
    echo "blue"
    echo "gold"
    echo "quit"
fi