Add editorconfig-checker workflow and fix styling errors

Signed-off-by: Christian König <ckoenig@posteo.de>
This commit is contained in:
Christian König
2022-06-29 13:18:44 +02:00
parent 13958e6804
commit b332f0c584
3 changed files with 25 additions and 5 deletions

View File

@@ -5,11 +5,17 @@ root = true
[*]
insert_final_newline = true
indent_style = tab
indent_size = 4
indent_style = space
indent_size = tab
tab_width = 4
charset = utf-8
trim_trailing_whitespace = true
[*.yml]
indent_style = space
indent_size = 2
[*.md]
indent_style = space
indent_size = 2

View File

@@ -0,0 +1,14 @@
name: editorconfig-checker
on:
pull_request:
push:
jobs:
build:
name: editorconfig-checker
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- uses: editorconfig-checker/action-editorconfig-checker@main
- run: editorconfig-checker

View File

@@ -523,7 +523,7 @@ GetVersionInformation() {
if [ "$INSTALL_WEB_INTERFACE" = true ]; then
web_version=$(pihole -v -a | awk '{print $4}' | tr -d '[:alpha:]')
web_version_latest=$(pihole -v -a | awk '{print $(NF)}' | tr -d ')')
# if web_version is something else then x.xx set it to N/A
if ! echo "${web_version}" | grep -qE '^[0-9]+([.][0-9]+)?$' || [ "${web_version_latest}" = "ERROR" ]; then
web_version="N/A"
@@ -550,7 +550,7 @@ GetVersionInformation() {
# Gather FTL version information...
ftl_version=$(pihole -v -f | awk '{print $4}' | tr -d '[:alpha:]')
ftl_version_latest=$(pihole -v -f | awk '{print $(NF)}' | tr -d ')')
# if ftl_version is something else then x.xx set it to N/A
if ! echo "${ftl_version}" | grep -qE '^[0-9]+([.][0-9]+)?$' || [ "${ftl_version_latest}" = "ERROR" ]; then
ftl_version="N/A"
@@ -892,7 +892,7 @@ PrintSystemInformation() {
CleanEcho "${bold_text}SYSTEM ========================================================================${reset_text}"
# Device
CleanPrintf " %-10s%-39s\e[0K\\n" "Device:" "${sys_model}"
# Uptime and memory
CleanPrintf " %-10s%-39s %-10s[${memory_heatmap}%-10s${reset_text}] %-6s\\n" "Uptime:" "${system_uptime}" "Memory:" "${memory_bar}" "${memory_percent}%"