Custom Component: HACS

I have followed the tutorial by I don’t know why hacs do not detect my components :frowning:
https://github.com/max5962/prixCarburant-home-assistant
Thanks

Hi, I followed it and tried once again:

  1. Remove the configuration from configuration.yaml (if configured with legacy(YAMl)) or remove it using the trashbin icon on the integration page. :
    HACS configuration commented in my configuration.YAML
  2. Restart Home Assistant important
    Done
  3. Restart Home Assistant (yes, this needs to be done twice) important
    Done
  4. Delete the hacs directory under custom_components .
    Done
  5. Delete all files containing hacs under the .storage directory.
    Done
  6. Restart Home Assistant.
    Done

Then I tried to install againbut still the same. I do not understand as I never had any issue with HACS :frowning:

Is there any easy way to set the colour of the hacs.sensor in lovelace if there are available updates? I was trying to use the state_color: true but it doesn’t seem to work…

Regular sensors don’t get icon coloring (and never have). Binary sensors do though, so you could accomplish this by creating a Template Binary Sensor.

I am not great with templates but I think this might work (not tested).

binary_sensor:
  - platform: template
    sensors:
      hacs_updates:
        friendly_name: "HACS Update Available"
        value_template: "{{ (states.sensor.hacs.state|float > 0)}}"
        
2 Likes

Hi,

i am trying to install custom cards, however, i am getting this errors when installing:

Download was not complete [No content to download]

What can be the issue?

Same here, though only with some plugins, eg button card, mini graph card, custom header
2020-02-12 11:28:57 ERROR (MainThread) [hacs.repository.plugin.custom-cards.button-card] Download was not complete [No content to download]
2020-02-12 11:28:57 ERROR (MainThread) [hacs.repository.plugin.custom-cards.button-card] Download was not complete [No content to download]
2020-02-12 11:28:57 ERROR (MainThread) [hacs.repository.plugin.custom-cards.button-card] Download was not complete [No content to download]
2020-02-12 11:28:57 ERROR (MainThread) [hacs.repository.plugin.custom-cards.button-card] Download was not complete [No content to download]
2020-02-12 11:28:57 ERROR (MainThread) [hacs.repository.plugin.custom-cards.button-card] Download was not complete [No content to download]

edit:
Maybe because these don’t seem to have a hacs.json? Opened an issue for button-card to ask if this could be the cause.

Is this what you’re after?

          - entity: sensor.hacs
            name: HACS
            tap_action:
              action: navigate
              navigation_path: /hacs
            style: |
              :host {
                {% if states(config.entity) != '0' %}
                  color: yellow;
                  --paper-item-icon-color: yellow;
                {% endif %};
              }

image

3 Likes

While I’m here… Possibly the least important question I’ve ever asked here, but why don’t I get the new icon in the side bar?
image

You need 1.0.0+ for that or change your config

fixed in HACS 0.21.5!

I redid the integration (deleted the old one) then set the icon to hacs:hacs when you add it back

You can also

  • stop HA
  • search for mdi:alpha-c-box in <config>/.storage/core.config_entries and replace it with hacs:hacs
  • start HA

Auswahl_267

2 Likes

I found some of the config options were different as well when I redid the integration…

Yeah… almost exactly like that. I only want the icon colour to change and I navigate to a different spot:

              - entity: sensor.hacs
                tap_action:
                  action: navigate
                  navigation_path: /hacs/installed
                style: |
                  :host {
                  --paper-item-icon-color:
                    {% if states(config.entity)|int >0 %}
                      rgb(255, 165, 0)
                    {% endif %}
                    ;
                  }

Thanks!

3 Likes

Hello. I’ve tried to install HACS on a newly installed Home Assistant. I’ve followed all the steps to install and configure it, but when I’m pasting the github personal access token I’m getting this error:
The Personal Access Token is invalid.
The token is newly generated. I’ve tried to uninstall hacs, deleted all hacs files from .storage folder, deleted hacs folder, restarted HA 2 times, reinstalled HACS but I’m getting the same error.
Could anybody help me please to get through this error? Thank you.

Thanks :slight_smile:
To keep the original color when there is no update I did it this way:

entities:
  - entity: sensor.hacs
    style: |
      {% if states(config.entity)|int >0 %}
      :host {
      --paper-item-icon-color:
          rgb(255, 165, 0)
      }
      {% endif %}
type: entities

I’m new to this. Hope this is correct.

Double check your credentials, with this error, it seems likely, that you really have something wrong with the access token(s) and/or other credentials.

In general Github and a few other sites do strange things with formatting. I recommend to paste the copied code in an empty editor window, select and copy it again, then paste it where you need it. This way, you can avoid any strange formatting errors. :slight_smile:

For developers/publishers
Have a look here:

Mine keeps the original theme colour if no update already so not sure what you think you’re doing differently?

With the latest version of Home Assistant I can’t access the settings of HACS to enable Appdaemon. Or is it hidden somewhere else now?