{"id":19269835,"url":"https://github.com/lyqht/article-badge-counter-github-action","last_synced_at":"2026-05-14T08:42:38.840Z","repository":{"id":65160733,"uuid":"431355544","full_name":"lyqht/article-badge-counter-github-action","owner":"lyqht","description":"GitHub Action Workflow that complements blog-post-workflow to generate a Shields.io badge. Intended to be easy like ABC","archived":false,"fork":false,"pushed_at":"2021-12-03T09:36:23.000Z","size":49,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-02-23T20:13:44.757Z","etag":null,"topics":["articles","blogging","composite-action","github-actions","hackathon"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lyqht.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-11-24T05:12:57.000Z","updated_at":"2023-06-16T02:25:38.000Z","dependencies_parsed_at":"2023-01-13T15:44:05.988Z","dependency_job_id":null,"html_url":"https://github.com/lyqht/article-badge-counter-github-action","commit_stats":{"total_commits":27,"total_committers":1,"mean_commits":27.0,"dds":0.0,"last_synced_commit":"91ba6978315bf45dfadffeadb0990157c5dad664"},"previous_names":["lyqht/article-badge-counter-workflow"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/lyqht/article-badge-counter-github-action","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lyqht%2Farticle-badge-counter-github-action","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lyqht%2Farticle-badge-counter-github-action/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lyqht%2Farticle-badge-counter-github-action/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lyqht%2Farticle-badge-counter-github-action/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lyqht","download_url":"https://codeload.github.com/lyqht/article-badge-counter-github-action/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lyqht%2Farticle-badge-counter-github-action/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29385175,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-12T22:07:52.078Z","status":"ssl_error","status_checked_at":"2026-02-12T22:07:49.026Z","response_time":55,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["articles","blogging","composite-action","github-actions","hackathon"],"created_at":"2024-11-09T20:22:10.269Z","updated_at":"2026-02-12T23:04:39.012Z","avatar_url":"https://github.com/lyqht.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# article-count-workflow\n\nThis GitHub action workflow aims to help you to create an article badge counter like this to showcase on your profile that you are more than just a developer 😉 Users can click it and be redirected to a website of your choice. \n\nThe default badge looks something like this.\n\n\n\u003ca href=\"https://esteetey.dev/\"\u003e\u003cimg alt=\"Website\" src=\"https://img.shields.io/website?label=blog 📝\u0026up_message=18 articles\u0026url=https://esteetey.dev/\"\u003e\u003c/img\u003e\u003c/a\u003e\n\n## What it does\n\nThis workflow is a composite action:\n\n- The number of articles is retrieved using the [blog-post-workflow](https://github.com/gautamkrishnar/blog-post-workflow) action.\n- The badge is generated using Shields.io, which are not clickable by default.\n- This action has a script to take in your inputs to create a customized clickable badge.\n- The commit and push github actions to your repo are performed by the [git-auto-commit workflow](https://github.com/stefanzweifel/git-auto-commit-action)\n\n## How to use\n\nIf you are new to GitHub Actions, refer to [this section](#if-you-dont-have-an-existing-github-action-workflow-for-your-repository). Otherwise, you can get started by referring to to the example given and the input options available.\n\n### Example\n\nThis is an example retrieved from the `article-badge.yml` that I declared to generate the badge on [my profile](https://github.com/lyqht).\n\n```yml\nname: Article Counter Badge Workflow\non:\n  schedule:\n    - cron: '*/60 * * * *'\n  workflow_dispatch:\n\njobs:\n  build:\n    runs-on: ubuntu-latest\n\n    steps:\n      - uses: lyqht/article-badge-counter-workflow@main\n        with:\n          feed_list: \"https://esteetey.dev/rss.xml\"\n          redirect_link: \"https://esteetey.dev/\"\n          tag_post_pre_newline: true\n          readme_path: \"README.md\"\n          badge_style: flat\n          badge_label: \"technical blog 📝\"\n          badge_message_suffix: \"articles\"\n          badge_message_bg_color: \"#abcbca\"\n```\n\nAnd add the corresponding `comment_tag_name` on the `README.md`\n\n```\n\u003c!-- ARTICLE_BADGE:START --\u003e\nYour badge will be populated here by the Github action!\n\u003c!-- ARTICLE_BADGE:END --\u003e\n```\n\nGenerated Badge\n\n\u003ca href=\"https://esteetey.dev/\"\u003e\u003cimg alt=\"Website\" src=\"https://img.shields.io/website?label=technical blog 📝\u0026up_message=18 articles\u0026url=https://esteetey.dev/\u0026style=flat\u0026up_color=%23abcbca\u0026\"\u003e\u003c/img\u003e\u003c/a\u003e\n\n## Input Options\n\nThe list of inputs below are retrieved from the workflow's [action.yml](https://github.com/lyqht/article-badge-counter-workflow/blob/main/action.yml). Basically, **every input except for `feed_list` is optional** if you don't plan to customize the default badge style and look. If you are not sure how to get RSS for your blog on community platforms e.g. Dev.to, Hashnode, please refer to [this section](https://github.com/gautamkrishnar/blog-post-workflow#popular-sources) written on the blog-post-workflow action's README.\n\n```yml\ninputs:\n  feed_list:\n    description: \"Comma separated list of RSS feed urls\"\n    required: true\n  gh_token:\n    description: \"GitHub access token with Repo scope\"\n    required: false\n    default: ${{ github.token }}\n  redirect_link:\n    description: \"Link to redirect user when they click on the badge. If not provided, the badge will not be a clickable.\"\n    required: false\n  readme_path:\n    description: \"Path of the readme file you want to update\"\n    default: README.md\n    required: false\n  comment_tag_name:\n    description: \"Override the default comment tag name, if you want to show multiple instances of the action on the same repo\"\n    default: ARTICLE_BADGE\n    required: false\n  tag_post_pre_newline:\n    description: \"To append with newline or not\"\n    default: \"false\"\n    required: false\n  badge_style:\n    description: \"Style of badge to be applied, refer to Shields.io website for the styles they offer\"\n    default: 'flat-square'\n    required: false\n  badge_label:\n    description: \"Text to be shown on the left side of the badge (label)\"\n    default: blog\n    required: false\n  badge_logo:\n    description: \"Logo to be shown on the left side of the badge (label)\"\n    default: \"\"\n    required: false\n  badge_message_suffix:\n    description: \"Text to be appended as suffix to the right side of the badge (message). For example, a suffix of 'pieces' will result in a message showing '20 pieces'\"\n    default: articles\n    required: false\n  badge_message_bg_color:\n    description: \"Background color of the right side of the badge (message). Accepts colors like 'green', hex values like '#F9D3C6'\"\n    default: \"green\"\n    required: false\n```\n\n\n**Use case considerations:**\n- Using Emoji: \n  - if you're want to include emoji in the label or message suffix, please make sure that they're enclosed in quotes. Otherwise the GitHub Action will not pick up the emoji.\n- If you are an author that cross-post to multiple platforms\n  - the action is able to take in a list of RSS, thanks to the blog-post-workflow.\n- If you don't want the user to be redirected to a specific link when they click on the badge\n  - You can choose to not pass in a `redirect_link`, then the badge will not be clickable.\n\n---\n\n### If you don't have an existing GitHub Action workflow for your repository\n\n1. Create a folder `.github/workflows` if you don't have it already \n2. Inside that folder, create a YAML file say `article-badge.yml`\n3. In the `article-badge.yml` file, you can copy the example above and modify it to your usage.\n4. You can choose to declare the `schedule` with a cron expression to run the job at a specified frequency e.g. every day once.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flyqht%2Farticle-badge-counter-github-action","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flyqht%2Farticle-badge-counter-github-action","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flyqht%2Farticle-badge-counter-github-action/lists"}