We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9215889 commit 45ef1b7Copy full SHA for 45ef1b7
custom_components/file_plusplus/const.py
@@ -4,5 +4,5 @@
4
5
CONF_TIMESTAMP = "timestamp"
6
7
-DEFAULT_NAME = "File++"
+DEFAULT_NAME = "file_plusplus"
8
FILE_ICON = "mdi:file"
custom_components/file_plusplus/sensor.py
@@ -62,7 +62,7 @@ async def async_setup_entry(
62
options = dict(entry.options)
63
file_path: str = config[CONF_FILE_PATH]
64
unique_id: str = entry.entry_id
65
- name: str = config.get(CONF_NAME, DEFAULT_NAME)
+ name: str = config.get(CONF_NAME, DEFAULT_NAME) + "_" + file_path.split("/")[-1].replace(".", "_")
66
unit: str | None = options.get(CONF_UNIT_OF_MEASUREMENT)
67
value_template: Template | None = None
68
0 commit comments