Readme Converter Action

Readme Converter Action

Readme Converter Action is a GitHub Action that reads the content of a README.md file from any repository and transforms it into HTML Chrome bookmarks, CSV, and JSON files.

GitHub ActionsLibraryCI/CD

Resources:

In the vast landscape of GitHub repositories, awesome collections, like "Awesome SEO", and "Awesome Awesome" stand out as incredible resources filled with valuable links and information. These repositories curate a wealth of knowledge, offering bookmarks to some of the best resources on various topics. However, managing and exporting these links from a README.md file can be challenging.

Enter Readme Converter Action. This GitHub action reads the content of a README.md file from any repository and transforms it into HTML Chrome bookmarks, CSV, and JSON files. It's the perfect tool for exporting link and bookmark information from a README file into other formats, making the wealth of knowledge in repositories like "awesome" easily accessible in various formats.

How to Use

You can use this action in a workflow in your own repository to process the README.md file from another repository. Below is an example of how to set up the action in a workflow configuration file (.github/workflows/main.yml) in your own repository:

on: [push]

jobs:
  parse_to_bookmarks:
    runs-on: ubuntu-latest
    name: Export README to json, csv, and bookmarks
    steps:
        - uses: teles/[email protected]
          with:
            input: README.md
            output: dist/bookmarks.html
        - uses: teles/[email protected]
          with:
            type: csv
            input: README.md
            output: dist/links.csv
        - uses: teles/[email protected]
          with:
            type: json
            input: README.md
            output: dist/links.json
            commit_branch: gh-pages
            commit_message: Updates JSON file

In this example, the action is set up to run when a push occurs in the repository. It reads the content of the README.md file and generates HTML, CSV, and JSON files in a directory named dist. You can also customize the output type and other options as needed.

Parameters

  • input: The README.md file you want to process.
  • output: The name of the output file generated by the action.
  • type (optional): The desired output format (HTML, CSV, or JSON).
  • commit_branch (optional): The branch where you want to commit the output file (used when the type is JSON).
  • commit_message (optional): The commit message used when the action commits the output file.

Make sure to properly configure credentials and permissions to access the repository containing the README.md file you want to process.


šŸ§° Tools and Technologies

  • Shell Script
  • GitHub Actions
  • Yaml
  • CSV
  • JSON