mirror of
https://github.com/RunaCapital/awesome-oss-alternatives.git
synced 2025-04-05 05:51:16 +08:00
add readme builder
This commit is contained in:
parent
2e230d21a9
commit
da6821d549
16
README.md
16
README.md
@ -83,9 +83,10 @@ ELT / ETL|[Dagster](https://dagster.io/)|Orchestration platform for data assets|
|
||||
ELT / ETL|[Kestra](https://kestra.io/)|orchestration and scheduling platform|<a href=https://github.com/kestra-io/kestra><img src="https://img.shields.io/github/stars/kestra-io/kestra?style=social" width=150/></a>|[Fivetran](https://fivetran.com/)
|
||||
ELT / ETL|[Orchest](https://www.orchest.io/)|No-code data pipelines builder|<a href=https://github.com/orchest/orchest><img src="https://img.shields.io/github/stars/orchest/orchest?style=social" width=150/></a>|[Fivetran](https://fivetran.com/)
|
||||
ELT / ETL|[Prefect](https://www.prefect.io/)|Data orchestration platform for a modern data stack|<a href=https://github.com/prefecthq/prefect><img src="https://img.shields.io/github/stars/prefecthq/prefect?style=social" width=150/></a>|[Fivetran](https://fivetran.com/)
|
||||
ERP|[DoliCloud](https://dolicloud.com) | Business management suite (ERP and CRM)|<a href=https://github.com/Dolibarr/dolibarr><img src="https://img.shields.io/github/stars/Dolibarr/dolibarr?style=social" width=150/></a>|[Oracle Fusion ERP Cloud](https://www.oracle.com/erp),[Odoo](https://odoo.com/),[Microsoft Dynamics](https://dynamics.microsoft.com/)
|
||||
ERP|[ERPNext](https://erpnext.com) | Agile, modern, module based Business management suite|<a href=https://github.com/frappe/erpnext><img src="https://img.shields.io/github/stars/frappe/erpnext?style=social" width=150/>|[SAP Business One](https://www.sap.com/products/business-one.html), [Odoo](https://odoo.com/)
|
||||
Email marketing|[Keila](https://www.keila.io/)|Email newsletter tool|<a href=https://github.com/pentacent/keila><img src="https://img.shields.io/github/stars/pentacent/keila?style=social" width=150/></a>|[Mailchimp](https://mailchimp.com), [Sendinblue](https://www.sendinblue.com)|
|
||||
Enterprise Search|[AppBase](https://www.appbase.io/)|Search UI components for React and Vue|<a href=https://github.com/appbaseio/reactivesearch><img src="https://img.shields.io/github/stars/appbaseio/reactivesearch?style=social" width=150/></a>|[Algolia](https://www.algolia.com/)
|
||||
Enterprise Search|[deepset](https://www.deepset.ai/)|NLP platform to build enterprise-grade semantic search|<a href=https://github.com/deepset-ai/haystack><img src="https://img.shields.io/github/stars/deepset-ai/haystack?style=social" width=150/></a>|[AWS Kendra](https://aws.amazon.com/kendra/), [QnA Maker](https://www.qnamaker.ai/)|
|
||||
Enterprise Search|[Jina.ai](https://jina.ai/)|Neural search framework for 𝙖𝙣𝙮 kind of data (including images)|<a href=https://github.com/jina-ai/jina><img src="https://img.shields.io/github/stars/jina-ai/jina?style=social" width=150/></a>|[Algolia](https://www.algolia.com/)
|
||||
Enterprise Search|[Meilisearch](https://www.meilisearch.com/)|Typo tolerant search engine|<a href=https://github.com/meilisearch/meilisearch><img src="https://img.shields.io/github/stars/meilisearch/MeiliSearch?style=social" width=150/></a>|[Algolia](https://www.algolia.com/)
|
||||
Enterprise Search|[Qdrant](https://qdrant.tech/)|Vector similarity search engine with extended filtering support|<a href=https://github.com/qdrant/qdrant><img src="https://img.shields.io/github/stars/qdrant/qdrant?style=social" width=150/></a>|[Google Vertex AI](https://cloud.google.com/vertex-ai), [Algolia](https://www.algolia.com/)|
|
||||
@ -93,8 +94,7 @@ Enterprise Search|[SeMI](https://www.semi.technology/)'s [Weaviate](https://gith
|
||||
Enterprise Search|[TypeSense](https://typesense.org/)|Typo tolerant fuzzy search engine|<a href=https://github.com/typesense/typesense><img src="https://img.shields.io/github/stars/typesense/typesense?style=social" width=150/></a>|[Algolia](https://www.algolia.com/)
|
||||
Enterprise Search|[Zilliz](https://zilliz.com)'s [Milvus](https://milvus.io)|Vector database for AI applications|<a href=https://github.com/milvus-io/milvus><img src="https://img.shields.io/github/stars/milvus-io/milvus?style=social" width=150/></a>|[Google Vertex AI](https://cloud.google.com/vertex-ai)
|
||||
Enterprise Search|[Zinc Labs](https://www.zinclabs.io)'s [Zinc](https://github.com/prabhatsharma/zinc)|Cloud native full text search|<a href=https://github.com/prabhatsharma/zinc><img src="https://img.shields.io/github/stars/prabhatsharma/zinc?style=social" width=150/></a>|[Elastic Cloud](https://www.elastic.co/elastic-stack/)
|
||||
ERP|[DoliCloud](https://dolicloud.com) | Business management suite (ERP and CRM)|<a href=https://github.com/Dolibarr/dolibarr><img src="https://img.shields.io/github/stars/Dolibarr/dolibarr?style=social" width=150/></a>|[Oracle Fusion ERP Cloud](https://www.oracle.com/erp),[Odoo](https://odoo.com/),[Microsoft Dynamics](https://dynamics.microsoft.com/)
|
||||
ERP|[ERPNext](https://erpnext.com) | Agile, modern, module based Business management suite|<a href=https://github.com/frappe/erpnext><img src="https://img.shields.io/github/stars/frappe/erpnext?style=social" width=150/>|[SAP Business One](https://www.sap.com/products/business-one.html), [Odoo](https://odoo.com/)
|
||||
Enterprise Search|[deepset](https://www.deepset.ai/)|NLP platform to build enterprise-grade semantic search|<a href=https://github.com/deepset-ai/haystack><img src="https://img.shields.io/github/stars/deepset-ai/haystack?style=social" width=150/></a>|[AWS Kendra](https://aws.amazon.com/kendra/), [QnA Maker](https://www.qnamaker.ai/)|
|
||||
Feature flag and toggle management|[FlagSmith](https://flagsmith.com/)|Feature Flag & Remote Config Service|<a href=https://github.com/Flagsmith/flagsmith><img src="https://img.shields.io/github/stars/Flagsmith/flagsmith?style=social" width=150/></a>|[LaunchDarkly](https://launchdarkly.com/)
|
||||
Feature flag and toggle management|[GrowthBook](https://www.growthbook.io/)|Feature flags and A/B testing|<a href=https://github.com/growthbook/growthbook><img src="https://img.shields.io/github/stars/growthbook/growthbook?style=social" width=150/></a>|[LaunchDarkly](https://launchdarkly.com/)
|
||||
Feature flag and toggle management|[Unleash](https://www.getunleash.io/)|Feature flags platform|<a href=https://github.com/Unleash/unleash><img src="https://img.shields.io/github/stars/Unleash/unleash?style=social" width=150/></a>|[LaunchDarkly](https://launchdarkly.com/)
|
||||
@ -145,22 +145,22 @@ Notetaking|[Logseq](https://logseq.com/)|Knowledge base manager|<a href=https://
|
||||
Notetaking|[Notabase](https://notabase.io)|Powerful and easy-to-use note-taking app for networked thinking|<a href=https://github.com/churichard/notabase><img src="https://img.shields.io/github/stars/churichard/notabase?style=social" width=150/></a>|[Notion](https://www.notion.so/), [Roam Research](https://roamresearch.com/)|
|
||||
Notetaking|[Outline](https://www.getoutline.com/)|Wiki and knowledge base|<a href=https://github.com/outline/outline><img src="https://img.shields.io/github/stars/outline/outline?style=social" width=150/></a>|[Notion](https://notion.so)|
|
||||
Notetaking|[Trilium.cc](https://trilium.cc/)|Personal knowledge base|<a href=https://github.com/zadam/trilium><img src="https://img.shields.io/github/stars/zadam/trilium?style=social" width=150/></a>|[Evernote](https://evernote.com/), [Onenote](https://www.onenote.com/)
|
||||
Observability and monitoring|[Chaos Genius](https://www.chaosgenius.io/)|ML powered analytics engine for outlier/anomaly detection and root cause analysis|<a href=https://github.com/chaos-genius/chaos_genius><img src="https://img.shields.io/github/stars/chaos-genius/chaos_genius?style=social" width=150/></a>|[AWS Lookout](https://aws.amazon.com/lookout-for-metrics/), [Anodot](https://www.anodot.com/), [Sisu Data](https://sisudata.com/), [Outlier](https://outlier.ai/)
|
||||
Observability and monitoring|[Grafana](https://grafana.com/)|Observability and data visualization platform|<a href=https://github.com/grafana/grafana><img src="https://img.shields.io/github/stars/grafana/grafana?style=social" width=150/></a>|[DataDog](https://www.datadoghq.com/), [NewRelic](https://newrelic.com/)
|
||||
Observability and monitoring|[Netdata](https://www.netdata.cloud)|Application monitoring and observability platform|<a href=https://github.com/netdata/netdata><img src="https://img.shields.io/github/stars/netdata/netdata?style=social" width=150/></a>|[DataDog](https://www.datadoghq.com/), [NewRelic](https://newrelic.com/)
|
||||
Observability and monitoring|[Sentry](https://sentry.io/)|Application monitoring with a focus on error reporting|<a href=https://github.com/getsentry/sentry><img src="https://img.shields.io/github/stars/getsentry/sentry?style=social" width=150/></a>|[DataDog](https://www.datadoghq.com/), [NewRelic](https://newrelic.com/)
|
||||
Observability and monitoring|[Signoz](https://signoz.io/)|Application monitoring and observability platform|<a href=https://github.com/signoz/signoz><img src="https://img.shields.io/github/stars/signoz/signoz?style=social" width=150/></a>|[DataDog](https://www.datadoghq.com/), [NewRelic](https://newrelic.com/)
|
||||
Observability and monitoring|[VictoriaMetrics](https://victoriametrics.com/)|Application monitoring and observability platform|<a href=https://github.com/VictoriaMetrics/VictoriaMetrics><img src="https://img.shields.io/github/stars/victoriametrics/victoriametrics?style=social" width=150/></a>|[DataDog](https://www.datadoghq.com/), [NewRelic](https://newrelic.com/)
|
||||
Observability and monitoring|[Netdata](https://www.netdata.cloud)|Application monitoring and observability platform|<a href=https://github.com/netdata/netdata><img src="https://img.shields.io/github/stars/netdata/netdata?style=social" width=150/></a>|[DataDog](https://www.datadoghq.com/), [NewRelic](https://newrelic.com/)
|
||||
Observability and monitoring|[Chaos Genius](https://www.chaosgenius.io/)|ML powered analytics engine for outlier/anomaly detection and root cause analysis|<a href=https://github.com/chaos-genius/chaos_genius><img src="https://img.shields.io/github/stars/chaos-genius/chaos_genius?style=social" width=150/></a>|[AWS Lookout](https://aws.amazon.com/lookout-for-metrics/), [Anodot](https://www.anodot.com/), [Sisu Data](https://sisudata.com/), [Outlier](https://outlier.ai/)
|
||||
Observability and monitoring|[Uptrace](https://uptrace.dev/)|Application monitoring and observability platform|<a href=https://github.com/uptrace/uptrace><img src="https://img.shields.io/github/stars/uptrace/uptrace?style=social" width=150/></a>|[DataDog](https://www.datadoghq.com/), [NewRelic](https://newrelic.com/)
|
||||
Observability and monitoring|[VictoriaMetrics](https://victoriametrics.com/)|Application monitoring and observability platform|<a href=https://github.com/VictoriaMetrics/VictoriaMetrics><img src="https://img.shields.io/github/stars/victoriametrics/victoriametrics?style=social" width=150/></a>|[DataDog](https://www.datadoghq.com/), [NewRelic](https://newrelic.com/)
|
||||
Password manager|[BitWarden](https://bitwarden.com/)|Password manager for teams and individuals|<a href=https://github.com/bitwarden/server><img src="https://img.shields.io/github/stars/bitwarden/server?style=social" width=150/></a>|[1Password](https://1password.com/)
|
||||
Password manager|[Padloc](https://padloc.app/)|Password manager for teams and individuals|<a href=https://github.com/padloc/padloc><img src="https://img.shields.io/github/stars/padloc/padloc?style=social" width=150/></a>|[1Password](https://1password.com/)|
|
||||
Password manager|[Passbolt](https://www.passbolt.com/)|Password manager for teams and individuals|<a href=https://github.com/passbolt/passbolt_api><img src="https://img.shields.io/github/stars/passbolt/passbolt_api?style=social" width=150/></a>|[1Password](https://1password.com/)
|
||||
Platform as a service|[Coolify](https://coolify.io/)|Self-hostable Heroku alternative|<a href=https://github.com/coollabsio/coolify><img src="https://img.shields.io/github/stars/coollabsio/coolify?style=social" width=150/></a>|[Heroku](https://www.heroku.com/)|
|
||||
Platform as a servive|[Otomi](https://otomi.io)|Self-hosted PaaS for Kubernetes|<a href=https://github.com/redkubes/otomi-core><img src="https://img.shields.io/github/stars/redkubes/otomi-core?style=social" width=150/></a>|[Heroku](https://www.heroku.com/)
|
||||
Platform as a service|[Porter](https://porter.run/)|Kubernetes powered PaaS that runs in your own cloud|<a href=https://github.com/porter-dev/porter><img src="https://img.shields.io/github/stars/porter-dev/porter?style=social" width=150/></a>|[Heroku](https://www.heroku.com/)
|
||||
Platform as a service|[Pulumi](https://www.pulumi.com/)|Universal Infrastructure as Code|<a href=https://github.com/pulumi/pulumi><img src="https://img.shields.io/github/stars/pulumi/pulumi?style=social" width=150/></a>|[Heroku](https://www.heroku.com/)|
|
||||
Platform as a service|[Qovery](https://www.qovery.com/)|Kubernetes powered PaaS that runs in your own cloud|<a href=https://github.com/Qovery/engine><img src="https://img.shields.io/github/stars/Qovery/engine?style=social" width=150/></a>|[Heroku](https://www.heroku.com/)
|
||||
Platform as a service|[Space Cloud](https://space-cloud.io/)|Serverless cloud deployment platform|<a href=https://github.com/spacecloud-io/space-cloud><img src="https://img.shields.io/github/stars/spacecloud-io/space-cloud?style=social" width=150/></a>|[Heroku](https://www.heroku.com/)|
|
||||
Platform as a servive|[Otomi](https://otomi.io)|Self-hosted PaaS for Kubernetes|<a href=https://github.com/redkubes/otomi-core><img src="https://img.shields.io/github/stars/redkubes/otomi-core?style=social" width=150/></a>|[Heroku](https://www.heroku.com/)
|
||||
Product Analytics|[PostHog](https://posthog.com/)|Product analytics platform|<a href=https://github.com/PostHog/posthog><img src="https://img.shields.io/github/stars/PostHog/posthog?style=social" width=150/></a>|[Amplitude](https://amplitude.com/), [MixPanel](https://mixpanel.com/)
|
||||
Project Management|[Focalboard](https://www.focalboard.com/)|Alternative to Trello, Notion, and Asana|<a href=https://github.com/mattermost/focalboard><img src="https://img.shields.io/github/stars/mattermost/focalboard?style=social" width=150/></a>|[Trello](https://trello.com/), [Notion](https://www.notion.so/), [Asana](https://asana.com/)|
|
||||
Project Management|[OpenProject](https://www.openproject.org/)|Project management software|<a href=https://github.com/opf/openproject><img src="https://img.shields.io/github/stars/opf/openproject?style=social" width=150/></a>|[Asana](https://asana.com/), [Trello](https://trello.com/)|
|
||||
@ -177,8 +177,8 @@ Session replay software|[OpenReplay](https://openreplay.com/)|Session replay sta
|
||||
Streaming|[Glimesh](https://glimesh.tv/)|Live streaming platform|<a href=https://github.com/glimesh/glimesh.tv><img src="https://img.shields.io/github/stars/glimesh/glimesh.tv?style=social" width=150/></a>|[Twitch](https://www.twitch.tv/)
|
||||
Timeseries database|[InfluxDB](https://www.influxdata.com/)|Database designed to process time series data|<a href=https://github.com/influxdata/influxdb><img src="https://img.shields.io/github/stars/influxdata/influxdb?style=social" width=150/></a>|[Kdb+](https://kx.com/developers/)
|
||||
Timeseries database|[QuestDB](https://questdb.io/)|Database designed to process time series data|<a href=https://github.com/questdb/questdb><img src="https://img.shields.io/github/stars/questdb/questdb?style=social" width=150/></a>|[Kdb+](https://kx.com/developers/)
|
||||
Timeseries database|[TimescaleDB](https://www.timescale.com/)|Database designed to process time series data|<a href=https://github.com/timescale/timescaledb><img src="https://img.shields.io/github/stars/timescale/timescaledb?style=social" width=150/></a>|[Kdb+](https://kx.com/developers/)
|
||||
Timeseries database|[TDengine](https://tdengine.com/?en)|Database designed to process time series data|<a href=https://github.com/taosdata/TDengine><img src="https://img.shields.io/github/stars/taosdata/TDengine?style=social" width=150/></a>|[Kdb+](https://kx.com/developers/)
|
||||
Timeseries database|[TimescaleDB](https://www.timescale.com/)|Database designed to process time series data|<a href=https://github.com/timescale/timescaledb><img src="https://img.shields.io/github/stars/timescale/timescaledb?style=social" width=150/></a>|[Kdb+](https://kx.com/developers/)
|
||||
Video Conferencing|[Jitsi](https://jitsi.org/meet)|Video conferences platform and SDK|<a href=https://github.com/jitsi/jitsi-meet><img src="https://img.shields.io/github/stars/jitsi/jitsi-meet?style=social" width=150/></a>|[Zoom](https://zoom.us/)|
|
||||
Video Conferencing|[LiveKit](https://livekit.io/)|SFU and SDKs for high-performance, scalable WebRTC|<a href=https://github.com/livekit/livekit-server><img src="https://img.shields.io/github/stars/livekit/livekit-server?style=social" width=150/></a>|[Twilio](https://www.twilio.com/), [Agora](https://agora.io/)|
|
||||
Video Conferencing|[OpenVidu](https://openvidu.io/)|Platform and SDKs to build on-premises WebRTC video conferences|<a href=https://github.com/OpenVidu/openvidu><img src="https://img.shields.io/github/stars/OpenVidu/openvidu?style=social" width=150/></a>|[Twilio](https://www.twilio.com/)|
|
||||
|
172
add_company.py
172
add_company.py
@ -1,129 +1,163 @@
|
||||
"""
|
||||
This script adds company directly to the list
|
||||
"""
|
||||
import yaml
|
||||
|
||||
|
||||
def get_repo_from_url(url):
|
||||
'''
|
||||
"""
|
||||
Given a url, return the repository name.
|
||||
|
||||
|
||||
:param url: the url of the repo
|
||||
:return: The repo name.
|
||||
'''
|
||||
idx = url.find('.com/')
|
||||
return url[idx + len('.com/'):].strip('/')
|
||||
"""
|
||||
idx = url.find(".com/")
|
||||
return url[idx + len(".com/") :].strip("/")
|
||||
|
||||
|
||||
def create_alternatives_md(names, links):
|
||||
'''
|
||||
Create a markdown string of the form:
|
||||
|
||||
"""
|
||||
Create a markdown string of the form:
|
||||
|
||||
[name1](link1), [name2](link2), ...
|
||||
|
||||
|
||||
:param names: A list of alternative names for the image
|
||||
:param links: A list of links to the alternative versions of the file
|
||||
:return: A string of the form:
|
||||
'''
|
||||
return ', '.join(
|
||||
(
|
||||
f"""[{name.strip()}]({link.strip()})""" for name, link in zip(names, links)
|
||||
)
|
||||
"""
|
||||
return ", ".join(
|
||||
(f"""[{name.strip()}]({link.strip()})""" for name, link in zip(names, links))
|
||||
)
|
||||
|
||||
|
||||
def create_shield_link(gh_link):
|
||||
return 'https://img.shields.io/github/stars/{repo}?style=social'.format(repo=get_repo_from_url(gh_link)).strip()
|
||||
return "https://img.shields.io/github/stars/{repo}?style=social".format(
|
||||
repo=get_repo_from_url(gh_link)
|
||||
).strip()
|
||||
|
||||
|
||||
def create_new_line(category,
|
||||
name,
|
||||
description,
|
||||
link,
|
||||
gh_link,
|
||||
alts_names,
|
||||
alts_links
|
||||
):
|
||||
|
||||
return '{}|{}|{}|{}|{}|\n'.format(
|
||||
category.strip(),
|
||||
f'[{name.strip()}]({link.strip()})',
|
||||
description.strip(),
|
||||
f'<a href={gh_link.strip()}><img src="{create_shield_link(gh_link)}" width=150/></a>',
|
||||
create_alternatives_md(alts_names, alts_links)
|
||||
)
|
||||
def create_new_line(
|
||||
category, company_name, description, link, gh_link, alts_names, alts_links
|
||||
):
|
||||
|
||||
return "{}|{}|{}|{}|{}|\n".format(
|
||||
category.strip(),
|
||||
f"[{company_name.strip()}]({link.strip()})",
|
||||
description.strip(),
|
||||
f'<a href={gh_link.strip()}><img src="{create_shield_link(gh_link)}" width=150/></a>',
|
||||
create_alternatives_md(alts_names, alts_links),
|
||||
)
|
||||
|
||||
|
||||
def add_new_company(category,
|
||||
name,
|
||||
description,
|
||||
link,
|
||||
gh_link,
|
||||
alts_names,
|
||||
alts_links
|
||||
):
|
||||
def add_new_company(
|
||||
category, company_name, description, link, gh_link, alts_names, alts_links
|
||||
):
|
||||
|
||||
|
||||
with open('README.md', 'r', encoding='utf-8') as f:
|
||||
with open("README.md", "r", encoding="utf-8") as f:
|
||||
all = f.readlines()
|
||||
|
||||
table_start = '|Category|Company|Description|GitHub Stars|Alternative to|\n'
|
||||
table_end = '<!-- END STARTUP LIST -->\n'
|
||||
|
||||
table_start = "|Category|Company|Description|GitHub Stars|Alternative to|\n"
|
||||
table_end = "<!-- END STARTUP LIST -->\n"
|
||||
|
||||
idx = all.index(table_start)
|
||||
idx_end = all.index(table_end)
|
||||
|
||||
find_name = lambda x: x[x.index('[') + 1 : x.index(']')].strip()
|
||||
find_cat = lambda x: x[:x.index('|')].strip()
|
||||
find_name = lambda x: x[x.index("[") + 1 : x.index("]")].strip()
|
||||
find_cat = lambda x: x[: x.index("|")].strip()
|
||||
|
||||
categories = [(find_cat(x), find_name(x)) for x in all[idx + 2: idx_end - 1]]
|
||||
categories = [(find_cat(x), find_name(x)) for x in all[idx + 2 : idx_end - 1]]
|
||||
|
||||
search_tup = (category.strip(), name.strip())
|
||||
search_tup = (category.strip(), company_name.strip())
|
||||
|
||||
insert_idx = -1
|
||||
|
||||
for i, tup in enumerate(reversed(categories)):
|
||||
if search_tup > tup:
|
||||
if search_tup == tup:
|
||||
return "This entry already exists"
|
||||
elif search_tup > tup:
|
||||
print(search_tup, tup)
|
||||
insert_idx = len(categories) - i
|
||||
break
|
||||
|
||||
all.insert(
|
||||
insert_idx + idx + 2,
|
||||
create_new_line(category, name, description, link, gh_link, alts_names, alts_links)
|
||||
create_new_line(
|
||||
category, company_name, description, link, gh_link, alts_names, alts_links
|
||||
),
|
||||
)
|
||||
|
||||
with open('README.md', 'w', encoding='utf-8') as f:
|
||||
f.writelines(all)
|
||||
|
||||
file_name = "_".join(company_name.split(" "))
|
||||
with open(f"submissions/{file_name}.yaml", "w") as file:
|
||||
yaml.dump(
|
||||
dict(
|
||||
category=category,
|
||||
company_name=company_name,
|
||||
description=description,
|
||||
link=link,
|
||||
gh_link=gh_link,
|
||||
alts_names=alts_names,
|
||||
alts_links=alts_links,
|
||||
),
|
||||
file,
|
||||
default_flow_style=False,
|
||||
)
|
||||
|
||||
if __name__ == '__main__':
|
||||
with open("README.md", "w", encoding="utf-8") as f:
|
||||
f.writelines(all)
|
||||
|
||||
return "ok, added!"
|
||||
|
||||
|
||||
def add_company_from_command_line():
|
||||
count = 0
|
||||
args = dict()
|
||||
|
||||
while True:
|
||||
if count == 0:
|
||||
args['name'] = input("Enter the company name.\n(e.g Metabase)\n: ")
|
||||
print('-' * 100)
|
||||
args["company_name"] = input("Enter the company name.\n(e.g Metabase)\n: ")
|
||||
print("-" * 100)
|
||||
count += 1
|
||||
elif count == 1:
|
||||
args['category'] = input("Enter category of the company. May be an existing or a new one.\n(e.g Business Intelligence)\n: ")
|
||||
print('-' * 100)
|
||||
args["category"] = input(
|
||||
"Enter category of the company. May be an existing or a new one.\n(e.g Business Intelligence)\n: "
|
||||
)
|
||||
print("-" * 100)
|
||||
count += 1
|
||||
elif count == 2:
|
||||
args['description'] = input("Description of the company.\nKeep it short and simple (use one line)\n: ")
|
||||
print('-' * 100)
|
||||
args["description"] = input(
|
||||
"Description of the company.\nKeep it short and simple (use one line)\n: "
|
||||
)
|
||||
print("-" * 100)
|
||||
count += 1
|
||||
elif count == 3:
|
||||
args['link'] = input("""Url to the company's website.\n(e.g https://www.metabase.com/)\n: """)
|
||||
print('-' * 100)
|
||||
args["link"] = input(
|
||||
"""Url to the company's website.\n(e.g https://www.metabase.com/)\n: """
|
||||
)
|
||||
print("-" * 100)
|
||||
count += 1
|
||||
elif count == 4:
|
||||
args['gh_link'] = input(""""Url of the product's github repo.\n(e.g https://github.com/metabase/metabase)\n: """)
|
||||
print('-' * 100)
|
||||
args["gh_link"] = input(
|
||||
""""Url of the product's github repo.\n(e.g https://github.com/metabase/metabase)\n: """
|
||||
)
|
||||
print("-" * 100)
|
||||
count += 1
|
||||
elif count == 5:
|
||||
args['alts_names'] = input("""Names of the company's well-known SaaS competitors.\n(e.g for Metabase: PowerBI, DataStudio, Tableau)\n: """).split(',')
|
||||
print('-' * 100)
|
||||
args["alts_names"] = input(
|
||||
"""Names of the company's well-known SaaS competitors.\n(e.g for Metabase: PowerBI, DataStudio, Tableau)\n: """
|
||||
).split(",")
|
||||
print("-" * 100)
|
||||
count += 1
|
||||
elif count == 6:
|
||||
args['alts_links'] = input('Links to the corresponding SaaS competitors.\n(e.g for Metabase: https://powerbi.microsoft.com/, https://datastudio.google.com/, https://www.tableau.com/)\n: ').split(',')
|
||||
print('-' * 100)
|
||||
args["alts_links"] = input(
|
||||
"Links to the corresponding SaaS competitors.\n(e.g for Metabase: https://powerbi.microsoft.com/, https://datastudio.google.com/, https://www.tableau.com/)\n: "
|
||||
).split(",")
|
||||
print("-" * 100)
|
||||
count += 1
|
||||
else:
|
||||
add_new_company(**args)
|
||||
result = add_new_company(**args)
|
||||
print(result)
|
||||
break
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
add_company_from_command_line()
|
||||
|
26
build_readme.py
Normal file
26
build_readme.py
Normal file
@ -0,0 +1,26 @@
|
||||
"""
|
||||
This file builds README from YAML
|
||||
"""
|
||||
import yaml
|
||||
import os
|
||||
from add_company import add_new_company
|
||||
|
||||
|
||||
def parse_all_yamls():
|
||||
arr = []
|
||||
for filename in os.listdir("submissions"):
|
||||
if filename.endswith(".yaml"):
|
||||
with open(f"submissions/{filename}", "r") as file:
|
||||
obj = yaml.load(file, yaml.Loader)
|
||||
arr.append(obj)
|
||||
return arr
|
||||
|
||||
|
||||
def build_list():
|
||||
arr = parse_all_yamls()
|
||||
for obj in arr:
|
||||
add_new_company(**obj)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
build_list()
|
@ -1,3 +1,7 @@
|
||||
"""
|
||||
This script create yamls from README
|
||||
"""
|
||||
|
||||
import yaml
|
||||
|
||||
|
||||
|
21
sort.py
21
sort.py
@ -1,25 +1,28 @@
|
||||
def sort_readme():
|
||||
|
||||
with open('README.md', 'r', encoding='utf-8') as f:
|
||||
with open("README.md", "r", encoding="utf-8") as f:
|
||||
all = f.readlines()
|
||||
|
||||
table_start = '|Category|Company|Description|GitHub Stars|Alternative to|\n'
|
||||
table_start = "|Category|Company|Description|GitHub Stars|Alternative to|\n"
|
||||
table_end = "<!-- END STARTUP LIST -->\n"
|
||||
|
||||
idx = all.index(table_start)
|
||||
idx_end = all.index(table_end)
|
||||
|
||||
find_name = lambda x: x[x.index('[') + 1 : x.index(']')].strip()
|
||||
find_cat = lambda x: x[:x.index('|')].strip()
|
||||
find_name = lambda x: x[x.index("[") + 1 : x.index("]")].strip()
|
||||
find_cat = lambda x: x[: x.index("|")].strip()
|
||||
|
||||
pairs = [(find_cat(x), find_name(x)) for x in all[idx + 2: -1]]
|
||||
pairs = [(find_cat(x), find_name(x)) for x in all[idx + 2 : idx_end - 1]]
|
||||
|
||||
sorted_pairs = sorted(pairs)
|
||||
|
||||
right_elements = [all[idx + 2: -1][pairs.index(i)] for i in sorted_pairs]
|
||||
right_elements = [all[idx + 2 : -1][pairs.index(i)] for i in sorted_pairs]
|
||||
|
||||
all[idx + 2: -1] = right_elements
|
||||
all[idx + 2 : idx_end - 1] = right_elements
|
||||
|
||||
with open('README.md', 'w', encoding='utf-8') as f:
|
||||
with open("README.md", "w", encoding="utf-8") as f:
|
||||
f.writelines(all)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
sort_readme()
|
||||
sort_readme()
|
||||
|
Loading…
x
Reference in New Issue
Block a user