emacs/var/elfeed/db/data/52/52c9c0457ee4ea2f9135388c71b4c8d402c0048e
2022-01-03 12:49:32 -06:00

1 line
1.7 KiB
Plaintext

<!-- SC_OFF --><div class="md"><p>For those unpatiently waiting for gnome 41 and are running home assistant.</p> <p>Add the following to your sensors to check the package version every hour:</p> <pre><code>- platform: command_line name: Gnome Shell Version json_attributes: - pkgver - pkgrel - repo command: &quot;curl https://archlinux.org/packages/search/json/?name=gnome-shell | python -c \&quot;import sys, json; print(json.dumps(json.load(sys.stdin)[&#39;results&#39;][-1]))\&quot;&quot; value_template: &quot;{{ value_json.pkgver | float }}-{{ value_json.pkgrel }}&quot; scan_interval: 600 </code></pre> <p>You can use it in sensors to see the current gnome-shell version and repo with an entities card:</p> <pre><code>type: entities entities: - entity: sensor.gnome_shell_version icon: mdi:gnome - type: attribute entity: sensor.gnome_shell_version attribute: repo name: Repository icon: mdi:database </code></pre> <p>With an automation you can get a notification of your choice. e.g. getting one on my mobile app</p> <pre><code>alias: Gnome 41 in Arch description: &#39;&#39; trigger: - platform: template value_template: &gt;- {% if state_attr(&#39;sensor.gnome_shell_version&#39;, &#39;pkgver&#39;) | float &gt; 41 %} true {% endif %} condition: [] action: - service: notify.mobile_app_mi_a2 data: message: &gt;- Gnome 41 released in {{ state_attr(&#39;sensor.gnome_shell_version&#39;, &#39;repo&#39;) }} mode: single </code></pre> </div><!-- SC_ON --> &#32; submitted by &#32; <a href="https://www.reddit.com/user/raetiacorvus"> /u/raetiacorvus </a> <br/> <span><a href="https://www.reddit.com/r/archlinux/comments/q795mr/are_we_gnome_41_yet/">[link]</a></span> &#32; <span><a href="https://www.reddit.com/r/archlinux/comments/q795mr/are_we_gnome_41_yet/">[comments]</a></span>