← All tasks
pythonletscontrolit/ESPEasy #5044Not a task: already works

Information of which set contains which plugin

envgap__letscontrolit__ESPEasy-5044

01 / FAILURE SIGNATURE

As reported upstream

No identifying execution failure has been captured.
Not a benchmark task.
  • The project already builds and runs before the fix, so there is nothing to repair.

02 / ENVIRONMENT RECIPE

Base commit
3c6ac2c484bcfcaf525db8001664019100c4fa73
Manifest
docs/requirements.txt
Reproduce
Awaiting issue-specific recipe
Run under trace
Awaiting a meaningful runtime command

03 / ORIGINAL ISSUE TEXT

letscontrolit/ESPEasy #5044 · read the original issue
Hi,

I'm using ESPEasy for different purposes and really love it. The only thing what I sometimes need and haven't found so far is the information which plugin is in which collection.

So I made a little awk script which parses

`  src/src/CustomBuild/define_plugin_sets.h

`

and prints the results.

```

#!/usr/bin/env -S awk -f

BEGIN{

  printf("List by sets:\n-------------\n");

}

/^#ifdef PLUGIN_SET_/,/^#endif/ {

  if(/^#ifdef PLUGIN_SET_/) {

    set=$NF;

    gsub(/^PLUGIN_SET_/,"",set);

    first=0;

  }

  if(/^\s+#define USES_/) {

    if(first++==0){

      printf "%s\n  Plugins:\n",set;

    }

    plugin=$2;

    gsub(/^USES_/,"",plugin);

    description[plugin]=$0;

    gsub("^.*//","//",description[plugin]);

    printf ("\t%s %s\n", plugin, description[plugin]);

    sets[plugin]=sets[plugin]","set;

  }

}

END {

  printf("\nList by plugins:\n---------------\n");

  asorti(sets,sorted_plugins);

  for(plugin in sorted_plugins) {

    printf("%s: %s\n  Sets:\n",sorted_plugins[plugin],description[sorted_plugins[plugin]]);

    split(gensub("^,","","g",sets[sorted_plugins[plugin]]),sets_array,",");

    asort(sets_array);

    for(set in sets_array) {

      printf("\t%s\n",sets_array[set]);

    }

    printf("\n");

  }

}

```



Something like this or a matrix of it would be nice.

Greetings,

   Lars
Continue on GitHub ↗

04 / LABELS

Labels from the report text only; not yet run

No supported category has been assigned.

Label rules and the text that matched
[]