diff --git a/config/automation/Timed_Triggers/wake_up.yaml b/config/automation/Timed_Triggers/wake_up.yaml index 1cf86142..6b46c49d 100755 --- a/config/automation/Timed_Triggers/wake_up.yaml +++ b/config/automation/Timed_Triggers/wake_up.yaml @@ -8,6 +8,7 @@ - platform: state entity_id: group.bed to: 'off' + for: "00:05:00" condition: - condition: state diff --git a/config/automation/good_night.yaml b/config/automation/good_night.yaml index e291881e..b4cac900 100755 --- a/config/automation/good_night.yaml +++ b/config/automation/good_night.yaml @@ -51,3 +51,33 @@ - service: homeassistant.turn_off entity_id: group.landscaping + +- alias: 'Bed Presence AMP Trigger' + id: 26846f7b-bc76-43d2-99be-af552d2300f + trigger: + - platform: state + entity_id: + - binary_sensor.sleepnumber_carlo_carlo_is_in_bed + - binary_sensor.sleepnumber_carlo_stacey_is_in_bed + to: 'on' + id: "in_bed" + - platform: state + entity_id: + - binary_sensor.sleepnumber_carlo_carlo_is_in_bed + - binary_sensor.sleepnumber_carlo_stacey_is_in_bed + to: 'off' + id: "out_of_bed" + + action: + choose: + - alias: "Some One in Bed" + conditions: " {{ trigger.id == 'in_bed'}} " + sequence: + - service: homeassistant.turn_off + target: + entity_id: switch.lr_amp + + default: + - service: homeassistant.turn_on + target: + entity_id: switch.lr_amp diff --git a/config/packages/epson_printer.yaml b/config/packages/epson_printer.yaml index 5c344c05..62958767 100755 --- a/config/packages/epson_printer.yaml +++ b/config/packages/epson_printer.yaml @@ -26,11 +26,6 @@ automation: weekday: - wed action: - - service: persistent_notification.create - data: - title: Low Ink - message: "{{ trigger.to_state.attributes.friendly_name }} is at {{ trigger.to_state.state }} " - notification_id: low-battery-alert - service: script.notify_engine data: value1: "{{ trigger.to_state.attributes.friendly_name }} is at {{ trigger.to_state.state }} " diff --git a/config/packages/holiday.yaml b/config/packages/holiday.yaml index 5fa73878..09ad512e 100755 --- a/config/packages/holiday.yaml +++ b/config/packages/holiday.yaml @@ -16,11 +16,11 @@ homeassistant: customize: sensor.holiday: - + icon: mdi:beach friendly_name: US Holiday sensor.flag: - + icon: mdi:flag friendly_name: Flag Day @@ -153,10 +153,6 @@ automation: - condition: template value_template: "{{ states.sensor.holiday.state | trim != '' }}" action: - - service: persistent_notification.create - data: - message: 'Today is {{ states.sensor.holiday.state }}.' - title: '{{ states.sensor.holiday.state }}' - delay: '0{{ (range(4, 8)|random|int) }}:{{ range(0,5) | random | int }}{{ range(0,9) | random | int }}:{{ range(0,5) | random | int }}{{ range(0,9) | random | int }}' - service: script.tweet_engine_image diff --git a/config/packages/processmonitor.yaml b/config/packages/processmonitor.yaml index 4e1f2bea..9efee847 100755 --- a/config/packages/processmonitor.yaml +++ b/config/packages/processmonitor.yaml @@ -50,9 +50,3 @@ automation: value1: 'Hard Drive Monitor:' value2: "Your harddrive is running out of Space! /dev/root:{{ states.sensor.disk_use_percent.state }}%!" who: 'carlo' - - - service: persistent_notification.create - data: - title: "Hard Drive Monitor:" - message: "Your harddrive is running out of Space! /dev/root:{{ states.sensor.disk_use_percent.state }}%!" - notification_id: "Critical Alert" diff --git a/config/www/community/search-card/search-card.js b/config/www/community/search-card/search-card.js index a556d276..7ee1c8f1 100644 --- a/config/www/community/search-card/search-card.js +++ b/config/www/community/search-card/search-card.js @@ -39,6 +39,9 @@ class SearchCard extends ct.LitElement { this.search_text = this.config.search_text || "Type to search..."; this.actions = BUILTIN_ACTIONS.concat(this.config.actions || []); + + this.included_domains = this.config.included_domains; + this.excluded_domains = this.config.excluded_domains || []; } getCardSize() { @@ -122,16 +125,22 @@ class SearchCard extends ct.LitElement { var searchRegex = new RegExp(searchText, 'i'); for (var entity_id in this.hass.states) { if ( - (entity_id.search(searchRegex) >= 0) || ( - "friendly_name" in this.hass.states[entity_id].attributes && - this.hass.states[entity_id].attributes.friendly_name.search(searchRegex) >= 0 + entity_id.search(searchRegex) >= 0 || + this.hass.states[entity_id].attributes.friendly_name?.search(searchRegex) >= 0 + ) + && + ( + this.included_domains + ? this.included_domains.includes(entity_id.split(".")[0]) + : !this.excluded_domains.includes(entity_id.split(".")[0]) ) ) { this.results.push(entity_id); } } } catch (err) { + console.warn(err); } this.active_actions = this._getActivatedActions(searchText); @@ -196,3 +205,11 @@ setTimeout(() => { setConfig() { throw new Error("Can't find card-tools. See https://github.com/thomasloven/lovelace-card-tools");} }); }, 2000); + +window.customCards = window.customCards || []; +window.customCards.push({ + type: "search-card", + name: "Search Card", + preview: true, + description: "Card to search entities" +}); diff --git a/config/www/community/search-card/search-card.js.gz b/config/www/community/search-card/search-card.js.gz index 119c4bab..497e134a 100644 Binary files a/config/www/community/search-card/search-card.js.gz and b/config/www/community/search-card/search-card.js.gz differ