update info-xampp, fix #19
This commit is contained in:
parent
843a7fab56
commit
1bc3e6807f
@ -38,6 +38,7 @@ Is this your first time here? You should definitely take a look at these scripts
|
||||
[](polybar-scripts/system-usb-udev/)
|
||||
[](polybar-scripts/openweathermap-simple/)
|
||||
[](polybar-scripts/openweathermap-detailed/)
|
||||
[](polybar-scripts/info-xampp/)
|
||||
[](polybar-scripts/player-mpris-tail/)
|
||||
[](polybar-scripts/info-redshift-temp/)
|
||||
[](polybar-scripts/hint-trash/)
|
||||
|
@ -1,25 +0,0 @@
|
||||
# Script: XAMPP status 
|
||||
|
||||
The Script prints the status of XAMPP services (Apache, MySQL, ProFTPD) if they are running. Otherwise, the script prints nothing.
|
||||
|
||||

|
||||
|
||||
|
||||
## Dependencies
|
||||
[XAMPP](https://www.apachefriends.org/de/index.html)
|
||||
|
||||
## Module
|
||||
|
||||
```
|
||||
[module/xampp]
|
||||
type = custom/script
|
||||
interval = 10
|
||||
label = %output%
|
||||
exec = ~/./.skript/xampp-status.sh
|
||||
```
|
||||
|
||||
## Troubleshooting
|
||||
To show the MySQL Server status, the script must own a file in /opt/lampp/var/MySQL. <br>
|
||||
To solve this I edited the xampp script in /opt/lampp/ in the startMySQL() function,  <br>
|
||||
The sleep is imported because the file need some time to create.
|
||||
The file is owned by the mysql user. May you can fix that problem on Otherwise. This is only one solution.
|
Binary file not shown.
Before Width: | Height: | Size: 1.7 KiB |
Binary file not shown.
Before Width: | Height: | Size: 8.7 KiB |
Binary file not shown.
Before Width: | Height: | Size: 1.0 KiB |
@ -1,18 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
a=$(/./opt/lampp/xampp status | grep Apa | cut -d " " -f3)
|
||||
m=$(/./opt/lampp/xampp status | grep My | cut -d " " -f3)
|
||||
f=$(/./opt/lampp/xampp status | grep Pro | cut -d " " -f3)
|
||||
ret="";
|
||||
|
||||
|
||||
if [ "$a" != "not" ]; then
|
||||
ret="A: %{F#0fe108}X%{F-}"
|
||||
fi
|
||||
if [ "$m" != "not" ]; then
|
||||
ret="$ret M: %{F#0fe108}X%{F-}"
|
||||
fi
|
||||
if [ "$f" != "deactivated." ]; then
|
||||
ret="$ret F: %{F#0fe108}X%{F-}"
|
||||
fi
|
||||
echo "$ret"
|
@ -5,6 +5,15 @@ The Script prints the status of [XAMPP](https://www.apachefriends.org/de/index.h
|
||||

|
||||
|
||||
|
||||
## Dependencies
|
||||
|
||||
Create a sudo rule to allow you user to read the status information.
|
||||
|
||||
```ini
|
||||
username ALL = NOPASSWD: /opt/lampp/xampp
|
||||
```
|
||||
|
||||
|
||||
## Module
|
||||
|
||||
```ini
|
||||
@ -13,11 +22,3 @@ type = custom/script
|
||||
exec = ~/polybar-scripts/info-xampp.sh
|
||||
interval = 10
|
||||
```
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
To show the MySQL Server status, the script must own a file in /opt/lampp/var/MySQL. To solve this I edited the xampp script in /opt/lampp/ in the startMySQL() function.
|
||||
|
||||

|
||||
|
||||
The sleep is imported because the file need some time to create. The file is owned by the mysql user. May you can fix that problem on Otherwise. This is only one solution.
|
||||
|
@ -1,18 +1,18 @@
|
||||
#!/bin/sh
|
||||
|
||||
if /./opt/lampp/xampp status | grep -q "Apache is running."; then
|
||||
if sudo /opt/lampp/xampp status | grep -q "Apache is running."; then
|
||||
status_apache="#11"
|
||||
else
|
||||
status_apache="#12"
|
||||
fi
|
||||
|
||||
if /./opt/lampp/xampp status |grep -q "MySQL is running."; then
|
||||
if sudo /opt/lampp/xampp status |grep -q "MySQL is running."; then
|
||||
status_mysql="#21"
|
||||
else
|
||||
status_mysql="#22"
|
||||
fi
|
||||
|
||||
if /./opt/lampp/xampp status | grep -q "ProFTPD is running."; then
|
||||
if sudo /opt/lampp/xampp status | grep -q "ProFTPD is running."; then
|
||||
status_ftp="#31"
|
||||
else
|
||||
status_ftp="#32"
|
||||
|
Loading…
x
Reference in New Issue
Block a user