config-editor-card/README.md

69 lines
1.5 KiB
Markdown
Raw Normal View History

2021-12-01 03:00:20 +01:00
Config Editor Card to edit configuration.yaml from dashboard
2021-12-01 15:31:08 +01:00
Automaticly searches for `*.yaml` in the root and subfolders and lists in the dropdown menu.
2021-12-01 03:14:45 +01:00
![screenshot](https://github.com/htmltiger/config-editor-card/raw/main/screenshot.png)
2021-12-01 15:31:08 +01:00
Please backup your files before using as there is no undo.
2021-12-01 03:00:20 +01:00
## Installation
2021-12-01 15:31:08 +01:00
### Step 1
You will also need to install a custom component https://github.com/htmltiger/config-editor
2021-12-01 15:46:17 +01:00
* **Manual**
2021-12-01 15:31:08 +01:00
2021-12-01 15:46:17 +01:00
Download and copy `config_editor` directory in `custom_components`
2021-12-01 15:31:08 +01:00
2021-12-01 15:46:17 +01:00
* **[HACS](https://hacs.xyz/)**
Integration > `Config Editor`
Restart home assistant.
Edit configuration.yaml and add the following so it can load
2021-12-01 15:31:08 +01:00
```
config_editor:
```
2021-12-01 15:46:17 +01:00
Restart home assistant.
2021-12-01 15:31:08 +01:00
### Step 2
2021-12-01 15:46:17 +01:00
* **Manual**
add config-editor-card.js to your `<config>/www/` folder
add url `/local/config-editor-card.js?v=1` from Configuration -> Lovelace Dashboards -> Resources panel when not using YAML mode
for YAML mode add the following to the `configuration.yaml` file:
```yaml
lovelace:
resources:
- url: /local/config-editor-card.js?v=1
type: module
```
* **[HACS](https://hacs.xyz/)**
Frontend > `Config Editor Card`
add this (if in YAML mode):
```yaml
lovelace:
resources:
- url: /hacsfiles/config-editor-card/config-editor-card.js
type: module
```
2021-12-01 03:00:20 +01:00
2021-12-01 15:31:08 +01:00
For the dashboard, create a new tab in panel mode and add a card
2021-12-01 15:46:17 +01:00
```yaml
2021-12-01 03:06:23 +01:00
type: custom:config-editor-card
```
2021-12-01 03:00:20 +01:00
It is also possible to add this using `+ Add Card` UI and choose `Custom: Config Editor Card`