summaryrefslogtreecommitdiffstats
path: root/integrations/gen_docs_integrations.py
diff options
context:
space:
mode:
Diffstat (limited to 'integrations/gen_docs_integrations.py')
-rw-r--r--integrations/gen_docs_integrations.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/integrations/gen_docs_integrations.py b/integrations/gen_docs_integrations.py
index d8006dd2a..2b27db859 100644
--- a/integrations/gen_docs_integrations.py
+++ b/integrations/gen_docs_integrations.py
@@ -97,7 +97,7 @@ def clean_string(string):
The string represents an integration name, as it would be displayed in the final text
"""
- return string.lower().replace(" ", "_").replace("/", "-").replace("(", "").replace(")", "")
+ return string.lower().replace(" ", "_").replace("/", "-").replace("(", "").replace(")", "").replace(":", "")
def read_integrations_js(path_to_file):
@@ -146,14 +146,16 @@ def build_readme_from_integration(integration, mode=''):
sidebar_label = integration['meta']['monitored_instance']['name']
learn_rel_path = generate_category_from_name(
integration['meta']['monitored_instance']['categories'][0].split("."), categories)
- # build the markdown string
+ most_popular = integration['meta']['most_popular']
+ # build the markdown string
md = \
f"""<!--startmeta
meta_yaml: "{meta_yaml}"
sidebar_label: "{sidebar_label}"
learn_status: "Published"
learn_rel_path: "{learn_rel_path}"
+most_popular: {most_popular}
message: "DO NOT EDIT THIS FILE DIRECTLY, IT IS GENERATED BY THE COLLECTOR'S metadata.yaml FILE"
endmeta-->
@@ -256,7 +258,7 @@ endmeta-->
def build_path(meta_yaml_link):
"""
- funtion that takes a metadata yaml file link, and makes it into a path that gets used to write to a file.
+ function that takes a metadata yaml file link, and makes it into a path that gets used to write to a file.
"""
return meta_yaml_link.replace("https://github.com/netdata/", "") \
.split("/", 1)[1] \