Support panel icon + more options (#573)

* Support panel icon + more options

* Update config.json
This commit is contained in:
Pascal Vizeli
2019-04-25 08:17:58 +02:00
committed by GitHub
parent a6a976ad06
commit 6e5d7282d6
4 changed files with 29 additions and 4 deletions

View File

@@ -1,42 +1,58 @@
# Changelog # Changelog
## 3.2
- Add `mdi:wrench` as panel icon
- Add options `ignore_pattern`
## 3.1 ## 3.1
- Add options `dirsfirst` and `enforce_basepath` - Add options `dirsfirst` and `enforce_basepath`
## 3.0 ## 3.0
- Update Python to version 3.7 - Update Python to version 3.7
- Update Configurator to version 0.3.5 - Update Configurator to version 0.3.5
- Migrate Add-on to new Ingress - Migrate Add-on to new Ingress
- Pin Home Assistant requirements to 0.91.1 - Pin Home Assistant requirements to 0.91.1
## 2.1 ## 2.1
- Update python version - Update python version
## 2.0 ## 2.0
- Add access to folder: `/share`, `/backup` - Add access to folder: `/share`, `/backup`
## 1.2 ## 1.2
- Update Configurator to version 0.3.2 - Update Configurator to version 0.3.2
## 1.1 ## 1.1
- Fixed ssl certificate path bug - Fixed ssl certificate path bug
## 1.0 ## 1.0
- Update Configurator to version 0.3.1 - Update Configurator to version 0.3.1
## 0.4 ## 0.4
- Update Configurator to version 0.2.9 - Update Configurator to version 0.2.9
## 0.3 ## 0.3
- Update Configurator to version 0.2.8 - Update Configurator to version 0.2.8
## 0.2.7 ## 0.2.7
- Setting SO_REUSEADDR on socket for proper restarts - Setting SO_REUSEADDR on socket for proper restarts
- Using Threading to handle multiple connections - Using Threading to handle multiple connections
- New VERIFY_HOSTNAME option to block requests without correct host header - New VERIFY_HOSTNAME option to block requests without correct host header
- Fixed filebrowser hiding - Fixed filebrowser hiding
## 0.2.6 ## 0.2.6
- Displaying current filename in title - Displaying current filename in title
- Added menu item to open configurator in new tab - Added menu item to open configurator in new tab
- Automatically load last viewed (and not closed) file via localStorage - Automatically load last viewed (and not closed) file via localStorage
@@ -44,6 +60,7 @@
- Prompting before saving now opt-in in editor settings - Prompting before saving now opt-in in editor settings
## 0.2.5 ## 0.2.5
- Added warning-logs for access failure - Added warning-logs for access failure
- Added transparency to whitespace characters - Added transparency to whitespace characters
- Using external repository for Docker - Using external repository for Docker
@@ -52,5 +69,6 @@
- Added "Sesame" feature - Added "Sesame" feature
## 0.2.4 ## 0.2.4
- YAML lint support - YAML lint support
- Support new Hass.io token system - Support new Hass.io token system

View File

@@ -1,6 +1,6 @@
{ {
"name": "Configurator", "name": "Configurator",
"version": "3.1", "version": "3.2",
"slug": "configurator", "slug": "configurator",
"description": "Browser-based configuration file editor for Home Assistant.", "description": "Browser-based configuration file editor for Home Assistant.",
"url": "https://home-assistant.io/addons/configurator", "url": "https://home-assistant.io/addons/configurator",
@@ -9,6 +9,7 @@
"startup": "application", "startup": "application",
"webui": "http://[HOST]:[PORT:8080]", "webui": "http://[HOST]:[PORT:8080]",
"ingress": true, "ingress": true,
"panel_icon": "mdi:wrench",
"auth_api": true, "auth_api": true,
"homeassistant_api": true, "homeassistant_api": true,
"boot": "auto", "boot": "auto",
@@ -23,11 +24,15 @@
}, },
"options": { "options": {
"dirsfirst": false, "dirsfirst": false,
"enforce_basepath": false "enforce_basepath": false,
"ignore_pattern": [
"__pycache__"
]
}, },
"schema": { "schema": {
"dirsfirst": "bool", "dirsfirst": "bool",
"enforce_basepath": "bool" "enforce_basepath": "bool",
"ignore_pattern": ["str"]
}, },
"image": "homeassistant/{arch}-addon-configurator" "image": "homeassistant/{arch}-addon-configurator"
} }

View File

@@ -16,7 +16,7 @@
"ALLOWED_DOMAINS": [], "ALLOWED_DOMAINS": [],
"BANNED_IPS": [], "BANNED_IPS": [],
"BANLIMIT": 0, "BANLIMIT": 0,
"IGNORE_PATTERN": [], "IGNORE_PATTERN": %%IGNORE_PATTERN%%,
"DIRSFIRST": %%DIRSFIRST%%, "DIRSFIRST": %%DIRSFIRST%%,
"SESAME": null, "SESAME": null,
"SESAME_TOTP_SECRET": null, "SESAME_TOTP_SECRET": null,

View File

@@ -3,6 +3,7 @@ set -e
DIRSFIRST=$(bashio::config 'dirsfirst') DIRSFIRST=$(bashio::config 'dirsfirst')
ENFORCE_BASEPATH=$(bashio::config 'enforce_basepath') ENFORCE_BASEPATH=$(bashio::config 'enforce_basepath')
IGNORE_PATTERN="$(bashio::jq "/data/options.json" ".ignore_pattern")"
WAIT_PIDS=() WAIT_PIDS=()
# Setup and run Frontend # Setup and run Frontend
@@ -16,6 +17,7 @@ WAIT_PIDS+=($!)
sed -i "s/%%TOKEN%%/${HASSIO_TOKEN}/g" /etc/configurator.conf sed -i "s/%%TOKEN%%/${HASSIO_TOKEN}/g" /etc/configurator.conf
sed -i "s/%%DIRSFIRST%%/${DIRSFIRST}/g" /etc/configurator.conf sed -i "s/%%DIRSFIRST%%/${DIRSFIRST}/g" /etc/configurator.conf
sed -i "s/%%ENFORCE_BASEPATH%%/${ENFORCE_BASEPATH}/g" /etc/configurator.conf sed -i "s/%%ENFORCE_BASEPATH%%/${ENFORCE_BASEPATH}/g" /etc/configurator.conf
sed -i "s/%%IGNORE_PATTERN%%/${IGNORE_PATTERN}/g" /etc/configurator.conf
hass-configurator /etc/configurator.conf & hass-configurator /etc/configurator.conf &
WAIT_PIDS+=($!) WAIT_PIDS+=($!)