Change i3 config
This commit is contained in:
parent
1ae0c15145
commit
98e013d18a
3 changed files with 17 additions and 6 deletions
|
@ -40,7 +40,16 @@ BASE_COLOR=#5fff5f
|
||||||
UPDATE_COLOR=#ffff85
|
UPDATE_COLOR=#ffff85
|
||||||
LABEL=
|
LABEL=
|
||||||
|
|
||||||
|
[temperature]
|
||||||
|
label=<span foreground='#c7505c'> </span>
|
||||||
|
interval=10
|
||||||
|
|
||||||
|
[cpu_usage]
|
||||||
|
interval=10
|
||||||
|
LABEL=<span foreground='#f59335'> </span>
|
||||||
|
|
||||||
[ccurrency]
|
[ccurrency]
|
||||||
|
LABEL=test
|
||||||
command=scripts/ccurrency -f USD
|
command=scripts/ccurrency -f USD
|
||||||
interval=1800
|
interval=1800
|
||||||
|
|
||||||
|
@ -54,12 +63,13 @@ interval=1800
|
||||||
|
|
||||||
[protonvpn]
|
[protonvpn]
|
||||||
interval=5
|
interval=5
|
||||||
LABEL=
|
LABEL_ON=<span foreground='#17d427'> </span>
|
||||||
|
LABEL_OFF=<span foreground='#c90f1f'> </span>
|
||||||
|
|
||||||
[rofi-calendar]
|
[rofi-calendar]
|
||||||
interval=60
|
interval=60
|
||||||
LABEL=
|
LABEL=
|
||||||
DATEFTM=+ %a. %d %b. - %H:%M
|
DATEFTM=+ %a %d %b - %H:%M
|
||||||
SHORTFTM=+ %d.%m.%Y
|
SHORTFTM=+ %d.%m.%Y
|
||||||
|
|
||||||
[]
|
[]
|
||||||
|
|
|
@ -7,7 +7,7 @@ from protonvpn_cli import utils as pvpn_utils
|
||||||
IP_ADDR = pvpn_utils.get_ip_info()[0]
|
IP_ADDR = pvpn_utils.get_ip_info()[0]
|
||||||
|
|
||||||
if not pvpn_utils.is_connected():
|
if not pvpn_utils.is_connected():
|
||||||
OUTPUT = "<span foreground='#ef1225'>{}</span>".format(os.environ['LABEL'])
|
OUTPUT = os.environ['LABEL_OFF']
|
||||||
OUTPUT += " {}".format(IP_ADDR)
|
OUTPUT += " {}".format(IP_ADDR)
|
||||||
|
|
||||||
else:
|
else:
|
||||||
|
@ -16,7 +16,7 @@ else:
|
||||||
COUNTRY_CODE = pvpn_utils.get_server_value(CONNECTED_SERVER, "ExitCountry", SERVERS)
|
COUNTRY_CODE = pvpn_utils.get_server_value(CONNECTED_SERVER, "ExitCountry", SERVERS)
|
||||||
COUNTRY = pvpn_utils.get_country_name(COUNTRY_CODE)
|
COUNTRY = pvpn_utils.get_country_name(COUNTRY_CODE)
|
||||||
CITY = pvpn_utils.get_server_value(CONNECTED_SERVER, "City", SERVERS)
|
CITY = pvpn_utils.get_server_value(CONNECTED_SERVER, "City", SERVERS)
|
||||||
OUTPUT = "<span foreground='#12ef25'>{}</span>".format(os.environ['LABEL'])
|
OUTPUT = os.environ['LABEL_ON']
|
||||||
OUTPUT += " {} - {}, {}".format(IP_ADDR, CITY, COUNTRY)
|
OUTPUT += " {} - {}, {}".format(IP_ADDR, CITY, COUNTRY)
|
||||||
|
|
||||||
print(OUTPUT)
|
print(OUTPUT)
|
||||||
|
|
|
@ -133,9 +133,10 @@ class Installer:
|
||||||
ui.info_2("Installing packages...")
|
ui.info_2("Installing packages...")
|
||||||
for package in packages:
|
for package in packages:
|
||||||
if self.operating_system == "arch based":
|
if self.operating_system == "arch based":
|
||||||
command = "sudo pacman -S --needed {}".format(package)
|
command = "sudo pacman -S --needed --noconfirm {}"\
|
||||||
|
.format(package)
|
||||||
elif self.operating_system == "debian based":
|
elif self.operating_system == "debian based":
|
||||||
command = "sudo apt install {}".format(package)
|
command = "sudo apt install -y {}".format(package)
|
||||||
|
|
||||||
install = subprocess.run(command, check=False, shell=True,
|
install = subprocess.run(command, check=False, shell=True,
|
||||||
stdout=subprocess.DEVNULL,
|
stdout=subprocess.DEVNULL,
|
||||||
|
|
Loading…
Add table
Reference in a new issue